[OpenSIPS-Devel] rls_handle_notify() does not recognize dialog

Anca Vamanu anca at opensips.org
Mon Sep 7 15:01:23 CEST 2009


Hi Juha,

I have just tested myself and did not saw this problem. First, what 
version are you running? Trunk or 1.5 branch?
Then, do you see this problem all the time or only from time to time?
I am thinking it might be a synchronization issue. And the processing of 
the Notify taking place before the process that received the 200 OK for 
Subscribe succeeds to update the dialog information. If you see this 
problem only time to time, then this theory could be true and to prove 
it you could try to run opensips with fork=no. If this problem doesn't 
occur anymore then I was right. And then I will think at a solution.. I 
have one in mind already.
I will wait for your answers.

Regards,
Anca


Juha Heinanen wrote:
> i did some rls tests.  first i create a buddy list sip:jh-buddies at test.fi
> that currently has only one buddy test at test.fi.
>
> then jh used sip_subscribe_rls to subscribe to jh-buddies.  wireshark
> shows how rls server upon receiving subscribe send subscribe to
> sip:test at test.fi, how presence server replies to it with 200 ok followed
> by in-dialog notify.  when rls_handle_notify() handles this notify, it
> returns 2 meaning that "the Notify did not belog to a dialog initiated
> by the RLS server.".
>
> why is that?  the packets are below starting from subscribe sent by rls
> server.  "404 not found" comes from this piece of config code:
>
>     $var(ret_code) = rls_handle_notify();
>     if ($var(ret_code) == 1) exit;
>     if ($var(ret_code) == 2) {
>         sl_send_reply("404", "Not found");
> 	exit;
>     };
>
> -- juha
>
> ---------------------------------------------------------------------
>
> No.     Time            Source                Destination           Protocol Info
>       9 15:53:46.955023 127.0.0.1             127.0.0.1             SIP      Request: SUBSCRIBE sip:sip:test at test.fi
>
> Frame 9 (448 bytes on wire, 448 bytes captured)
> Linux cooked capture
> Internet Protocol, Src: 127.0.0.1 (127.0.0.1), Dst: 127.0.0.1 (127.0.0.1)
> User Datagram Protocol, Src Port: qcp (5082), Dst Port: qcp (5082)
> Session Initiation Protocol
>     Request-Line: SUBSCRIBE sip:sip:test at test.fi SIP/2.0
>     Message Header
>         Via: SIP/2.0/UDP 127.0.0.1:5082;branch=z9hG4bK8d99.0df60be7.0
>         To: sip:sip:test at test.fi
>         From: <sip:jh at test.fi>;tag=374ba85b6c1b7e45caf839d18042c8ae-ec2b
>         CSeq: 10 SUBSCRIBE
>         Call-ID: 7bffc7ef-21244 at 127.0.0.1
>         Content-Length: 0
>         User-Agent: OpenSIPS (1.5.2-notls (i386/linux))
>         Max-Forwards: 70
>         Event: presence
>         Contact: <sip:rls at 127.0.0.1:5082>
>         Expires: 610
>
> No.     Time            Source                Destination           Protocol Info
>      10 15:53:46.956119 127.0.0.1             127.0.0.1             SIP      Status: 202 OK
>
> Frame 10 (423 bytes on wire, 423 bytes captured)
> Linux cooked capture
> Internet Protocol, Src: 127.0.0.1 (127.0.0.1), Dst: 127.0.0.1 (127.0.0.1)
> User Datagram Protocol, Src Port: qcp (5082), Dst Port: qcp (5082)
> Session Initiation Protocol
>     Status-Line: SIP/2.0 202 OK
>     Message Header
>         Via: SIP/2.0/UDP 127.0.0.1:5082;branch=z9hG4bK8d99.0df60be7.0
>         To: sip:sip:test at test.fi;tag=48de7c3cb9f0a00e953b10ae4e49e9de-3f5d
>         From: <sip:jh at test.fi>;tag=374ba85b6c1b7e45caf839d18042c8ae-ec2b
>         CSeq: 10 SUBSCRIBE
>         Call-ID: 7bffc7ef-21244 at 127.0.0.1
>         Expires: 610
>         Contact: <sip:127.0.0.1:5082>
>         Server: OpenSIPS (1.5.2-notls (i386/linux))
>         Content-Length: 0
>
> No.     Time            Source                Destination           Protocol Info
>      11 15:53:46.956273 127.0.0.1             127.0.0.1             SIP      Request: NOTIFY sip:rls at 127.0.0.1:5082
>
> Frame 11 (505 bytes on wire, 505 bytes captured)
> Linux cooked capture
> Internet Protocol, Src: 127.0.0.1 (127.0.0.1), Dst: 127.0.0.1 (127.0.0.1)
> User Datagram Protocol, Src Port: qcp (5082), Dst Port: qcp (5082)
> Session Initiation Protocol
>     Request-Line: NOTIFY sip:rls at 127.0.0.1:5082 SIP/2.0
>     Message Header
>         Via: SIP/2.0/UDP 127.0.0.1:5082;branch=z9hG4bK0f26.4e8e9573.0
>         To: <sip:jh at test.fi>;tag=374ba85b6c1b7e45caf839d18042c8ae-ec2b
>         From: <sip:sip at test.fi>;tag=48de7c3cb9f0a00e953b10ae4e49e9de-3f5d
>         CSeq: 1 NOTIFY
>         Call-ID: 7bffc7ef-21244 at 127.0.0.1
>         Content-Length: 0
>         User-Agent: OpenSIPS (1.5.2-notls (i386/linux))
>         Max-Forwards: 70
>         Event: presence
>         Contact: <sip:127.0.0.1:5082>
>         Subscription-State: pending;expires=610
>
> No.     Time            Source                Destination           Protocol Info
>      12 15:53:46.956465 127.0.0.1             127.0.0.1             SIP      Status: 404 Not found
>
> Frame 12 (378 bytes on wire, 378 bytes captured)
> Linux cooked capture
> Internet Protocol, Src: 127.0.0.1 (127.0.0.1), Dst: 127.0.0.1 (127.0.0.1)
> User Datagram Protocol, Src Port: qcp (5082), Dst Port: qcp (5082)
> Session Initiation Protocol
>     Status-Line: SIP/2.0 404 Not found
>     Message Header
>         Via: SIP/2.0/UDP 127.0.0.1:5082;branch=z9hG4bK0f26.4e8e9573.0
>         To: <sip:jh at test.fi>;tag=374ba85b6c1b7e45caf839d18042c8ae-ec2b
>         From: <sip:sip at test.fi>;tag=48de7c3cb9f0a00e953b10ae4e49e9de-3f5d
>         CSeq: 1 NOTIFY
>         Call-ID: 7bffc7ef-21244 at 127.0.0.1
>         Server: OpenSIPS (1.5.2-notls (i386/linux))
>         Content-Length: 0
>
> _______________________________________________
> Devel mailing list
> Devel at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/devel
>
>   




More information about the Devel mailing list