2009/4/7 Olle E. Johansson <o...@edvina.net>: > [snip] > > The REGISTER request in the RFC was really written for a device. > The way providers use it for trunks with multiple DIDs is outside of the > RFC and is discussed in relation to the SIPconnect specification in > the SIP forum. > > Some providers solve this by not using the Contact: in the register > request at all for the calls, instead guessing a URI with the DID > in the user name part, something that breaks communication > even more as the Contact might include other hints on call routing > internally, like line button in a SNOM phone. > > I would say that the only way right now is to parse the To: header. > I started working on some code a while ago that would handle > this better, but never completed it. We simply registered a random > string and then replaced it with whatever was sent in the To: header > (which should be the original destination) before hitting the dialplan. > That code still exists in a branch somewhere and in Pineapple. > > This code would also solve the issue with registering multiple > accounts with one provider. > /O >
Thanks Olle, as always, a useful response :) In the meantime, I suspect that the following is the current dialplan based workaround for calls that come in to 's' because of a default Registration Contact? [default] exten => s,1,Set(DN=${SIP_HEADER(TO):5}) exten => s,n,Set(DN=${CUT(DN,@,1)}) exten => s,n,GotoIf($["${DN}" = "s"]?:default,${DN},1) exten => s,n,Hangup() Comments or improvements anyone? Thanks again. Steve _______________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users