[Asterisk-Dev] [patch] Possible fix for subscribe bug.

Steve Davies davies147 at gmail.com
Fri May 13 07:17:08 MST 2005


Hi,

A couple of days ago I posted regarding SIP 'SUBSCRIBE's failing from
our snom190 phones here:
    http://lists.digium.com/pipermail/asterisk-users/2005-May/106545.html

I did some more analysis, and it seems that the problem is caused
because each of our phones REGISTERs as two or more users on the same
server (So that the user can choose an identity for outgoing calls)

This means that when a subscribe comes in, it calls to
check_user_full(...), which then calls find_peer(NULL,ip_address) -
the find_peer call was of course only returning ONE of the
registrations for that IP address.

The failure was due to an inability to authenticate the SUBSCRIBE, and
this was happening when the phone was trying to SUBSCRIBE using
credentials from "SIP/line1", and find_peer(...) was returning
credentials for the correct phone, but for "SIP/line2".

I have provided 2 versions of a simple patch, one against 1.0.7 and
once against CVS-HEAD, and would appreciate comments. I have given the
1.0.7 version some basic testing, and have found no obvious problems.

Thanks,
Steve
-------------- next part --------------
A non-text attachment was scrubbed...
Name: asterisk.chan_sip.107.patch
Type: text/x-patch
Size: 991 bytes
Desc: not available
Url : http://lists.digium.com/pipermail/asterisk-dev/attachments/20050513/cf0a460b/asterisk.chan_sip.107.bin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: asterisk.chan_sip.HEAD.patch
Type: text/x-patch
Size: 1136 bytes
Desc: not available
Url : http://lists.digium.com/pipermail/asterisk-dev/attachments/20050513/cf0a460b/asterisk.chan_sip.HEAD.bin


More information about the asterisk-dev mailing list