The Dial() presentation options seem to be kind of broken when it comes to how they pass on the presentation.
Private presentation in SIP is conventionally denoted by a header like the following:
From: "Anonymous" <sip:[email protected]>;tag=23963b45-01bf-48c9-92b7-fd64fd9469ab
While presentation tends to be poorly supported in SIP due to SIP lacking a mechanism for conveying this information explicitly to Class 5 endpoints, the above is the most standard way.
Likewise, carrier grade SIP equipment uses the following convention for unavailable presentation:
From: <sip:O@SERVER-IP-ADDRESS>;tag=4ef38964-4a13-448b-ae7f-e9c8996b1cfe
Grandstream has recently updated their firmware to support presentation properly according to these specifications (HT firmware 1.0.55.x). Some carrier grade equipment like Adtrans that support SIP have done it this way for a while.
Private presentation in SIP with Asterisk "just works", but for unavailable presentation, we currently have to do the following:
same => n,Set(CALLERID(num)=O)
same => n,Set(CALLERID(name)=)
i.e. when dialing a SIP endpoint (but ONLY SIP endpoints, not DAHDI endpoints!), the following logic is required for the presentation to be displayed correctly:
same => n,If($["${CALLERID(pres)}"="unavailable"])
same => n,Set(CALLERID(num)=O)
same => n,Set(CALLERID(name)=)
same => n,EndIf()
Hence, a patch is required to automatically modify the From header as needed when the presentation is unavailable, so that it "just works", and SIP endpoints do not need special treatment and logic.
You must be