[asterisk-bugs] [JIRA] (ASTERISK-28393) Multidomain support issue
Kevin Harwell (JIRA)
noreply at issues.asterisk.org
Tue Apr 23 12:07:47 CDT 2019
[ https://issues.asterisk.org/jira/browse/ASTERISK-28393?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=246989#comment-246989 ]
Kevin Harwell commented on ASTERISK-28393:
------------------------------------------
I was able to replicate this issue. It appears that when Asterisk is building the "from" address (_sip_dialog_create_from_ in _res_pjsip.c_):
{noformat}
from->ptr = pj_pool_alloc(pool, PJSIP_MAX_URL_SIZE);
from->slen = pj_ansi_snprintf(from->ptr, PJSIP_MAX_URL_SIZE,
"<sip:%s@%s%.*s%s:%d%s%s>",
user,
(type & PJSIP_TRANSPORT_IPV6) ? "[" : "",
(int)local_addr.slen,
local_addr.ptr,
(type & PJSIP_TRANSPORT_IPV6) ? "]" : "",
local_port,
(type != PJSIP_TRANSPORT_UDP && type != PJSIP_TRANSPORT_UDP6) ? ";transport=" : "",
(type != PJSIP_TRANSPORT_UDP && type != PJSIP_TRANSPORT_UDP6) ? pjsip_transport_get_type_name(type) : "");
{noformat}
the _user_ portion in this scenario is the endpoint name (1000 at sip20.voztovoice.org), and the _local_addr_ is derived from the transport or system.
In any case the final result contains two '@' characters in the from header, which gets passed into _pjsip_endpt_create_request_. The underlying pjsip parsing algorithm then fails to parse the header due to it containing two '@' characters, thus failing to create the request.
> Multidomain support issue
> -------------------------
>
> Key: ASTERISK-28393
> URL: https://issues.asterisk.org/jira/browse/ASTERISK-28393
> Project: Asterisk
> Issue Type: Bug
> Security Level: None
> Components: Channels/chan_pjsip
> Affects Versions: 13.26.0, 16.3.0
> Environment: Centos 7
> Reporter: Andrea Sannucci
> Labels: pjsip
> Attachments: pjsip-debug.txt
>
>
> I'm Trying to configure PJSIP in a multi domain escenario. My Endpoint configuration is:
> [1000 at sip20.voztovoice.org]
> type=endpoint
> context=externas-pjsip
> disallow=all
> allow=ulaw,g722
> accountcode=1000
> language=es
> mailboxes=1000 at default
> dtmf_mode=rfc4733
> callerid=Fulano <1000>
> direct_media=no
> force_rport=yes
> rtp_symmetric=yes
> rewrite_contact=yes
> call_group=1
> pickup_group=1
> transport=no-nat
> auth=aut1000
> aors=1000
> [aut1000]
> type=auth
> auth_type=userpass
> password=password
> username=1000
> [1000]
> type=aor
> max_contacts=1
> remove_existing=yes
> qualify_frequency=30
> When I register a Softphone (XLITE) on the Asterisk console i can see:
> -- Added contact 'sip:1000 at 93.41.37.15:64331;rinstance=9ef93b2b70945db5' to AOR '1000' with expiration of 600 seconds
> [2019-04-22 12:20:29] ERROR[631]: res_pjsip.c:3874 create_out_of_dialog_request: Unable to create outbound NOTIFY request to endpoint 1000 at sip20.voztovoice.org
> [2019-04-22 12:20:29] WARNING[631]: res_pjsip_mwi.c:503 send_unsolicited_mwi_notify_to_contact: Unable to create unsolicited NOTIFY request to endpoint 1000 at sip20.voztovoice.org URI sip:1000 at 93.41.37.15:64331;rinstance=9ef93b2b70945db5
> [2019-04-22 12:20:29] ERROR[6447]: res_pjsip.c:3874 create_out_of_dialog_request: Unable to create outbound OPTIONS request to endpoint 1000 at sip20.voztovoice.org
> [2019-04-22 12:20:29] ERROR[6447]: res_pjsip/pjsip_options.c:877 sip_options_qualify_contact: Unable to create request to qualify contact sip:1000 at 93.41.37.15:64331;rinstance=9ef93b2b70945db5 on AOR 1000
> -- Removed contact 'sip:1000 at 93.41.37.15:64331;rinstance=9ef93b2b70945db5' from AOR '1000' due to request
> == Contact 1000/sip:1000 at 93.41.37.15:64331;rinstance=9ef93b2b70945db5 has been deleted
> -- Added contact 'sip:1000 at 93.41.37.15:64331;rinstance=9ef93b2b70945db5' to AOR '1000' with expiration of 600 seconds
> [2019-04-22 12:20:29] ERROR[631]: res_pjsip.c:3874 create_out_of_dialog_request: Unable to create outbound NOTIFY request to endpoint 1000 at sip20.voztovoice.org
> [2019-04-22 12:20:29] WARNING[631]: res_pjsip_mwi.c:503 send_unsolicited_mwi_notify_to_contact: Unable to create unsolicited NOTIFY request to endpoint 1000 at sip20.voztovoice.org URI sip:1000 at 93.41.37.15:64331;rinstance=9ef93b2b70945db5
> [2019-04-22 12:20:29] ERROR[9751]: res_pjsip.c:3874 create_out_of_dialog_request: Unable to create outbound OPTIONS request to endpoint 1000 at sip20.voztovoice.org
> [2019-04-22 12:20:29] ERROR[9751]: res_pjsip/pjsip_options.c:877 sip_options_qualify_contact: Unable to create request to qualify contact sip:1000 at 93.41.37.15:64331;rinstance=9ef93b2b70945db5 on AOR 1000
--
This message was sent by Atlassian JIRA
(v6.2#6252)
More information about the asterisk-bugs
mailing list