[OpenSIPS-Users] $ai transformation

Ehrny y at jettel.ru
Mon Nov 14 12:03:34 CET 2016


Hi, Răzvan,
Very helpful,
Thank you very much.
Best Regards,
Ehrny

From: users-bounces at lists.opensips.org [mailto:users-bounces at lists.opensips.org] On Behalf Of Razvan Crainea
Sent: Monday, November 14, 2016 11:03 AM
To: users at lists.opensips.org
Subject: Re: [OpenSIPS-Users] $ai transformation

Hi, Ehrny!

Yes, you can transform the P-Asserted-Identity header as you wish, by dropping the existing one and creating a new one. Use the remove_hf()[1] and append_hf()[2] headers for that, i.e.:

if (is_present_hf("P-Asserted-Identity")) {
    remove_hf("P-Asserted-Identity");
    $avp(rpid) = "new-header";
    append_hf("P-Asserted-Identity: $avp(rpid) <sip:$avp(rpid)@opensips.org><mailto:sip:$avp(rpid)@opensips.org>\r\n");
}

[1] http://www.opensips.org/html/docs/modules/2.2.x/sipmsgops.html#id293937
[2] http://www.opensips.org/html/docs/modules/2.2.x/sipmsgops.html#id249696

Best regards,


Răzvan Crainea

OpenSIPS Solutions

www.opensips-solutions.com<http://www.opensips-solutions.com>
On 11/13/2016 08:55 PM, Ehrny wrote:
Hello team,
I’m trying to follow my carrier’s request to transform P-Asserted-Identity header.
Is there any possibilities to do that on the fly with opensips (v2.2.2)?
Yet another project assume to add the redirecting number even if it’s not exists. Would it be possible to add it in the route?
Your help is really appreciated,

Best Regards,
Ehrny






_______________________________________________

Users mailing list

Users at lists.opensips.org<mailto:Users at lists.opensips.org>

http://lists.opensips.org/cgi-bin/mailman/listinfo/users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20161114/4e8cd92e/attachment.htm>


More information about the Users mailing list