Summary: | ASTERISK-17716: Asterisk tries to send an INVITE even when the DNS lookup for the host fails | ||
Reporter: | Terry Wilson (twilson) | Labels: | |
Date Opened: | 2011-04-19 12:06:54 | Date Closed: | 2011-10-19 14:15:28 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Channels/chan_sip/General |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ( 0) chan_sip_ASTERISK-17716.diff | |
Description: | When doing a "channel originate SIP/foo@address.invalid", Asterisk still tries to transmit (and re-transmit) the INVITE even though the DNS lookup fails. ****** STEPS TO REPRODUCE ****** *CLI> core set debug on *CLI> channel originate SIP/foo@address.invalid application Playback tt-monkeys ****** ADDITIONAL INFORMATION ****** *CLI> channel originate SIP/blah@address.invalid application Playback tt-weasels == Using SIP RTP CoS mark 5 [Apr 19 10:00:34] ERROR[15584]: netsock2.c:245 ast_sockaddr_resolve: getaddrinfo("address.invalid", "(null)", ...): No address associated with hostname [Apr 19 10:00:34] WARNING[15584]: chan_sip.c:5075 create_addr: No such host: address.invalid [Apr 19 10:00:34] WARNING[15584]: acl.c:708 ast_ouraddrfor: Cannot connect Audio is at 5060 Adding codec 0x2 (gsm) to SDP Adding codec 0x4 (ulaw) to SDP Adding codec 0x8 (alaw) to SDP Adding codec 0x800000000000 (testlaw) to SDP Adding non-codec 0x1 (telephone-event) to SDP Reliably Transmitting (no NAT) to (null): INVITE sip:blah@address.invalid SIP/2.0 Via: SIP/2.0/UDP 127.0.1.1:5060;branch=z9hG4bK15c4da04 Max-Forwards: 70 From: "Anonymous" <sip:Anonymous@anonymous.invalid>;tag=as10a4e54c To: <sip:blah@address.invalid> Contact: <sip:Anonymous@127.0.1.1:5060> Call-ID: 54b82ff67b9372f1717335c8005c62fd@127.0.1.1:5060 CSeq: 102 INVITE User-Agent: Asterisk PBX SVN-branch-1.8-r311874 Date: Tue, 19 Apr 2011 17:00:34 GMT Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH Supported: replaces, timer Content-Type: application/sdp Content-Length: 319 v=0 o=root 1125951442 1125951442 IN IP4 127.0.1.1 s=Asterisk PBX SVN-branch-1.8-r311874 c=IN IP4 127.0.1.1 t=0 0 m=audio 14160 RTP/AVP 3 0 8 101 a=rtpmap:3 GSM/8000 a=rtpmap:0 PCMU/8000 a=rtpmap:8 PCMA/8000 a=rtpmap:101 telephone-event/8000 a=fmtp:101 0-16 a=silenceSupp:off - - - - a=ptime:20 a=sendrecv --- [Apr 19 10:00:34] WARNING[15584]: chan_sip.c:3132 __sip_xmit: sip_xmit of 0x16f3c30 (len 902) to (null) returned -1: Invalid argument | ||
Comments: | By: Shane Kamar (shanekamar) 2011-06-12 17:38:58.090-0500 Submitted a fix, now the invite-sending function will fail (return -1 and continue) if ast_ouraddrfor does not return the appropriate host. |