Getting P-Asserted-Identity for outbound calls working

Hi, have FreePBX 16 with Asterisk 16.8.
When trying to dial UK phone numbers they fail because the carrier used has written

Your INVITE does not contain a P-Asserted-Identity: header in +E164 format which is Mandatory to call the UK & will be mandatory for all countries after the 16th January 2023

I have checked our extensions and all have Send RPID set to Send P-Asserted-Identity header.
The outbound CallerID for all extensions is set to “SOME NAME” <+1xxxxxxxxxx> which I think is +E164 format.

Can someone help me out with this? Have done some searching on how to get this working but have not as yet found a document to get P-Asserted-Identity working.

Thanks.

It’s the trunk that needs this setting.

Hi Stewart,
Thanks for pointing out trunk settings. Now able to make the calls to UK because P-Asserted-Identity is sent.

Bria mobile has a 0 key which when pressed and held 0 key turns 0 to +. In the trunk settings tried to Prefix ‘+’ but when dialing the UK number the ‘+’ doesn’t get stripped out. It dials:
Called PJSIP/0011101+44786879XXXX@
the call fails. It should send without the ‘+’
Prepended number is in front of the ‘+’.The Prepend is added from the outbound route settings

Thanks.

Outbound Route:

PJSIP Trunk:

Also tried removing Prefix + from pjsip trunk and place it in outbound route. Same issue. The ‘+’ is not stripped out and the call fails.

So the question is, how to remove the ‘+’ when number is sent to carrier?
Thanks.

When using the prefix field to strip characters, the match pattern is defined as the string that remains after the prefix is removed, which in this case means there should not be a + character in the match pattern. The rule as you’ve written it would only act on dial strings with two leading + characters, one of which would be stripped.

Hi Igaetz,
Then how is one to dial +XX and remove the +?

I have tried all kinds of combo’s between outbound route and trunk including removing the + in the match pattern. Most simply drop the call with
INVITE sip:+44786879XXXX
‘+44786879XXXX’ rejected because extension not found in context ‘from-internal’

Thanks.

That sounds like you don’t have a corresponding dial pattern in an outbound route.

A generic dial pattern that will strip the leading + char would be:

The single dot in the match pattern field will match any sequence.

prepend (blank)
prefix +
match pattern 44.
should do what you want if the provider accepts (for example) 442071234567

If they require 02071234567 then
prepend 0
prefix +44
match pattern XX.

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.