Bug#543823: TCP transport yields unreachable clients
martin f krafft
madduck at debian.org
Thu Aug 27 07:29:32 UTC 2009
Package: asterisk
Version: 1:1.6.2.0~dfsg~beta4-0.7501
Severity: normal
[this is about the unofficial xorcom packages]
I am trying to use TCP transport and told twinkle to use TCP for
a test. Everything works fine with UDP, so the testing environment
seems ideal. However, even though TCP traffic flows properly,
asterisk deems the client UNREACHABLE.
Client configuration is included below.
We start off with an unregistered client:
jugband*CLI> sip unregister piper
Peer piper not registered
And now let it register. tshark sees the traffic, the asterisk SIP
debug is further below:
77.788716 84.74.106.21 -> 77.109.139.86 SIP Request: REGISTER sip:madduck.net
77.789182 77.109.139.86 -> 84.74.106.21 SIP Status: 401 Unauthorized (0 bindings)
77.807464 84.74.106.21 -> 77.109.139.86 TCP 57047 > sip [ACK] Seq=1543 Ack=1530 Win=9088 Len=0 TSV=863726127 TSER=1511175267
77.814185 84.74.106.21 -> 77.109.139.86 SIP Request: REGISTER sip:madduck.net
77.814769 77.109.139.86 -> 84.74.106.21 SIP Request: OPTIONS sip:piper at 192.168.14.3;transport=tcp
77.833677 84.74.106.21 -> 77.109.139.86 SIP Status: 200 OK
77.833708 77.109.139.86 -> 84.74.106.21 SIP Status: 200 OK (1 bindings)
77.884156 84.74.106.21 -> 77.109.139.86 TCP 57047 > sip [ACK] Seq=2701 Ack=2643 Win=11392 Len=0 TSV=863726148 TSER=1511175278
This seems like a successful registration, but immediately
afterwards, asterisk reports:
[Aug 27 09:18:41] NOTICE[2816]: chan_sip.c:22075 sip_poke_noanswer: Peer 'piper' is now UNREACHABLE! Last qualify: 0
The subsequent OPTIONS exchange also appears successful:
91.823075 77.109.139.86 -> 84.74.106.21 SIP Request: OPTIONS sip:piper at 192.168.14.3;transport=tcp
91.840711 84.74.106.21 -> 77.109.139.86 TCP 57047 > sip [ACK] Seq=2701 Ack=3210 Win=12544 Len=0 TSV=863729636 TSER=1511178776
91.840970 84.74.106.21 -> 77.109.139.86 SIP Status: 200 OK
91.878838 77.109.139.86 -> 84.74.106.21 TCP sip > 57047 [ACK] Seq=3210 Ack=3239 Win=12896 Len=0 TSV=1511178790 TSER=863729636
and even the NAT refreshes sent from the client are fine:
107.861611 84.74.106.21 -> 77.109.139.86 SIP Continuation
107.861682 77.109.139.86 -> 84.74.106.21 TCP sip > 57047 [ACK] Seq=3210 Ack=3243 Win=12896 Len=0 TSV=1511182785 TSER=863733641
and yet, the client remains UNREACHABLE. If I switch back to UDP, it
works again.
Here's the peer configuration:
* Name : piper
Secret : <Not set>
MD5Secret : <Set>
Remote Secret: <Not set>
Context : phones
Subscr.Cont. : <Not set>
Language : de
AMA flags : Unknown
Transfer mode: open
CallingPres : Presentation Allowed, Not Screened
Callgroup :
Pickupgroup :
Mailbox : 0 at default
VM Extension : asterisk
LastMsgsSent : 32767/65535
Call limit : 0
Dynamic : Yes
Callerid : "" <>
MaxCallBR : 384 kbps
Expire : -1
Insecure : no
Nat : Always
ACL : No
T38 pt UDPTL : No
CanReinvite : Yes
PromiscRedir : No
User=Phone : No
Video Support: No
Text Support : No
Ign SDP ver : No
Trust RPID : No
Send RPID : No
Subscriptions: Yes
Overlap dial : No
DTMFmode : rfc2833
Timer T1 : 500
Timer B : 32000
ToHost :
Addr->IP : (Unspecified) Port 0
Defaddr->IP : 0.0.0.0 Port 5060
Prim.Transp. : UDP
Allowed.Trsp : TCP,UDP
Def. Username: piper
SIP Options : (none)
Codecs : 0xc (ulaw|alaw)
Codec Order : (ulaw:20,alaw:20)
Auto-Framing : No
100 on REG : No
Status : UNKNOWN
Useragent :
Reg. Contact :
Qualify Freq : 60000 ms
Sess-Timers : Accept
Sess-Refresh : uas
Sess-Expires : 1800 secs
Min-Sess : 90 secs
SIP debug output:
Registration:
<--- SIP read from TCP:84.74.106.21:38592 --->
REGISTER sip:madduck.net SIP/2.0
Via: SIP/2.0/TCP 192.168.14.3;rport;branch=z9hG4bKvcnlbcvw
Max-Forwards: 70
To: "martin" <sip:piper at madduck.net>
From: "martin" <sip:piper at madduck.net>;tag=qyrjm
Call-ID: jsezqmwghnjmpap at piper.oerlikon.madduck.net
CSeq: 1849 REGISTER
Contact: <sip:piper at 192.168.14.3;transport=tcp>;expires=900
Allow: INVITE,ACK,BYE,CANCEL,OPTIONS,PRACK,REFER,NOTIFY,SUBSCRIBE,INFO,MESSAGE
User-Agent: Twinkle/1.4.2
Content-Length: 0
jugband*CLI>
<------------->
--- (11 headers 0 lines) ---
<--- Transmitting (NAT) to 84.74.106.21:38592 --->
SIP/2.0 401 Unauthorized
Via: SIP/2.0/TCP 192.168.14.3;branch=z9hG4bKvcnlbcvw;received=84.74.106.21;rport=38592
From: "martin" <sip:piper at madduck.net>;tag=qyrjm
To: "martin" <sip:piper at madduck.net>;tag=as4c4320c4
Call-ID: jsezqmwghnjmpap at piper.oerlikon.madduck.net
CSeq: 1849 REGISTER
Server: madduck.net asterisk
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="madduck.net", nonce="49c65175"
Content-Length: 0
<------------>
Scheduling destruction of SIP dialog 'jsezqmwghnjmpap at piper.oerlikon.madduck.net' in 32000 ms (Method: REGISTER)
jugband*CLI>
<--- SIP read from TCP:84.74.106.21:38592 --->
REGISTER sip:madduck.net SIP/2.0
Via: SIP/2.0/TCP 192.168.14.3;rport;branch=z9hG4bKonsbqrqd
Max-Forwards: 70
To: "martin" <sip:piper at madduck.net>
From: "martin" <sip:piper at madduck.net>;tag=qyrjm
Call-ID: jsezqmwghnjmpap at piper.oerlikon.madduck.net
CSeq: 1850 REGISTER
Contact: <sip:piper at 192.168.14.3;transport=tcp>;expires=900
Authorization: Digest username="piper",realm="madduck.net",nonce="49c65175",uri="sip:madduck.net",response="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",algorithm=MD5
Allow: INVITE,ACK,BYE,CANCEL,OPTIONS,PRACK,REFER,NOTIFY,SUBSCRIBE,INFO,MESSAGE
User-Agent: Twinkle/1.4.2
Content-Length: 0
<------------->
--- (12 headers 0 lines) ---
Sending to 84.74.106.21 : 38592 (NAT)
Reliably Transmitting (NAT) to 84.74.106.21:38592:
OPTIONS sip:piper at 192.168.14.3;transport=tcp SIP/2.0
Via: SIP/2.0/TCP 77.109.139.86:5060;branch=z9hG4bK48663b98;rport
Max-Forwards: 70
From: "asterisk" <sip:asterisk at 77.109.139.86>;tag=as6fce7955
To: <sip:piper at 192.168.14.3;transport=tcp>
Contact: <sip:asterisk at 77.109.139.86;transport=TCP>
Call-ID: 6bdaf57f24e0a183511383bd34608dda at 77.109.139.86
CSeq: 102 OPTIONS
User-Agent: madduck.net asterisk
Date: Thu, 27 Aug 2009 07:24:29 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Content-Length: 0
---
<--- Transmitting (NAT) to 84.74.106.21:38592 --->
SIP/2.0 200 OK
Via: SIP/2.0/TCP 192.168.14.3;branch=z9hG4bKonsbqrqd;received=84.74.106.21;rport=38592
From: "martin" <sip:piper at madduck.net>;tag=qyrjm
To: "martin" <sip:piper at madduck.net>;tag=as4c4320c4
Call-ID: jsezqmwghnjmpap at piper.oerlikon.madduck.net
CSeq: 1850 REGISTER
Server: madduck.net asterisk
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Expires: 900
Contact: <sip:piper at 192.168.14.3;transport=tcp>;expires=900
Date: Thu, 27 Aug 2009 07:24:29 GMT
Content-Length: 0
<------------>
Scheduling destruction of SIP dialog 'jsezqmwghnjmpap at piper.oerlikon.madduck.net' in 32000 ms (Method: REGISTER)
jugband*CLI>
<--- SIP read from TCP:84.74.106.21:38592 --->
SIP/2.0 200 OK
Via: SIP/2.0/TCP 77.109.139.86:5060;received=77.109.139.86;rport=5060;branch=z9hG4bK48663b98
To: <sip:piper at 192.168.14.3;transport=tcp>;tag=housc
From: "asterisk" <sip:asterisk at 77.109.139.86>;tag=as6fce7955
Call-ID: 6bdaf57f24e0a183511383bd34608dda at 77.109.139.86
CSeq: 102 OPTIONS
Accept: application/sdp
Accept-Encoding: identity
Accept-Language: en
Allow: INVITE,ACK,BYE,CANCEL,OPTIONS,PRACK,REFER,NOTIFY,SUBSCRIBE,INFO,MESSAGE
Server: Twinkle/1.4.2
Supported: replaces,norefersub,100rel
Content-Length: 0
<------------->
--- (13 headers 0 lines) ---
OPTIONS:
Reliably Transmitting (NAT) to 84.74.106.21:38592:
OPTIONS sip:piper at 192.168.14.3;transport=tcp SIP/2.0
Via: SIP/2.0/TCP 77.109.139.86:5060;branch=z9hG4bK206f4765;rport
Max-Forwards: 70
From: "asterisk" <sip:asterisk at 77.109.139.86>;tag=as6cc4a23f
To: <sip:piper at 192.168.14.3;transport=tcp>
Contact: <sip:asterisk at 77.109.139.86;transport=TCP>
Call-ID: 622a257e30b97f377ed4c2ed1d1ec738 at 77.109.139.86
CSeq: 102 OPTIONS
User-Agent: madduck.net asterisk
Date: Thu, 27 Aug 2009 07:24:43 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Content-Length: 0
---
jugband*CLI>
<--- SIP read from TCP:84.74.106.21:38592 --->
SIP/2.0 200 OK
Via: SIP/2.0/TCP 77.109.139.86:5060;received=77.109.139.86;rport=5060;branch=z9hG4bK206f4765
To: <sip:piper at 192.168.14.3;transport=tcp>;tag=rvrey
From: "asterisk" <sip:asterisk at 77.109.139.86>;tag=as6cc4a23f
Call-ID: 622a257e30b97f377ed4c2ed1d1ec738 at 77.109.139.86
CSeq: 102 OPTIONS
Accept: application/sdp
Accept-Encoding: identity
Accept-Language: en
Allow: INVITE,ACK,BYE,CANCEL,OPTIONS,PRACK,REFER,NOTIFY,SUBSCRIBE,INFO,MESSAGE
Server: Twinkle/1.4.2
Supported: replaces,norefersub,100rel
Content-Length: 0
<------------->
--- (13 headers 0 lines) ---
NAT keep-alive:
IP read from TCP:84.74.106.21:38592 --->
<------------->
-- System Information:
Debian Release: squeeze/sid
APT prefers unstable
APT policy: (500, 'unstable'), (500, 'testing'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.31-rc3-amd64 (SMP w/1 CPU core)
Locale: LANG=en_GB, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
--
.''`. martin f. krafft <madduck at d.o> Related projects:
: :' : proud Debian developer http://debiansystem.info
`. `'` http://people.debian.org/~madduck http://vcs-pkg.org
`- Debian - when you have better things to do than fixing systems
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Digital signature (see http://martin-krafft.net/gpg/)
URL: <http://lists.alioth.debian.org/pipermail/pkg-voip-maintainers/attachments/20090827/feb57a2c/attachment.pgp>
More information about the Pkg-voip-maintainers
mailing list