[asterisk-bugs] [JIRA] (ASTERISK-27996) Header matching doesn’t work on an inbound registration
Richard Mudgett (JIRA)
noreply at issues.asterisk.org
Mon Jul 30 07:36:54 CDT 2018
[ https://issues.asterisk.org/jira/browse/ASTERISK-27996?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=244325#comment-244325 ]
Richard Mudgett commented on ASTERISK-27996:
--------------------------------------------
There are two things currently wrong with how you are using the match_header option:
# It is documented that the value needs to match the received header value \[1]. This is implying that it *must* be the whole value of the header and the header contents cannot *change*. The From and To headers do not have this characteristic.
# The option only matches generic headers which are not used by SIP for its operation ASTERISK-27548. The option was originally added to identify endpoints that add their own custom header for identification purposes. E.g., match_header=X-my-custom-header: This is my identifying string
The patch up for review for ASTERISK-27548 addresses both of these so you could do what you want.
# It adds regular expression support so you don't have to know beforehand the entire contents of the header value.
# It allows specifying any type of header.
\[1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+13+Configuration_res_pjsip_endpoint_identifier_ip
> Header matching doesn’t work on an inbound registration
> -------------------------------------------------------
>
> Key: ASTERISK-27996
> URL: https://issues.asterisk.org/jira/browse/ASTERISK-27996
> Project: Asterisk
> Issue Type: Bug
> Security Level: None
> Components: pjproject/pjsip
> Affects Versions: 13.21.1
> Reporter: Edvin Vidmar
> Severity: Minor
> Labels: pjsip, webrtc
> Attachments: output.txt, pjsip.conf
>
>
> Hi,
> I try to register webrtc client with identify set to header but it doesn’t work. I have attached pjsip.conf and asterisk cli output.
> From configuration you can see that match_header is set to ‘From-WebRTC: 2000’ and from sip log you can see From-WebRTC header is set correctly, but I always get following error:
> res_pjsip_registrar.c:967 find_registrar_aor: AOR ‘’ not found for endpoint ‘2000-webrtc’
> Error says that AOR ‘’ is not found, but from config you can see that AOR is set and also if I check in asterisk cli it all looks OK.
> Also if I change identify_by=header to identify_by=username it works ok. So it looks like problem with header identification.
> br
> edvin
--
This message was sent by Atlassian JIRA
(v6.2#6252)
More information about the asterisk-bugs
mailing list