[asterisk-users] Retaining P-Asserted Info

Markus universe at truemetal.org
Sun Feb 16 14:05:48 CST 2014

Am 16.02.2014 03:30, schrieb Nick Cameo:
> Tried setting `sendrpid = yes` and still same problem. We really don't want to
> have to `SipAddHeader` as it is already being formed by our switch.

 From http://www.voip-info.org/wiki/view/Asterisk+SIP+trustrpid :


Asterisk does nothing when it receives a P-Asserted-Identity header. It 
ignores it totally no matter what settings you use for "trustrpid" or 
"sendrpid". It does not copy it from an inbound call leg to an outbound 
call leg for a bridged SIP-to-SIP call.


I use SIPAddHeader to achieve what you described.

For example, I have a DID provider who only sends P-Asserted-Identity, 
and at the same time a customer who needs that data as Remote-Party-ID, 
so I'm doing this to send it to him:

exten => _X.,n,Set(RPID=${SIP_HEADER(P-Asserted-Identity)})
exten => _X.,n,Set(RPID=${CUT(RPID,\+,2-)})
exten => _X.,n,Set(RPID=${CUT(RPID,@,-1)})
exten => _X.,n,SIPAddHeader(Remote-Party-ID: "${RPID}" 

More information about the asterisk-users mailing list