Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to remove tel: URI from PAI Header

Status
Not open for further replies.

LordJeffers

Systems Engineer
Jun 16, 2020
1
GB
I was wondering if anyone knew of a sigma script that will remove the tel URL from the PAI? I have been trying and even tried replacing it but the tel: just gets repositioned.

|INVITE sip:+441213937200@10.36.90.200:5060 SIP/2.0
|From: <sip:+447968601547@10.32.250.55>;tag=gK02336489
|To: <sip:+441213937200@10.36.90.200>
|CSeq: 22064 INVITE
|Call-ID: 1359127851_111651496@10.32.250.55
|Contact: <sip:+447968601574@10.32.250.55:5060>
|Allow: INVITE,ACK,CANCEL,BYE,REGISTER,REFER,INFO,SUBSCRIBE,NOTIFY,PRACK,UPDATE,OPTIONS
|Supported: timer,100rel
|Max-Forwards: 61
|Via: SIP/2.0/UDP 10.32.250.55:5060;branch=z9hG4bK02B393b06bb2f9754ce
|Accept: application/sdp, application/isup, application/dtmf, application/dtmf-relay, multipart/mixed
|P-Asserted-Identity: <sip:+447968601547@213.121.52.77>, <tel:+447968601547>
|Session-Expires: 1800
|Min-SE: 90
|Content-Disposition: session; handling=required
|Content-Type: application/sdp
|Content-Length: 233
 
I think in the server interworking profile there's an option to switch it.

Here might be a good guess though. Remove PAI. Copy Contact to PAI.

Often you need to sigma script the diversion header to overwrite the PAI. In a scenario of call forwarding, diversion is the original called party and PAI is the original calling party and some carriers don't want to see a PAI of a number that's not on your trunks.

within session "INVITE"
{
/*Look for INVITE messages only.*/
act on request where %DIRECTION="OUTBOUND" and %ENTRY_POINT="POST_ROUTING" and %METHOD="INVITE"
{
/*Look for the PAI Header, and if it exist, remove it.*/
if(exists(%HEADERS["p-asserted-identity"][1]))then
{
remove(%HEADERS["p-asserted-identity"][1]);
{
%var1 = %HEADERS["Contact"][1].URI.USER;
%var2 = %HEADERS["Contact"][1].DISPLAY_NAME;

%HEADERS["P-Asserted-Identity"][1].URI.USER = %var1;
%HEADERS["P-Asserted-Identity"][1].DISPLAY_NAME = %var2;
}


}
}
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top