[asterisk-bugs] [JIRA] (ASTERISK-26772) Crash in srv.c on startup with pjsip

nappsoft (JIRA) noreply at issues.asterisk.org
Tue Feb 7 08:32:10 CST 2017


    [ https://issues.asterisk.org/jira/browse/ASTERISK-26772?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=235089#comment-235089 ] 

nappsoft commented on ASTERISK-26772:
-------------------------------------

I've looked a bit deeper into the issue in the meantime. The crash happens when ast_search_dns returns with 0 what means that there were no matches.

maybe the following line of ast_srv_lookup:

if ((ast_search_dns(*context, service, C_IN, T_SRV, srv_callback)) < 0) {

should be changed to:

if ((ast_search_dns(*context, service, C_IN, T_SRV, srv_callback)) < 1) {

?


> Crash in srv.c on startup with pjsip
> ------------------------------------
>
>                 Key: ASTERISK-26772
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-26772
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Core/DNS
>    Affects Versions: 13.14.0
>         Environment: Linux gcc 4.9.3 musl 1.1.15
>            Reporter: nappsoft
>         Attachments: backtrace.txt, srv_lookup.patch
>
>
> First of all: version is 13.14.0-rc1, but this version does not seem to exist yet in the bugtracker...
> And now about the issue: As soon as I configure a host with a hostname instead of an ip in pjsip.conf (registration, aor and identify section) asterisk 13.14.0-rc1 crashes during startup. This didn't happen with 13.13.1 as res_pjsip_endpoint_identifier_ip.c did not use ast_srv_lookup.
> I'm able to work around the issue by either using IP addresses instead of hostnames or by applying the attached patch.
> Backtrace attached



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list