|
|||
|
|||
|
|||
|
Thanks John for the Reply.So if i understand properly :group 1 is here <sip:anonymous@group 2 is emptygroup 3 is ;tag=41008079_nab_FFFF_isp_FFFF_cco_FFFF_igo_FFFF_mgt_ 78DDthe previous expression is working for IPv4.Now for IPv6Input : From: <sip:anonymous@[2008:abcd:1234:2260:208:5dff:fe93:5b65]> ;tag=42006C96_nab_FFFF_isp_ FFFF_cco_FFFF_igo_FFFF_mgt_ 8092 subst('/^From:(.*)[2008:abcd:1234:2260:208:5dff:fe93:5b65]( .*)>(.*)/From:\1[2008:abcd: 1234:2260:20c:29ff:fe9a:b9cb]> \3/ig'); Output : From: <sip:anonymous@[2008:abcd:1234:2260:208:5dff:fe93:5b6[ 2008:abcd:1234:2260:20c:29ff: fe9a:b9cb]>;tag=42006C96_nab_ FFFF_isp_FFFF_cco_FFFF_igo_ FFFF_mgt_8092 //what is going wrong here? Heregroup 1 is <sip:anonymous@group 2 is emptygroup 3 is ;tag=42006C96_nab_FFFF_isp_FFFF_cco_FFFF_igo_FFFF_mgt_ 8092 what mistake am i making for IPv6 ? if you see the output.Regards,Mahesh.bOn Mon, Jul 2, 2018 at 6:54 PM John Petrini <jpetrini@coredial.com> wrote:______________________________They are references to groups in the regex match. The groups are in parenthesis. Whatever is matched by group 1 and 3 will be included in the substitution.https://regexr.com/ and https://regex101.com/ are both good sites for building and explaining regexes._________________
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr- users
_______________________________________________
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr- users