On Wed, Aug 2, 2017, at 10:39 AM, Carsten Bock wrote: > Hi, > > quick question: > I need to pass-through some headers from the A-Leg to the B-Leg, which > are connected using PJSIP. > Currently I do the following: > > [handler] > exten => addheader,1,GotoIf($["${ARG1}" == ""]?3) > exten => addheader,2,Set(PJSIP_HEADER(add,Route)=${ARG1}) > exten => addheader,3,GotoIf($["${ARG2}" == ""]?5) > exten => addheader,4,Set(PJSIP_HEADER(add,P-Charging-Vector)=${ARG2}) > exten => addheader,5,GotoIf($["${ARG3}" == ""]?7) > exten => addheader,6,Set(PJSIP_HEADER(add,P-Visited-Network-ID)=${ARG3}) > exten => addheader,7,GotoIf($["${ARG4}" == ""]?9) > exten => addheader,8,Set(PJSIP_HEADER(add,X-C-Params)=${ARG4}) > exten => addheader,9,GotoIf($["${ARG5}" == ""]?11) > exten => addheader,10,Set(PJSIP_HEADER(add,X-URI)=${ARG5}) > exten => addheader,11,Return > > [pcscf1] > exten => > _.,1,Dial(PJSIP/pcscf1/sip:${EXTEN}@${SIPDOMAIN},,b(handler^addheader^1,(${PJSIP_HEADER(read,Route)},${PJSIP_HEADER(read,P-Charging-Vector)},${PJSIP_HEADER(read,P-Visited-Network-ID)},${PJSIP_HEADER(read,X-C-Params)},${PJSIP_HEADER(read,X-URI)}))) > > This works, but you'll have to admit, it's not the most > readable-Version of an extensions.conf. > > Are there any better solutions around?
Not really. > > Thanks, > Carsten > > P.S.: I may have found an issue in Asterisk 13.x (LTS); if I send the > right SIP-Message I can make it crash. I'm currently verifying, if it > still happens with the latest 13.x release from GIT. If I can confirm > it with the latest 13.x from GIT, should I post my findings to the > dev-list or is there some security mailing list, as this would apply > to all installations around there? The process for reporting security vulnerabilities is documented on the wiki[1]. [1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+Security+Vulnerabilities -- Joshua Colp Digium, Inc. | Senior Software Developer 445 Jan Davis Drive NW - Huntsville, AL 35806 - US Check us out at: www.digium.com & www.asterisk.org -- _____________________________________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- Check out the new Asterisk community forum at: https://community.asterisk.org/ New to Asterisk? Start here: https://wiki.asterisk.org/wiki/display/AST/Getting+Started asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users