Observant readers will recognize from the following that this question is related to earlier posts from me... that is: there is something fundamental that I just don't get.
If someone is eager to answer all my questions, then please search ahead for the question marks (?).
Also, what is the bigger picture that I am missing? Please use as many words as necessary to explain.
Thanks, -mark
The players:
CUSTOMER-IP: the UserAgent OPENSER-IP: my openser box OPENSER.FQDN: the fully qualified domain name of my openser box PSTNGW-IP: the PSTN gateway
My openser box gets this CANCEL:
U 2006/11/06 18:40:10.689785 CUSTOMER-IP:5060 -> OPENSER-IP:5060 CANCEL sip:011445551212@OPENSER.FQDN:5060 SIP/2.0 From: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP;tag=TAG To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP Call-ID: CALLID@CUSTOMER-IP CSeq: 2 CANCEL Via: SIP/2.0/UDP CUSTOMER-IP:5060;branch=BRANCH Max-Forwards: 70 Supported: 100rel,replaces Content-Length: 0
It ends up in my standard stateful relay handler where I t_relay() it (should I?) and this gets generated:
# U 2006/11/06 18:40:10.691301 OPENSER-IP:5060 -> PSTNGW-IP:5060 CANCEL sip:445551212@PSTNGW-IP;user=phone SIP/2.0 Record-Route: sip:011445551212@OPENSER-IP;lr=on;ftag=TAG From: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP;tag=TAG To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP Call-ID: CALLID@CUSTOMER-IP CSeq: 2 CANCEL Via: SIP/2.0/UDP OPENSER-IP;branch=BRANCH2.0 Via: SIP/2.0/UDP CUSTOMER-IP:5060;branch=BRANCH Max-Forwards: 69 Supported: 100rel,replaces Content-Length: 0
and this also happens:
# U 2006/11/06 18:40:10.691342 OPENSER-IP:5060 -> CUSTOMER-IP:5060 SIP/2.0 200 canceling From: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP;tag=TAG To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP;tag=TAG2 Call-ID: CALLID@CUSTOMER-IP CSeq: 2 CANCEL Via: SIP/2.0/UDP CUSTOMER-IP:5060;branch=BRANCH Content-Length: 0
How was that last packet generated, where was it done?
It's not in my openser.cfg, should I have sent back just such a message? If so, would this automagically sent message still have been sent?
Next I get these two packets:
# U 2006/11/06 18:40:10.761582 PSTNGW-IP:5060 -> OPENSER-IP:5060 SIP/2.0 200 OK Call-ID: CALLID@CUSTOMER-IP From: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP;tag=TAG To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP Content-Length: 0 CSeq: 2 CANCEL Via: SIP/2.0/UDP OPENSER-IP;branch=BRANCH2.0,SIP/2.0/UDP CUSTOMER-IP:5060;branch=BRANCH Contact: sip:445551212@PSTNGW-IP:5060;user=phone Record-Route: sip:011445551212@OPENSER-IP;lr=on;ftag=TAG
# U 2006/11/06 18:40:10.761616 PSTNGW-IP:5060 -> OPENSER-IP:5060 SIP/2.0 487 Request Terminated Call-ID: CALLID@CUSTOMER-IP From: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP;tag=TAG To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP;tag=20505 Content-Length: 0 CSeq: 2 INVITE Via: SIP/2.0/UDP OPENSER-IP;branch=BRANCH2.0,SIP/2.0/UDP CUSTOMER-IP:5060;branch=BRANCH
and my openser box replies with :
# U 2006/11/06 18:40:10.762238 OPENSER-IP:5060 -> PSTNGW-IP:5060 ACK sip:445551212@PSTNGW-IP;user=phone SIP/2.0 Via: SIP/2.0/UDP OPENSER-IP;branch=BRANCH2.0 From: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP;tag=TAG Call-ID: CALLID@CUSTOMER-IP To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP;tag=20505 CSeq: 2 ACK Content-Length: 0
and sends on this to the UAC:
# U 2006/11/06 18:40:10.762377 OPENSER-IP:5060 -> CUSTOMER-IP:5060 SIP/2.0 487 Request Terminated Call-ID: CALLID@CUSTOMER-IP From: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP;tag=TAG To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP;tag=20505 Content-Length: 0 CSeq: 2 INVITE Via: SIP/2.0/UDP CUSTOMER-IP:5060;branch=BRANCH
Now, how was that generated? Is this part of the "tm" module?
And then when I get this ACK:
# U 2006/11/06 18:40:10.772875 CUSTOMER-IP:5060 -> OPENSER-IP:5060 ACK sip:011445551212@OPENSER.FQDN:5060 SIP/2.0 From: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP;tag=TAG To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP;tag=20505 Call-ID: CALLID@CUSTOMER-IP CSeq: 2 ACK Via: SIP/2.0/UDP CUSTOMER-IP:5060;branch=BRANCH Max-Forwards: 70 Contact: sip:CUST-PHONE-NUMBER@CUSTOMER-IP:5060;transport=UDP Content-Length: 0
What should I do with it? I do nothing... if I should do nothing is there any special way I should do it? Or is this just handled by the tm module?
What I don't get is the CANCEL is directed AT my openser box:
CANCEL sip:011445551212@OPENSER.FQDN:5060 SIP/2.0 To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP
just like the ACK:
ACK sip:011445551212@OPENSER.FQDN:5060 SIP/2.0 To: sip:011445551212@OPENSER.FQDN:5060;transport=UDP;tag=20505
and I t_relay() the CANCEL but sit on the ACK...