[sr-dev] [kamailio/kamailio] cannot parse From header (#2723)

Wolfgang Kampichler notifications at github.com
Sun May 2 17:01:29 CEST 2021


lost module uses the standard header parsing function. `lost_get_from_header` is just a wrapper function to return a string pointer and uses `parse_headers`, which in your case returns an error. I did use the sipp example but had no header parsing issues, see below (OS: alpine:latest docker image)
```
6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} <script>: ### ESRP - INVITE request received 
Sock: tcp:172.16.16.176:38763
From: sip:sipp at 127.0.0.1:2345
To:   sip:service at 127.0.0.1:5060
###
 6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} <script>: INVITE urn:service:sos SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:2345;branch=z9hG4bK-7655-1-0
From: sipp <sip:sipp at 127.0.0.1:2345>;tag=7655SIPpTag001
To: service <sip:service at 127.0.0.1:5060>
Call-ID: 1-7655 at 127.0.0.1
CSeq: 1 INVITE
Contact: sip:sipp at 127.0.0.1:2345
Max-Forwards: 70
Subject: Performance Test
Content-Type: application/sdp
Content-Length:   129

v=0
o=user1 53655765 2353687637 IN IP4 127.0.0.1
s=-
c=IN IP4 127.0.0.1
t=0 0
m=audio 6000 RTP/AVP 0
a=rtpmap:0 PCMU/8000

 6(13) WARNING: {1 1 INVITE 1-7655 at 127.0.0.1} lost [functions.c:257]: lost_held_function(): P-A-I header not found, trying From header ...
 6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} lost [functions.c:271]: lost_held_function(): ### HELD id [sip:sipp at 127.0.0.1:2345]
 6(13) WARNING: {1 1 INVITE 1-7655 at 127.0.0.1} lost [functions.c:480]: lost_held_function(): locationRequest error response: [locationUnknown]
 6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} <script>: ### ESRP - held request failed
 6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} <script>: ### ESRP - held request returned err:
locationUnknown
 6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} <script>: ### ESRP - service urn received
 6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} <script>: INVITE urn:service:sos SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:2345;branch=z9hG4bK-7655-1-0
From: sipp <sip:sipp at 127.0.0.1:2345>;tag=7655SIPpTag001
To: service <sip:service at 127.0.0.1:5060>
Call-ID: 1-7655 at 127.0.0.1
CSeq: 1 INVITE
Contact: sip:sipp at 127.0.0.1:2345
Max-Forwards: 69
Subject: Performance Test
Content-Type: application/sdp
Content-Length:   129

v=0
o=user1 53655765 2353687637 IN IP4 127.0.0.1
s=-
c=IN IP4 127.0.0.1
t=0 0
m=audio 6000 RTP/AVP 0
a=rtpmap:0 PCMU/8000

 6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} <script>: ###
 6(13) INFO: {1 1 INVITE 1-7655 at 127.0.0.1} lost [functions.c:891]: lost_function(): ### LOST urn        [urn:service:sos]
 6(13) ERROR: {1 1 INVITE 1-7655 at 127.0.0.1} lost [functions.c:923]: lost_function(): geolocation header not found
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2723#issuecomment-830822660
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20210502/e3d3f8c0/attachment.htm>


More information about the sr-dev mailing list