[asterisk-dev] [Code Review] SIP: peer matching bycallbackextension
Olle E. Johansson
oej at edvina.net
Fri Aug 28 12:13:56 CDT 2009
28 aug 2009 kl. 18.56 skrev Klaus Darilion:
>
>
> Olle E. Johansson schrieb:
>> 28 aug 2009 kl. 12.40 skrev Nick Lewis:
>>
>>> oej
>>>
>>>> I think we have to solve this differently. When we register, we
>>>> don't
>>>> register the extension as a contact, we generate a unique random
>>>> string. When the call comes back, the random string will be the
>>>> request URI and we can match on that. I actually have code for that
>>>> somewhere.
>>> I do not see the advantage of a unique random string. I suggest a
>>> different unique string - the peername.
>> Well, not all registrations is based on a peer. And you can have
>> multiple registrations for a peer.
>>
>>>> What messes that up is that you know frequently have registrations
>>>> for
>>>> SIP trunks where you won't get the contact back in the request URI,
>>>> which messes things up.
>>> I have also experienced some trunk providers that make this mistake.
>>> They tend to send the username back instead. In these cases I simply
>>> name the peer after the username. This does not clash with other
>>> peernames on the system because client peers have shorter names e.g.
>>> [101] and trunk peers typically have usernames that are PSTN numbers
>>> e.g. [442920500718] and hence unique.
>> Well, you should not have phone numbers as device identifiers. That's
>> a topic you can read ton of mails about in asterisk-users if you
>> need an
>> explanation.
>>
>> Check the draft by Hadriel Kaplan about this kind of registration,
>> something that's connected with the work for the new SIPconnect spec.
>
> Hi Olle!
>
> What's the draft name?
Google "draft kaplan registration" - first hit:
http://tools.ietf.org/html/draft-kaplan-dispatch-sip-implicit-registrations-00
/O :-)
More information about the asterisk-dev
mailing list