[OpenSIPS-Users] Opensips should reply "SIP/2.0 200 canceling" to CANCEL after forwarding ? or wait after reply

Bogdan-Andrei Iancu bogdan at voice-system.ro
Mon Jun 21 18:09:53 CEST 2010

Hi Julien,

I doubt opensips generates a 487 Request terminated for an INVITE when 
the CANCEL is passing through - the 497 is end to end, not hop by hop 
(as the CANCEL), So, the 487 is generated by callee and opensips simply 
relays it back.


Julien Chavanton wrote:
> Hi, regarding handling of CANCEL request,
> Please correct me if I am wrong,
> I have glare condition on how Opensips handled Cancel requests.
> The problem is taht Opensips respond "487 Request terminated" strait 
> after forwarding the CANCEL but it does not know if the targe UA will 
> accept it.
> I think it should wait after the target UA to reply before, as this 
> can create out of sync situation if there is a problem with the target.
> in this senario the "200 OK" is  received at the same time as the 
> CANCEL is sent, in this case the target UA as the right to ignore the 
> CANCEL because it as generated a final response.
> UA -----> CANCEL ------------------------> osips
> UA <------ SIP/2.0 200 canceling --------> osips
>                                            osips <--- 200 OK <-- UA
>                                            osips ---> CANCEL --> UA
> UA <---- SIP/2.0 487 Request Terminated -> osips

Bogdan-Andrei Iancu
OpenSIPS Bootcamp
20 - 24 September 2010, Frankfurt, Germany

More information about the Users mailing list