Benoit Panizzon
2006-Mar-23 15:01 UTC
[Asterisk-Users] Anonymous sip calls getting into wrong context?
Hi all Maybe somebody has an idea. I'm tracing a very strange phenomena... I've a connection from Asterisk to a SIP PBX. Most calls have a caller ID. Some International calls don't have any. Now it looks like those calls without caller ID never get to the context where incomming calls from this SIP PBX should get to.... Examples: Call with Caller ID: (slightly anonymized) ============================================<-- SIP read from 157.161.x.x:5060: INVITE sip:4144400xxxx@157.161.x.x:5060;user=phone SIP/2.0 Via: SIP/2.0/UDP 157.161.x.x:5060;branch=z9hG4bK70430e016215 From: sip:4144400xxxx@157.161.x.x;tag=7921cd61 To: <sip:4144400xxxx@157.161.x.x:5060> Call-ID: 00000049900000820268089802239622118752830@157.161.x.x CSeq: 2221 INVITE Contact: <sip:157.161.x.x:5060> Max-Forwards: 70 Content-Type: application/sdp Content-Length: 348 v=0 c=IN IP4 172.28.32.2 m=audio 54204 RTP/AVP 8 a=mptime:20 a=ptime:20 a=rtpmap:8 PCMA/8000/1 a=X-pc-secret:base64:-removed- a=X-pc-csuites-rtp:62/51 64/51 60/51 60/50 a=X-pc-csuites-rtcp:81/70 81/71 82/70 82/71 80/70 ============================================Asterisk chooses the right context: Using INVITE request as basis request - 00000049900000820268089802239622118752830@157.161.x.x Sending to 157.161.x.x : 5060 (NAT) Found peer 'PBX-in'' Found RTP audio format 8 Peer audio RTP is at port 172.28.32.2:54204 Peer video RTP is at port 172.28.32.2:65535 Found description format PCMA Capabilities: us - 0x1f060e (gsm|ulaw|alaw|speex|ilbc|jpeg|png|h261|h263| h263p), peer - audio=0x8 (alaw)/video=0x0 (nothing), combined - 0x8 (alaw) Non-codec capabilities: us - 0x1 (telephone-event), peer - 0x0 (nothing), combined - 0x0 (nothing) Looking for 4144400xxxx in fromPBX (domain 157.161.x.x) Now what I call an anonymous call: =============================================<-- SIP read from 157.161.x.x:5060: INVITE sip:4144400xxxx@157.161.x.x:5060;user=phone SIP/2.0 Via: SIP/2.0/UDP 157.161.x.x:5060;branch=z9hG4bK016217 From: sip:@157.161.x.x;tag=4971a27f # NOTE the missing 'username' part. To: <sip:4144400xxxx@157.161.x.x:5060> Call-ID: 00000049910000820270586775145522118752830@157.161.x.x CSeq: 2222 INVITE Contact: <sip:157.161.x.x:5060> Max-Forwards: 70 Content-Type: application/sdp Content-Length: 117 v=0 o=- 152257528 0 IN IP4 157.161.x.x s=- c=IN IP4 157.161.x.x t=0 0 m=audio 4030 RTP/AVP 8 a=ptime:20 ====================================================And asterisk selects my default context called 'anonymous'.... Using INVITE request as basis request - 00000049910000820270586775145522118752830@157.161.x.x Sending to 157.161.x.x : 5060 (NAT) Found RTP audio format 8 Peer audio RTP is at port 157.161.x.x:4030 Peer video RTP is at port 157.161.x.x:65535 Capabilities: us - 0x1f060e (gsm|ulaw|alaw|speex|ilbc|jpeg|png|h261|h263| h263p), peer - audio=0x8 (alaw)/video=0x0 (nothing), combined - 0x8 (alaw) Non-codec capabilities: us - 0x1 (telephone-event), peer - 0x0 (nothing), combined - 0x0 (nothing) Looking for 4144400xxxx in anonymous (domain 157.161.x.x) So what is it that goes wrong here? -Benoit-