Benoit Panizzon
2019-Apr-16 11:44 UTC
[asterisk-users] pjsip vs chan_sip: Where is callerid(num) taken from?
Dear List We are renewing our voicemail server and by this occasion I am migrating from chan_sip to pjsip. I have come to a problem I have not experienced on other pjsip examples. Switzerland was heavily SS7 based in the past. So usually you have a Network provided A Number, which is mapped to the PAI Header in SIP. And there is the user provided phone number aka Generic Number, aka Display Number, which is to be displayed to the destination and which is transmitted in the From: Header. So the From: Number is the one we want as source of the call in the voicemail: With chan_sip: Set(Caller=${CALLERID(number)}) ${Caller} contains the number from the From: header With pjsip: ${Caller} contains the number from the PAI header Any clue how I can change this pjsip behavior? Mit freundlichen Grüssen -Benoît Panizzon- -- I m p r o W a r e A G - Leiter Commerce Kunden ______________________________________________________ Zurlindenstrasse 29 Tel +41 61 826 93 00 CH-4133 Pratteln Fax +41 61 826 93 01 Schweiz Web http://www.imp.ch ______________________________________________________
Benoit Panizzon
2019-Apr-16 11:54 UTC
[asterisk-users] pjsip vs chan_sip: Where is callerid(num) taken from?
Ok, just figured it out, looks like pjsip uses some reversed trust logic... PAI contains the network provided screened number, the one which can be trusted and used for billing purposes and similar. From contains the generic number, which should be displayed, but which is user provided and therefore not very trustworthy. So of course I want to trust the PAI (billing etc) and Display the From: header on the called phone. trust_id_inbound=yes But this causes the PAI Number to be filled in callerID(number) switching to 'no' causes the From Number, to be filled in callerID(number). Very odd! Mit freundlichen Grüssen -Benoît Panizzon- -- I m p r o W a r e A G - Leiter Commerce Kunden ______________________________________________________ Zurlindenstrasse 29 Tel +41 61 826 93 00 CH-4133 Pratteln Fax +41 61 826 93 01 Schweiz Web http://www.imp.ch ______________________________________________________