[SR-Users] Handling of CANCEL in case of no matching INVITE

Vassilis Radis radisb at gmail.com
Fri May 3 11:04:31 CEST 2013


Hello all,

In the documentation of the t_relay_cancel() (TM module) there is an
example that reads:

if (method == CANCEL) {
if (!t_relay_cancel()) {  # implicit drop if relaying was successful,
                                  # nothing to do

# corresponding INVITE transaction found but error occurred
sl_reply("500", "Internal Server Error");
drop;
}
# bad luck, corresponding INVITE transaction is missing,
# do the same as for INVITEs
}

What bothers me is the phrase #do the same as or INVITEs, because in RFC(
http://tools.ietf.org/html/rfc3261#section-16.10 )  it says:

If a response context is not found, the element does not have any
knowledge of the request to apply the CANCEL to.  It MUST *statelessly*
forward the CANCEL request (it may have statelessly forwarded the
associated request previously).


So aren't we supposed to immediately statelessly forward the CANCEL if
t_relay_cancel() did not find the INVITE transaction, instead of doing
the same as INVITEs, which could be t_relay() (not stateless)?. Like
below:


if (method == CANCEL) {
	if (!t_relay_cancel()) {  # implicit drop if relaying was successful,
                                  # nothing to do

		# corresponding INVITE transaction found but error occurred
		sl_reply("500", "Internal Server Error");
		drop;
	}
        # bad luck, corresponding INVITE transaction is missing,
	forward();
}

Am I correct or am i missing something?
Thank you in advance,
Bill
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20130503/68e70900/attachment-0001.html>


More information about the sr-users mailing list