Tls register no tls call

hello,

i have two users:
5000 of ip:192.168.105.101 on gxp1625
5001 of ip:192.168.105.102 on gxp1625

what i uploaded for certificates is ca.crt at CA trusted certificates and client.pem at custom certificates!
Successfully registered on asterisk sip server: 192.168.105.100 of port:5061 transport=TLS, no srtp as for now

but the call was being refused due to cause 34

here are the logs at the asterisk sip server:

<--- Received SIP request (1183 bytes) from [TLS:192.168.105.102:36009](tls:192.168.105.102:36009) --->
INVITE sips:5000@192.168.105.100:5061 SIP/2.0
[Via:](via:) SIP/2.0/TLS 192.168.105.102:5061;branch=z9hG4bK1970851136;rport;alias
[From:](from:) "5001" <sips:5001@192.168.105.100:5061>;tag=345882001
[To:](to:) <sips:5000@192.168.105.100:5061>
[Call-ID:](call-id:) 236840991-5061-7@BJC.BGI.BAF.BAC
[CSeq:](cseq:) 40 INVITE
[Contact:](contact:) "5001" <sips:5001@192.168.105.102:5061;transport=tls>
[Max-Forwards:](max-forwards:) 70
[User-Agent:](user-agent:) Grandstream GXP1625 1.0.7.18
[Privacy:](privacy:) none
[P-Preferred-Identity:](p-preferred-identity:) "5001" <sips:5001@192.168.105.100:5061>
[P-Emergency-Info:](p-emergency-info:) IEEE-EUI-48;eui-48-addr=00-0B-82-A0-4D-86
[Supported:](supported:) replaces, path, timer
[Allow:](allow:) INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE, MESSAGE
[Content-Type:](content-type:) application/sdp
[Accept:](accept:) application/sdp, application/dtmf-relay
[Content-Length:](content-length:) 408

v=0
o=5001 8000 8000 IN IP4 192.168.105.102
s=SIP Call
c=IN IP4 192.168.105.102
t=0 0
m=audio 5004 RTP/AVP 0 8 4 18 9 97 2 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:9 G722/8000
a=rtpmap:97 iLBC/8000
a=fmtp:97 mode=30
a=rtpmap:2 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15

<--- Transmitting SIP response (505 bytes) to [TLS:192.168.105.102:36009](tls:192.168.105.102:36009) --->
SIP/2.0 401 Unauthorized
[Via:](via:) SIP/2.0/TLS 192.168.105.102:5061;rport=36009;received=192.168.105.102;branch=z9hG4bK1970851136;alias
[Call-ID:](call-id:) 236840991-5061-7@BJC.BGI.BAF.BAC
[From:](from:) "5001" <sips:5001@192.168.105.100>;tag=345882001
[To:](to:) <sips:5000@192.168.105.100>;tag=z9hG4bK1970851136
[CSeq:](cseq:) 40 INVITE
[WWW-Authenticate:](www-authenticate:) Digest realm="asterisk",nonce="1649415447/a54797b020f8f2e14d2ff42b34c34f5c",opaque="0828d92b39d5f21b",algorithm=md5,qop="auth"
[Server:](server:) Asterisk PBX 18.0.0-rc2
[Content-Length:](content-length:) 0

<--- Received SIP request (309 bytes) from [TLS:192.168.105.102:36009](tls:192.168.105.102:36009) --->
ACK sips:5000@192.168.105.100:5061 SIP/2.0
[Via:](via:) SIP/2.0/TLS 192.168.105.102:5061;branch=z9hG4bK1970851136;rport;alias
[From:](from:) "5001" <sips:5001@192.168.105.100>;tag=345882001
[To:](to:) <sips:5000@192.168.105.100>;tag=z9hG4bK1970851136
[Call-ID:](call-id:) 236840991-5061-7@BJC.BGI.BAF.BAC
[CSeq:](cseq:) 40 ACK
[Content-Length:](content-length:) 0

<--- Received SIP request (1460 bytes) from [TLS:192.168.105.102:36009](tls:192.168.105.102:36009) --->
INVITE sips:5000@192.168.105.100:5061 SIP/2.0
[Via:](via:) SIP/2.0/TLS 192.168.105.102:5061;branch=z9hG4bK1176825952;rport;alias
[From:](from:) "5001" <sips:5001@192.168.105.100:5061>;tag=345882001
[To:](to:) <sips:5000@192.168.105.100:5061>
[Call-ID:](call-id:) 236840991-5061-7@BJC.BGI.BAF.BAC
[CSeq:](cseq:) 41 INVITE
[Contact:](contact:) "5001" <sips:5001@192.168.105.102:5061;transport=tls>
[Authorization:](authorization:) Digest username="5001", realm="asterisk", nonce="1649415447/a54797b020f8f2e14d2ff42b34c34f5c", uri="sips:5000@192.168.105.100:5061", response="35bf30ad3875a5dbe01bcd3112c294fc", algorithm=md5, cnonce="07571131", opaque="0828d92b39d5f21b", qop=auth, nc=00000001
[Max-Forwards:](max-forwards:) 70
[User-Agent:](user-agent:) Grandstream GXP1625 1.0.7.18
[Privacy:](privacy:) none
[P-Preferred-Identity:](p-preferred-identity:) "5001" <sips:5001@192.168.105.100:5061>
[P-Emergency-Info:](p-emergency-info:) IEEE-EUI-48;eui-48-addr=00-0B-82-A0-4D-86
[Supported:](supported:) replaces, path, timer
[Allow:](allow:) INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE, MESSAGE
[Content-Type:](content-type:) application/sdp
[Accept:](accept:) application/sdp, application/dtmf-relay
[Content-Length:](content-length:) 408

v=0
o=5001 8000 8000 IN IP4 192.168.105.102
s=SIP Call
c=IN IP4 192.168.105.102
t=0 0
m=audio 5004 RTP/AVP 0 8 4 18 9 97 2 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:9 G722/8000
a=rtpmap:97 iLBC/8000
a=fmtp:97 mode=30
a=rtpmap:2 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15

== Setting global variable 'SIPDOMAIN' to '192.168.105.100'
<--- Transmitting SIP response (331 bytes) to [TLS:192.168.105.102:36009](tls:192.168.105.102:36009) --->
SIP/2.0 100 Trying
[Via:](via:) SIP/2.0/TLS 192.168.105.102:5061;rport=36009;received=192.168.105.102;branch=z9hG4bK1176825952;alias
[Call-ID:](call-id:) 236840991-5061-7@BJC.BGI.BAF.BAC
[From:](from:) "5001" <sips:5001@192.168.105.100>;tag=345882001
[To:](to:) <sips:5000@192.168.105.100>
[CSeq:](cseq:) 41 INVITE
[Server:](server:) Asterisk PBX 18.0.0-rc2
[Content-Length:](content-length:) 0

-- Executing [5000@phones:1] Dial("PJSIP/5001-00000029", "PJSIP/5000") in new stack
-- Called PJSIP/5000
<--- Transmitting SIP request (965 bytes) to [TLS:192.168.105.101:5061](tls:192.168.105.101:5061) --->
INVITE sips:5000@192.168.105.101:5061;transport=tls SIP/2.0
[Via:](via:) SIP/2.0/TLS 192.168.105.100:5061;rport;branch=z9hG4bKPjbS4C8G4sKa66Wv-C3lHj5EfwhctwNQph;alias
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=4bvMfmDQiZbMMYaAdcY8NZzYQjlHLqlw
[To:](to:) <sips:5000@192.168.105.101>
[Contact:](contact:) <sips:asterisk@192.168.105.100:5061;transport=TLS>
[Call-ID:](call-id:) GEnvHYLHep9c6oRZyHBuWH9.zrkwmB43
[CSeq:](cseq:) 3143 INVITE
[Allow:](allow:) OPTIONS, REGISTER, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, MESSAGE, REFER
[Supported:](supported:) 100rel, timer, replaces, norefersub
[Session-Expires:](session-expires:) 1800
[Min-SE:](min-se:) 90
[Max-Forwards:](max-forwards:) 70
[User-Agent:](user-agent:) Asterisk PBX 18.0.0-rc2
[Content-Type:](content-type:) application/sdp
[Content-Length:](content-length:) 265

v=0
o=- 549048275 549048275 IN IP4 192.168.105.100
s=Asterisk
c=IN IP4 192.168.105.100
t=0 0
m=audio 13846 RTP/AVP 8 0 101
a=rtpmap:8 PCMA/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=maxptime:150
a=sendrecv

== Everyone is busy/congested at this time (1:0/1/0)
-- Executing [5000@phones:2] Hangup("PJSIP/5001-00000029", "") in new stack
== Spawn extension (phones, 5000, 2) exited non-zero on 'PJSIP/5001-00000029'
<--- Transmitting SIP response (405 bytes) to [TLS:192.168.105.102:36009](tls:192.168.105.102:36009) --->
SIP/2.0 503 Service Unavailable
[Via:](via:) SIP/2.0/TLS 192.168.105.102:5061;rport=36009;received=192.168.105.102;branch=z9hG4bK1176825952;alias
[Call-ID:](call-id:) 236840991-5061-7@BJC.BGI.BAF.BAC
[From:](from:) "5001" <sips:5001@192.168.105.100>;tag=345882001
[To:](to:) <sips:5000@192.168.105.100>;tag=Wo5QLnOdph1BjbyvkkOP0Cob9hPPIO38
[CSeq:](cseq:) 41 INVITE
[Server:](server:) Asterisk PBX 18.0.0-rc2
[Reason:](reason:) Q.850;cause=34
[Content-Length:](content-length:) 0

[Apr 8 10:57:28] ERROR[6609]: cdr_csv.c:275 writefile: Unable to open file /var/log/asterisk//cdr-csv//Master.csv : Permission denied
[Apr 8 10:57:28] WARNING[6609]: cdr_csv.c:308 csv_log: Unable to write CSV record to master '/var/log/asterisk//cdr-csv//Master.csv' : Permission denied
<--- Received SIP request (324 bytes) from [TLS:192.168.105.102:36009](tls:192.168.105.102:36009) --->
ACK sips:5000@192.168.105.100:5061 SIP/2.0
[Via:](via:) SIP/2.0/TLS 192.168.105.102:5061;branch=z9hG4bK1176825952;rport;alias
[From:](from:) "5001" <sips:5001@192.168.105.100>;tag=345882001
[To:](to:) <sips:5000@192.168.105.100>;tag=Wo5QLnOdph1BjbyvkkOP0Cob9hPPIO38
[Call-ID:](call-id:) 236840991-5061-7@BJC.BGI.BAF.BAC
[CSeq:](cseq:) 41 ACK
[Content-Length:](content-length:) 0

and i tried same call but with UDP: the call was successfull and here are the logs:

<--- Received SIP request (1139 bytes) from [UDP:192.168.105.102:5060](udp:192.168.105.102:5060) --->
INVITE sip:5000@192.168.105.100 SIP/2.0
[Via:](via:) SIP/2.0/UDP 192.168.105.102:5060;branch=z9hG4bK1432996247;rport
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=1086321985
[To:](to:) <sip:5000@192.168.105.100>
[Call-ID:](call-id:) 1320297-5060-35@BJC.BGI.BAF.BAC
[CSeq:](cseq:) 270 INVITE
[Contact:](contact:) "5001" <sip:5001@192.168.105.102:5060>
[Max-Forwards:](max-forwards:) 70
[User-Agent:](user-agent:) Grandstream GXP1625 1.0.7.18
[Privacy:](privacy:) none
[P-Preferred-Identity:](p-preferred-identity:) "5001" <sip:5001@192.168.105.100>
[P-Emergency-Info:](p-emergency-info:) IEEE-EUI-48;eui-48-addr=00-0B-82-A0-4D-86
[Supported:](supported:) replaces, path, timer
[Allow:](allow:) INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE, MESSAGE
[Content-Type:](content-type:) application/sdp
[Accept:](accept:) application/sdp, application/dtmf-relay
[Content-Length:](content-length:) 408

v=0
o=5001 8000 8000 IN IP4 192.168.105.102
s=SIP Call
c=IN IP4 192.168.105.102
t=0 0
m=audio 5004 RTP/AVP 0 8 4 18 9 97 2 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:9 G722/8000
a=rtpmap:97 iLBC/8000
a=fmtp:97 mode=30
a=rtpmap:2 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15

<--- Transmitting SIP response (497 bytes) to [UDP:192.168.105.102:5060](udp:192.168.105.102:5060) --->
SIP/2.0 401 Unauthorized
[Via:](via:) SIP/2.0/UDP 192.168.105.102:5060;rport=5060;received=192.168.105.102;branch=z9hG4bK1432996247
[Call-ID:](call-id:) 1320297-5060-35@BJC.BGI.BAF.BAC
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=1086321985
[To:](to:) <sip:5000@192.168.105.100>;tag=z9hG4bK1432996247
[CSeq:](cseq:) 270 INVITE
[WWW-Authenticate:](www-authenticate:) Digest realm="asterisk",nonce="1649412385/71cdcf87c1bcb99d271a40b178c084ba",opaque="0a8a9d82110fa256",algorithm=md5,qop="auth"
[Server:](server:) Asterisk PBX 18.0.0-rc2
[Content-Length:](content-length:) 0

<--- Received SIP request (296 bytes) from [UDP:192.168.105.102:5060](udp:192.168.105.102:5060) --->
ACK sip:5000@192.168.105.100 SIP/2.0
[Via:](via:) SIP/2.0/UDP 192.168.105.102:5060;branch=z9hG4bK1432996247;rport
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=1086321985
[To:](to:) <sip:5000@192.168.105.100>;tag=z9hG4bK1432996247
[Call-ID:](call-id:) 1320297-5060-35@BJC.BGI.BAF.BAC
[CSeq:](cseq:) 270 ACK
[Content-Length:](content-length:) 0

<--- Received SIP request (1409 bytes) from [UDP:192.168.105.102:5060](udp:192.168.105.102:5060) --->
INVITE sip:5000@192.168.105.100 SIP/2.0
[Via:](via:) SIP/2.0/UDP 192.168.105.102:5060;branch=z9hG4bK870363195;rport
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=1086321985
[To:](to:) <sip:5000@192.168.105.100>
[Call-ID:](call-id:) 1320297-5060-35@BJC.BGI.BAF.BAC
[CSeq:](cseq:) 271 INVITE
[Contact:](contact:) "5001" <sip:5001@192.168.105.102:5060>
[Authorization:](authorization:) Digest username="5001", realm="asterisk", nonce="1649412385/71cdcf87c1bcb99d271a40b178c084ba", uri="sip:5000@192.168.105.100", response="c764410afba9593668a84950ed82e4b9", algorithm=md5, cnonce="06938650", opaque="0a8a9d82110fa256", qop=auth, nc=00000001
[Max-Forwards:](max-forwards:) 70
[User-Agent:](user-agent:) Grandstream GXP1625 1.0.7.18
[Privacy:](privacy:) none
[P-Preferred-Identity:](p-preferred-identity:) "5001" <sip:5001@192.168.105.100>
[P-Emergency-Info:](p-emergency-info:) IEEE-EUI-48;eui-48-addr=00-0B-82-A0-4D-86
[Supported:](supported:) replaces, path, timer
[Allow:](allow:) INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE, MESSAGE
[Content-Type:](content-type:) application/sdp
[Accept:](accept:) application/sdp, application/dtmf-relay
[Content-Length:](content-length:) 408

v=0
o=5001 8000 8000 IN IP4 192.168.105.102
s=SIP Call
c=IN IP4 192.168.105.102
t=0 0
m=audio 5004 RTP/AVP 0 8 4 18 9 97 2 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:9 G722/8000
a=rtpmap:97 iLBC/8000
a=fmtp:97 mode=30
a=rtpmap:2 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15

== Setting global variable 'SIPDOMAIN' to '192.168.105.100'
<--- Transmitting SIP response (322 bytes) to [UDP:192.168.105.102:5060](udp:192.168.105.102:5060) --->
SIP/2.0 100 Trying
[Via:](via:) SIP/2.0/UDP 192.168.105.102:5060;rport=5060;received=192.168.105.102;branch=z9hG4bK870363195
[Call-ID:](call-id:) 1320297-5060-35@BJC.BGI.BAF.BAC
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=1086321985
[To:](to:) <sip:5000@192.168.105.100>
[CSeq:](cseq:) 271 INVITE
[Server:](server:) Asterisk PBX 18.0.0-rc2
[Content-Length:](content-length:) 0

-- Executing [5000@phones:1] Dial("PJSIP/5001-00000000", "PJSIP/5000") in new stack
-- Called PJSIP/5000
<--- Transmitting SIP request (928 bytes) to [UDP:192.168.105.101:5060](udp:192.168.105.101:5060) --->
INVITE sip:5000@192.168.105.101:5060 SIP/2.0
[Via:](via:) SIP/2.0/UDP 192.168.105.100:5060;rport;branch=z9hG4bKPjzuoAKsl4ZClluvFYMxEFxg9ThD1BhJ7D
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=mCPh20GJF.MDi7.xBvdecVzyqgV8dJz7
[To:](to:) <sip:5000@192.168.105.101>
[Contact:](contact:) <sip:asterisk@192.168.105.100:5060>
[Call-ID:](call-id:) zNJrwjClHe2JJct7WlRxJ8qqnOtHoRwN
[CSeq:](cseq:) 2653 INVITE
[Allow:](allow:) OPTIONS, REGISTER, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, MESSAGE, REFER
[Supported:](supported:) 100rel, timer, replaces, norefersub
[Session-Expires:](session-expires:) 1800
[Min-SE:](min-se:) 90
[Max-Forwards:](max-forwards:) 70
[User-Agent:](user-agent:) Asterisk PBX 18.0.0-rc2
[Content-Type:](content-type:) application/sdp
[Content-Length:](content-length:) 265

v=0
o=- 288846336 288846336 IN IP4 192.168.105.100
s=Asterisk
c=IN IP4 192.168.105.100
t=0 0
m=audio 16188 RTP/AVP 8 0 101
a=rtpmap:8 PCMA/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=maxptime:150
a=sendrecv

<--- Received SIP response (479 bytes) from [UDP:192.168.105.101:5060](udp:192.168.105.101:5060) --->
SIP/2.0 100 Trying
[Via:](via:) SIP/2.0/UDP 192.168.105.100:5060;rport=5060;branch=z9hG4bKPjzuoAKsl4ZClluvFYMxEFxg9ThD1BhJ7D
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=mCPh20GJF.MDi7.xBvdecVzyqgV8dJz7
[To:](to:) <sip:5000@192.168.105.101>
[Call-ID:](call-id:) zNJrwjClHe2JJct7WlRxJ8qqnOtHoRwN
[CSeq:](cseq:) 2653 INVITE
[Supported:](supported:) replaces, path, timer
[User-Agent:](user-agent:) Grandstream GXP1630 1.0.7.18
[Allow:](allow:) INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE, MESSAGE
[Content-Length:](content-length:) 0

<--- Received SIP response (563 bytes) from [UDP:192.168.105.101:5060](udp:192.168.105.101:5060) --->
SIP/2.0 180 Ringing
[Via:](via:) SIP/2.0/UDP 192.168.105.100:5060;rport=5060;branch=z9hG4bKPjzuoAKsl4ZClluvFYMxEFxg9ThD1BhJ7D
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=mCPh20GJF.MDi7.xBvdecVzyqgV8dJz7
[To:](to:) <sip:5000@192.168.105.101>;tag=1443111549
[Call-ID:](call-id:) zNJrwjClHe2JJct7WlRxJ8qqnOtHoRwN
[CSeq:](cseq:) 2653 INVITE
[Contact:](contact:) <sip:5000@192.168.105.101:5060>
[Supported:](supported:) replaces, path, timer
[User-Agent:](user-agent:) Grandstream GXP1630 1.0.7.18
[Allow-Events:](allow-events:) talk, hold
[Allow:](allow:) INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE, MESSAGE
[Content-Length:](content-length:) 0

-- PJSIP/5000-00000001 is ringing
-- PJSIP/5000-00000001 is ringing
<--- Transmitting SIP response (508 bytes) to [UDP:192.168.105.102:5060](udp:192.168.105.102:5060) --->
SIP/2.0 180 Ringing
[Via:](via:) SIP/2.0/UDP 192.168.105.102:5060;rport=5060;received=192.168.105.102;branch=z9hG4bK870363195
[Call-ID:](call-id:) 1320297-5060-35@BJC.BGI.BAF.BAC
[From:](from:) "5001" <sip:5001@192.168.105.100>;tag=1086321985
[To:](to:) <sip:5000@192.168.105.100>;tag=sIAv1hekH1QUP11unKCnx1QuduRa462V
[CSeq:](cseq:) 271 INVITE
[Server:](server:) Asterisk PBX 18.0.0-rc2
[Contact:](contact:) <sip:192.168.105.100:5060>
[Allow:](allow:) OPTIONS, REGISTER, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, MESSAGE, REFER
[Content-Length:](content-length:) 0

now for further info: i registered one user at udp and one at tls:
result: i was able to call from tls user to udp user. but not from udp user to tls user!
i could not find out what is the problem!
but i am still thinking of the certificates!! although the user registered successfully but i dont know if the certificates are still used for calling, so it registered but for another reason it is not calling!

it was a port issue.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.