Łukasz Łukaszewicz

Łukasz Łukaszewicz Dyrektor
Zarządzający

Temat: Tribox - połączenia przychodzące

Witam,
Próbuję skonfigurować połączenia przychodzące dla triboxa znajdującego się za natem.
Podczas gdy połączenia wychodzące działają bez problemów to połączenia przychodzące są nie realizowalne.
Oto logi z triboxa (asteriska)

<--- SIP read from UDP://79.133.193.90:5060 --->
INVITE sip:s@10.0.0.101 SIP/2.0
Via: SIP/2.0/UDP 79.133.193.90:5060;branch=z9hG4bK5ca2664e;rport
From: "669666609" <sip:nr tel@79.133.193.90>;tag=as7e403ad7
To: <sip:s@10.0.0.101>
Contact: <sip:nr tel@79.133.193.90>
Call-ID: 70f27e151bd073be08e98cb8522f78d5@79.133.193.90
CSeq: 102 INVITE
User-Agent: NetCentrica SIP Server
Max-Forwards: 70
Date: Thu, 30 Sep 2010 08:03:51 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces
X-Called-Number: 224274403
Content-Type: application/sdp
Content-Length: 356

v=0
o=root 19685 19685 IN IP4 79.133.193.90
s=session
c=IN IP4 79.133.193.90
t=0 0
m=audio 11676 RTP/AVP 0 8 3 112 111 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:112 AAL2-G726-32/8000
a=rtpmap:111 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=silenceSupp:off - - - -
a=ptime:20
a=sendrecv

<------------->
--- (15 headers 16 lines) ---
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
== Using SIP VRTP TOS bits 136
== Using SIP VRTP CoS mark 6
Sending to 79.133.193.90 : 5060 (no NAT)
Using INVITE request as basis request - 70f27e151bd073be08e98cb8522f78d5@79.133.193.90
No user '669nr tel' in SIP users list
Found peer 'extravoip_.....' for '669nr tel' from 79.133.193.90:5060
Found RTP audio format 0
Found RTP audio format 8
Found RTP audio format 3
Found RTP audio format 112
Found RTP audio format 111
Found RTP audio format 101
Found audio description format PCMU for ID 0
Found audio description format PCMA for ID 8
Found audio description format GSM for ID 3
Found audio description format AAL2-G726-32 for ID 112
Found audio description format G726-32 for ID 111
Found audio description format telephone-event for ID 101
Capabilities: us - 0x4 (ulaw), peer - audio=0x81e (gsm|ulaw|alaw|g726|g726aal2)/video=0x0 (nothing)/text=0x0 (nothing), combined - 0x4 (ulaw)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event), peer - 0x1 (telephone-event), combined - 0x1 (telephone-event)
Peer audio RTP is at port 79.133.193.90:11676
Looking for s in from-sip-external (domain 10.0.0.101)
list_route: hop: <sip:669nr tel@79.133.193.90>

<--- Transmitting (NAT) to 79.133.193.90:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 79.133.193.90:5060;branch=z9hG4bK5ca2664e;received=79.133.193.90;rport=5060
From: "669666609" <sip:669nr tel@79.133.193.90>;tag=as7e403ad7
To: <sip:s@10.0.0.101>
Call-ID: 70f27e151bd073be08e98cb8522f78d5@79.133.193.90
CSeq: 102 INVITE
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Contact: <sip:s@10.0.0.101>
Content-Length: 0


<------------>
-- Executing [s@from-sip-external:1] GotoIf("SIP/extravoip_307051-0000015f", "0?from-trunk,,1") in new stack
-- Executing [s@from-sip-external:2] Set("SIP/extravoip_307051-0000015f", "TIMEOUT(absolute)=15") in new stack
Channel will hangup at 2010-09-30 10:02:04.000 CEST.
-- Executing [s@from-sip-external:3] Answer("SIP/extravoip_307051-0000015f", "") in new stack
Audio is at 10.0.0.101 port 12704
Adding codec 0x4 (ulaw) to SDP
Adding non-codec 0x1 (telephone-event) to SDP
tqvoip*CLI>
<--- Reliably Transmitting (NAT) to 79.133.193.90:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 79.133.193.90:5060;branch=z9hG4bK5ca2664e;received=79.133.193.90;rport=5060
From: "669nr tel" <sip:669nr tel@79.133.193.90>;tag=as7e403ad7
To: <sip:s@10.0.0.101>;tag=as081da73e
Call-ID: 70f27e151bd073be08e98cb8522f78d5@79.133.193.90
CSeq: 102 INVITE
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Contact: <sip:s@10.0.0.101>
Content-Type: application/sdp
Content-Length: 270

v=0
o=root 429702546 429702546 IN IP4 10.0.0.101
s=Asterisk PBX 1.6.0.26-FONCORE-r78
c=IN IP4 10.0.0.101
t=0 0
m=audio 12704 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=silenceSupp:off - - - -
a=ptime:20
a=sendrecv

<------------>
tqvoip*CLI>
<--- SIP read from UDP://79.133.193.90:5060 --->
ACK sip:s@10.0.0.101 SIP/2.0
Via: SIP/2.0/UDP 79.133.193.90:5060;branch=z9hG4bK7a638d75;rport
From: "669nr tel" <sip:669nr tel@79.133.193.90>;tag=as7e403ad7
To: <sip:s@10.0.0.101>;tag=as081da73e
Contact: <sip:669nr tel@79.133.193.90>
Call-ID: 70f27e151bd073be08e98cb8522f78d5@79.133.193.90
CSeq: 102 ACK
User-Agent: NetCentrica SIP Server
Max-Forwards: 70
Content-Length: 0


<------------->
--- (10 headers 0 lines) ---
-- Executing [s@from-sip-external:4] Wait("SIP/extravoip_......-0000015f", "2") in new stack
-- Executing [s@from-sip-external:5] Playback("SIP/extravoip_.....-0000015f", "ss-noservice") in new stack
-- <SIP/extravoip_....-0000015f> Playing 'ss-noservice.gsm' (language 'en')
tqvoip*CLI>
<--- SIP read from UDP://10.0.0.206:5060 --->
REGISTER sip:10.0.0.101:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.206:5060;branch=z9hG4bK8951154530759945;rport
From: 203 <sip:203@10.0.0.101:5060>;tag=2583126590
To: 203 <sip:203@10.0.0.101:5060>
Call-ID: 20601923987-16861925428071@10.0.0.206
CSeq: 5357 REGISTER
Contact: <sip:203@10.0.0.206:5060>
Max-Forwards: 70
Expires: 60
Supported: path
User-Agent: Voip Phone 1.0
Content-Length: 0


<------------->
--- (12 headers 0 lines) ---
Sending to 10.0.0.206 : 5060 (no NAT)
tqvoip*CLI>
<--- Transmitting (NAT) to 10.0.0.206:5060 --->
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 10.0.0.206:5060;branch=z9hG4bK8951154530759945;received=10.0.0.206;rport=5060
From: 203 <sip:203@10.0.0.101:5060>;tag=2583126590
To: 203 <sip:203@10.0.0.101:5060>;tag=as5a73ece7
Call-ID: 20601923987-16861925428071@10.0.0.206
CSeq: 5357 REGISTER
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="38b0032f"
Content-Length: 0


<------------>
Scheduling destruction of SIP dialog '20601923987-16861925428071@10.0.0.206' in 32000 ms (Method: REGISTER)
tqvoip*CLI>
<--- SIP read from UDP://10.0.0.206:5060 --->
REGISTER sip:10.0.0.101:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.206:5060;branch=z9hG4bK1533612171236521605;rport
From: 203 <sip:203@10.0.0.101:5060>;tag=2583126590
To: 203 <sip:203@10.0.0.101:5060>
Call-ID: 20601923987-16861925428071@10.0.0.206
CSeq: 5358 REGISTER
Contact: <sip:203@10.0.0.206:5060>
Authorization: Digest username="203", realm="asterisk", nonce="38b0032f", uri="sip:10.0.0.101:5060", response="bbbcdf7980fc08a35b1ae61932b0c8c4", algorithm=MD5
Max-Forwards: 70
Expires: 60
Supported: path
User-Agent: Voip Phone 1.0
Content-Length: 0


<------------->
--- (13 headers 0 lines) ---
Sending to 10.0.0.206 : 5060 (NAT)
Reliably Transmitting (NAT) to 10.0.0.206:5060:
OPTIONS sip:203@10.0.0.206:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.101:5060;branch=z9hG4bK1a24ebf5;rport
Max-Forwards: 70
From: "Unknown" <sip:Unknown@10.0.0.101>;tag=as065b4493
To: <sip:203@10.0.0.206:5060>
Contact: <sip:Unknown@10.0.0.101>
Call-ID: 335d8e3e283a09125a1872f6433d7f22@10.0.0.101
CSeq: 102 OPTIONS
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Date: Thu, 30 Sep 2010 08:01:53 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Content-Length: 0


---
tqvoip*CLI>
<--- Transmitting (NAT) to 10.0.0.206:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.0.0.206:5060;branch=z9hG4bK1533612171236521605;received=10.0.0.206;rport=5060
From: 203 <sip:203@10.0.0.101:5060>;tag=2583126590
To: 203 <sip:203@10.0.0.101:5060>;tag=as5a73ece7
Call-ID: 20601923987-16861925428071@10.0.0.206
CSeq: 5358 REGISTER
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Expires: 60
Contact: <sip:203@10.0.0.206:5060>;expires=60
Date: Thu, 30 Sep 2010 08:01:53 GMT
Content-Length: 0


<------------>
Scheduling destruction of SIP dialog '20601923987-16861925428071@10.0.0.206' in 32000 ms (Method: REGISTER)
tqvoip*CLI>
<--- SIP read from UDP://10.0.0.206:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.0.0.101:5060;branch=z9hG4bK1a24ebf5;rport
From: "Unknown" <sip:Unknown@10.0.0.101>;tag=as065b4493
To: <sip:203@10.0.0.206:5060>
Call-ID: 335d8e3e283a09125a1872f6433d7f22@10.0.0.101
CSeq: 102 OPTIONS
Contact: <sip:203@10.0.0.206:5060>
Supported: 100rel, replaces, timer
Allow: INVITE, ACK, OPTIONS, BYE, CANCEL, REFER, NOTIFY, INFO, PRACK, UPDATE, MESSAGE
Accept: application/sdp, message/sipfrag, application/dtmf-relay
Content-Length: 0


<------------->
--- (11 headers 0 lines) ---
Really destroying SIP dialog '335d8e3e283a09125a1872f6433d7f22@10.0.0.101' Method: OPTIONS
tqvoip*CLI>
<--- SIP read from UDP://79.133.193.90:5060 --->
BYE sip:s@10.0.0.101 SIP/2.0
Via: SIP/2.0/UDP 79.133.193.90:5060;branch=z9hG4bK4f994a32;rport
From: "669nr tel" <sip:669nr tel@79.133.193.90>;tag=as7e403ad7
To: <sip:s@10.0.0.101>;tag=as081da73e
Call-ID: 70f27e151bd073be08e98cb8522f78d5@79.133.193.90
CSeq: 103 BYE
User-Agent: NetCentrica SIP Server
Max-Forwards: 70
X-Asterisk-HangupCause: Normal Clearing
X-Asterisk-HangupCauseCode: 16
Content-Length: 0


<------------->
--- (11 headers 0 lines) ---
Sending to 79.133.193.90 : 5060 (NAT)

<--- Transmitting (NAT) to 79.133.193.90:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 79.133.193.90:5060;branch=z9hG4bK4f994a32;received=79.133.193.90;rport=5060
From: "669nr tel" <sip:669nr tel@79.133.193.90>;tag=as7e403ad7
To: <sip:s@10.0.0.101>;tag=as081da73e
Call-ID: 70f27e151bd073be08e98cb8522f78d5@79.133.193.90
CSeq: 103 BYE
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Content-Length: 0


<------------>
== Spawn extension (from-sip-external, s, 5) exited non-zero on 'SIP/extravoip_.....-0000015f'
-- Executing [h@from-sip-external:1] NoOp("SIP/extravoip_....-0000015f", "Hangup") in new stack
-- Executing [h@from-sip-external:2] Set("SIP/extravoip_.....-0000015f", "DID=s") in new stack
-- Executing [h@from-sip-external:3] Goto("SIP/extravoip_.....-0000015f", "s,1") in new stack
-- Goto (from-sip-external,s,1)
-- Executing [s@from-sip-external:1] GotoIf("SIP/extravoip_....-0000015f", "0?from-trunk,s,1") in new stack
-- Executing [s@from-sip-external:2] Set("SIP/extravoip_......-0000015f", "TIMEOUT(absolute)=15") in new stack
Channel will hangup at 2010-09-30 10:02:10.000 CEST.
-- Executing [s@from-sip-external:3] Answer("SIP/extravoip_.....-0000015f", "") in new stack
== Spawn extension (from-sip-external, s, 3) exited non-zero on 'SIP/extravoip_.....-0000015f'
Really destroying SIP dialog '70f27e151bd073be08e98cb8522f78d5@79.133.193.90' Method: BYE
tqvoip*CLI>
<--- SIP read from UDP://10.0.0.204:5060 --->
REGISTER sip:10.0.0.101:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.204:5060;branch=z9hG4bK4360306261530716913;rport
From: 200 <sip:200@10.0.0.101:5060>;tag=2739626442
To: 200 <sip:200@10.0.0.101:5060>
Call-ID: 1564121332548-27990274545326@10.0.0.204
CSeq: 5357 REGISTER
Contact: <sip:200@10.0.0.204:5060>
Max-Forwards: 70
Expires: 60
Supported: path
User-Agent: Voip Phone 1.0
Content-Length: 0


<------------->
--- (12 headers 0 lines) ---
Sending to 10.0.0.204 : 5060 (no NAT)

<--- Transmitting (NAT) to 10.0.0.204:5060 --->
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 10.0.0.204:5060;branch=z9hG4bK4360306261530716913;received=10.0.0.204;rport=5060
From: 200 <sip:200@10.0.0.101:5060>;tag=2739626442
To: 200 <sip:200@10.0.0.101:5060>;tag=as69204bfe
Call-ID: 1564121332548-27990274545326@10.0.0.204
CSeq: 5357 REGISTER
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="7a02ee99"
Content-Length: 0


<------------>
Scheduling destruction of SIP dialog '1564121332548-27990274545326@10.0.0.204' in 32000 ms (Method: REGISTER)
tqvoip*CLI>
<--- SIP read from UDP://10.0.0.204:5060 --->
REGISTER sip:10.0.0.101:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.204:5060;branch=z9hG4bK293452585654056327;rport
From: 200 <sip:200@10.0.0.101:5060>;tag=2739626442
To: 200 <sip:200@10.0.0.101:5060>
Call-ID: 1564121332548-27990274545326@10.0.0.204
CSeq: 5358 REGISTER
Contact: <sip:200@10.0.0.204:5060>
Authorization: Digest username="200", realm="asterisk", nonce="7a02ee99", uri="sip:10.0.0.101:5060", response="58451c93c2fbd3f90f097b892599590d", algorithm=MD5
Max-Forwards: 70
Expires: 60
Supported: path
User-Agent: Voip Phone 1.0
Content-Length: 0


<------------->
--- (13 headers 0 lines) ---
Sending to 10.0.0.204 : 5060 (NAT)
Reliably Transmitting (NAT) to 10.0.0.204:5060:
OPTIONS sip:200@10.0.0.204:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.101:5060;branch=z9hG4bK46bdf30d;rport
Max-Forwards: 70
From: "Unknown" <sip:Unknown@10.0.0.101>;tag=as718211af
To: <sip:200@10.0.0.204:5060>
Contact: <sip:Unknown@10.0.0.101>
Call-ID: 630266ac74de605008500b8956dffed3@10.0.0.101
CSeq: 102 OPTIONS
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Date: Thu, 30 Sep 2010 08:02:05 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Content-Length: 0


---

<--- Transmitting (NAT) to 10.0.0.204:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.0.0.204:5060;branch=z9hG4bK293452585654056327;received=10.0.0.204;rport=5060
From: 200 <sip:200@10.0.0.101:5060>;tag=2739626442
To: 200 <sip:200@10.0.0.101:5060>;tag=as69204bfe
Call-ID: 1564121332548-27990274545326@10.0.0.204
CSeq: 5358 REGISTER
User-Agent: Asterisk PBX 1.6.0.26-FONCORE-r78
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Expires: 60
Contact: <sip:200@10.0.0.204:5060>;expires=60
Date: Thu, 30 Sep 2010 08:02:05 GMT
Content-Length: 0


<------------>
Scheduling destruction of SIP dialog '1564121332548-27990274545326@10.0.0.204' in 32000 ms (Method: REGISTER)
tqvoip*CLI>
<--- SIP read from UDP://10.0.0.204:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.0.0.101:5060;branch=z9hG4bK46bdf30d;rport
From: "Unknown" <sip:Unknown@10.0.0.101>;tag=as718211af
To: <sip:200@10.0.0.204:5060>
Call-ID: 630266ac74de605008500b8956dffed3@10.0.0.101
CSeq: 102 OPTIONS
Contact: <sip:200@10.0.0.204:5060>
Supported: 100rel, replaces, timer
Allow: INVITE, ACK, OPTIONS, BYE, CANCEL, REFER, NOTIFY, INFO, PRACK, UPDATE, MESSAGE
Accept: application/sdp, message/sipfrag, application/dtmf-relay
Content-Length: 0

oraz konfiguracja sip.conf

nazwa
disallow=all
context=from-pstn
host=79.133.193.90
username=extravoip_.....
secret=odpowiednie
nat=yes
qualify=yes
allow=ulaw
allow=alaw
allow=gsm
externip=adres prawidłowy
localnet=10.0.0.0/255.255.255.0

[extravoip_.....]
disallow=all
host=79.133.193.90
username=extravoip_....
secret=prawidłowe
insecure=invite,port
type=peer
nat=yes
qualify=yes
allow=ulaw

Będę wdzięczny za pomoc.