I don't think you're doing anything wrong. I think I found the same thing, that headers on the reply were available only in a reply route and not in a failure route. If you know where to look for them to populate the AVP, I suppose it doesn't matter much.
I haven't looked at the code but I suspect all the routes other than an onreply_route give you access to the requests headers, and onreply_route gives you access to the reply headers. Makes sense I guess. - Jeff On Tue, Jun 1, 2021 at 9:31 AM David Villasmil < [email protected]> wrote: > Thanks Jeff, > > MMM, that's strange, I was using it on failure route and the route was > being executed, but the data wasn't there. I put it on the onreply route > and that one is now executed with the data correctly there... > > I probably did something wrong. > > Thanks again Jeff! > > Regards, > > David Villasmil > email: [email protected] > phone: +34669448337 > > > On Tue, Jun 1, 2021 at 12:37 PM Jeff Pyle <[email protected]> wrote: > >> In which route are you trying to use if (is_present_hf("Identity"))? >> Since the 302 is both a reply and a "failure", I suggest seeing if it >> appears in either the armed onreply_route or failure_route. >> >> I think From is available because it was present in the original request >> route. >> >> >> - Jeff >> >> On Tue, Jun 1, 2021 at 5:39 AM David Villasmil < >> [email protected]> wrote: >> >>> Anyone has any idea about this? Appreciate your help. >>> >>> On Mon, 31 May 2021 at 21:11, David Villasmil < >>> [email protected]> wrote: >>> >>>> So weird, >>>> I can get the From header, but not "Identity"... >>>> >>>> Regards, >>>> >>>> David Villasmil >>>> email: [email protected] >>>> phone: +34669448337 >>>> >>>> >>>> On Mon, May 31, 2021 at 8:22 PM David Villasmil < >>>> [email protected]> wrote: >>>> >>>>> This is really weird, >>>>> >>>>> if (is_present_hf("Identity")) >>>>> >>>>> says it is not present, but it is! >>>>> >>>>> Regards, >>>>> >>>>> David Villasmil >>>>> email: [email protected] >>>>> phone: +34669448337 >>>>> >>>>> >>>>> On Mon, May 31, 2021 at 7:47 PM David Villasmil < >>>>> [email protected]> wrote: >>>>> >>>>>> Hello Guys, >>>>>> >>>>>> I'm getting a header on a 302 which i'm trying to get, but for some >>>>>> reason I can't. >>>>>> >>>>>> This is an example 302: >>>>>> >>>>>> 2021/05/31 18:42:36.499157 10.231.32.237:5060 -> 10.231.57.11:6075 >>>>>> SIP/2.0 302 Redirect >>>>>> Via: SIP/2.0/UDP 1.2.3.4: >>>>>> 6075;branch=z9hG4bKd8e8.50036ee6.0;received=10.231.57.11 >>>>>> Via: SIP/2.0/UDP >>>>>> 10.231.33.135;branch=z9hG4bKd8e8.fe2738f41d26b2b68328691c326a077a.0 >>>>>> v:SIP/2.0/UDP 10.231.49.211:6060 >>>>>> ;received=10.231.49.211;rport=6060;branch=z9hG4bK68SgceeareaUa >>>>>> f:"+18883333333"<sip:[email protected]>;tag=ZBQ713X9pgD5S >>>>>> t:<sip:[email protected] >>>>>> >;tag=9dd61ff61e802d8e2bef5f14621ef3c2.50cf6b6c >>>>>> i:cf649a38-3ce2-123a-eaad-122eaa5d9655 >>>>>> CSeq:36689486 INVITE >>>>>> Identity: >>>>>> eyJhbGciOiJFUzI1NiIsInBwdCI6InNoYWtlbiIsInR5cCI6InBhc3Nwb3J0IiwieDV1IjoiaHR0cHM6Ly9vcHMtc3RhdGljLnMzLmFtYXpvbmF3cy5jb20vc3Rpci1zaGFrZW4vZWMyNTYtcHVibGljLnBlbSJ9.eyJhdHRlc3QiO >>>>>> >>>>>> BIiwiZGVzdCI6eyJ0biI6WyIxNzg2NDEwNzgzNyJdfSwiaWF0IjoxNjIyNDg2NTU2LCJvcmlnIjp7InRuIjoiKzEzMTU5ODUyNTk0In0sIm9yaWdpZCI6IjhlZGE4M2Q1LWY1MjEtNDQzZC1iNDI0LWIzNDQ3MDc4ZjYxZCJ9.cjIz9VwlS9_6qA >>>>>> >>>>>> 6mmDgottk41BLpQcA40HdvV_6jAPqQ1EIL3_jLWl25oHeVEWOzTMhcERp4Jn-JZ4vP_n3w;info=< >>>>>> https://somedomain.com/stir-shaken/ec256-public.pem >>>>>> >;alg=ES256;ppt=shaken >>>>>> Server: kamailio (5.5.0 (x86_64/linux)) >>>>>> Content-Length: 0 >>>>>> >>>>>> I'm trying to get the "Identity" header with: >>>>>> >>>>>> $avp(identity_header) = $(hdr(Identity)); >>>>>> >>>>>> But It's coming up <null> >>>>>> >>>>>> Any ideas of what I'm doing wrong? >>>>>> >>>>>> Regards, >>>>>> >>>>>> David Villasmil >>>>>> email: [email protected] >>>>>> phone: +34669448337 >>>>>> >>>>> -- >>> Regards, >>> >>> David Villasmil >>> email: [email protected] >>> phone: +34669448337 >>> _______________________________________________ >>> Users mailing list >>> [email protected] >>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users >>> >> _______________________________________________ >> Users mailing list >> [email protected] >> http://lists.opensips.org/cgi-bin/mailman/listinfo/users >> > _______________________________________________ > Users mailing list > [email protected] > http://lists.opensips.org/cgi-bin/mailman/listinfo/users >
_______________________________________________ Users mailing list [email protected] http://lists.opensips.org/cgi-bin/mailman/listinfo/users
