P-Attestation-Indicator

kenn10

Member
Sep 11, 2018
87
21
8
69
Is anyone parsing out the attestation headers so that if the P-Attestation-Indicator is blank or "c" types the call can be sent to another destination than the called number? I'm sick of the calls from Cinch-family of companies that so far are 100% spam. I'd like to know how to achieve this in FS PBX.
 
Last edited:
@pbxgeek Any ideas about this? Dial plan mods aren't too difficult but I'm not sure how to capture the P-Attestation-Indicator from the SIP Invite from my carrier. FS PBX is beginning to resemble less of FusionPBX so I don't know what is legit on your system for extracting SIP Invite data. The data is there when I run sngrep.

Code:
2026/06/18 07:28:59.025582 76.8.29.198:5060 -> <my IP>:5080
INVITE sip:8284827213@<my IP>:5080;transport=udp;gw=6eb1b475-b27a-411f-97d4-e89b7b4ab341 SIP/2.0
Via: SIP/2.0/UDP 76.8.29.198:5060;branch=z9hG4bKkpd95d106gbgg9r560p0.1
From: "WIRELESS CALLER" <sip:770313xxxx@76.8.29.198:5060>;tag=gK082f41ee
To: <sip:82848xxxxx@<my IP>>
P-Asserted-Identity: "WIRELESS CALLER" <sip:770313xxxx;verstat=TN-Validation-Passed@76.8.29.198:5060>
P-Attestation-Indicator: A
P-Origination-ID: FFFFFFFF-FFFF-FFFF-FFFF-010100000000
P-Charge-Info: tel:182848xxxxx;Rate=0.0003;Trk=trunk3
 
Hi @kenn10, you can use Dialplan Manager or a Lua script.
Yeah. With a little AI help, I worked it out. It was just a dial plan addition. Capturing the attestation level is pretty straight forward. I didn't need to do any LUA work. Land lines still don't send attestation and I'm in an area where there are still mostly landlines. The spammers and scammers are now using remote banks of land lines.

This is the initial XML where I capture the attestation and write it to the log. I'm still deciding how to handle blank, null or level "C" attestations for call routing purposes in that I need to decide whether to send to voice mail or flat out reject the call.

Code:
<extension name="STIR-Shaken_Attestation_Check" continue="true" uuid="4d52f38e-90f6-4643-9b1a-01c16f3f454c">
    <condition field="destination_number" expression="^.*$"/>
    <condition field="${call_direction}" expression="inbound">
        <action application="set" data="attestation_level=${sip_h_P-Attestation-Indicator}"/>
        <action application="log" data="&quot;NOTICE --- Found Attestation Level: ${sip_h_P-Attestation-Indicator} ---&quot;"/>
    </condition>
</extension>