Morten Isaksen
2006-Jun-27 06:00 UTC
[Asterisk-Users] Problem with callerid in sip to isdn gateway
Hi! I have this setup: PABX <--ISDN30--> Asterisk 1 <--SIP--> Asterisk 2 <--ISDN30--> TELCO Digium TE410P is used in both Asterisk 1 and 2. When I set the CLIR bit on the PABX the Callerid / ANI is removed somewhere between the SIP interface on Asterisk 1 and the SIP interface on Asterisk 2. I need the callerid / ANI on Asterisk 2 in order for the TELCO to bill me correctly. Is there any way I can tell Asterisk 1 to keep the callerid and the clir bit, and then let Asterisk 2 deal with it? -- Morten Isaksen http://www.misak.dk/blog/ -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060627/905f3863/attachment.htm
trixter aka Bret McDanel
2006-Jun-27 06:28 UTC
[Asterisk-Users] Problem with callerid in sip to isdn gateway
On Tue, 2006-06-27 at 15:00 +0200, Morten Isaksen wrote:> Hi! > > I have this setup: > > PABX <--ISDN30--> Asterisk 1 <--SIP--> Asterisk 2 <--ISDN30--> TELCO > > Digium TE410P is used in both Asterisk 1 and 2. > > When I set the CLIR bit on the PABX the Callerid / ANI is removed > somewhere between the SIP interface on Asterisk 1 and the SIP > interface on Asterisk 2. >Have you used a packet sniffer to ensure that its actually sent to asterisk 2? If it isnt then that may be the entire problem. Before trying to diagnose anything on the isdn side I would make sure that it is infact being sent correctly. Alternatively you can try some noops() on asterisk2 for when a call is received to display the caller id to the console, that may be easier for some than reading sip headers.>-- Trixter http://www.0xdecafbad.com Bret McDanel Belfast IE +44 28 9099 6461 DE +49 801 777 555 3402 Utrecht NL +31 306 553058 US WA +1 360 207 0479 US NY +1 516 687 5200 FreeWorldDialup: 635378 http://www.trxtel.com the VoIP provider that pays you! -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part Url : http://lists.digium.com/pipermail/asterisk-users/attachments/20060627/6bd4a651/attachment.pgp
Morten Isaksen
2006-Jun-28 01:53 UTC
[Asterisk-Users] Problem with callerid in sip to isdn gateway
On 6/27/06, trixter aka Bret McDanel <trixter@0xdecafbad.com> wrote:> > On Tue, 2006-06-27 at 15:00 +0200, Morten Isaksen wrote: > > Hi! > > > > I have this setup: > > > > PABX <--ISDN30--> Asterisk 1 <--SIP--> Asterisk 2 <--ISDN30--> TELCO > > > > Digium TE410P is used in both Asterisk 1 and 2. > > > > When I set the CLIR bit on the PABX the Callerid / ANI is removed > > somewhere between the SIP interface on Asterisk 1 and the SIP > > interface on Asterisk 2. > > > Have you used a packet sniffer to ensure that its actually sent to > asterisk 2? If it isnt then that may be the entire problem. Before > trying to diagnose anything on the isdn side I would make sure that it > is infact being sent correctly. Alternatively you can try some noops() > on asterisk2 for when a call is received to display the caller id to the > console, that may be easier for some than reading sip headers.On Asterisk 1 the ${CALLERID(num)} is correct but on Asterisk 2 CALLERID(num) is set to "Unknown" if CALLINGPRES=32. If CALLINGPRES=0 then the CALLERID(num) is passed to Asterisk 2. I have solved the problem this way: On Asterisk 1: exten => _[2-9]XXXXXXX,1,sipaddheader(x-clir: ${CALLINGPRES}) exten => _[2-9]XXXXXXX,n,setcallerpres(allowed_not_screened) exten => _[2-9]XXXXXXX,n,dial(SIP/${EXTEN}@sipsrv2) On Asterisk 2: exten => _X.,n,set(CLIR=${SIP_HEADER(x-clir)}) exten => _X.,n,gotoif($[$[${CLIR}=32]]?NOCID:CID) exten => _X.,n(NOCID),SetCallerPres(prohib_not_screened) exten => _X.,n(CID),dial(ZAP/g2/${EXTEN}) -- Morten Isaksen http://www.misak.dk/blog/ -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060628/adb3faf1/attachment.htm