Hello
I have a FreePBX 16 installed on my home server with Matrix FXO-FXS gateway (for converting CO lines to SIP trunks)
My setup
FreePBX - 192.168.1.81
Matrix Gateway -192.168.1.240 - connected to FreePBX using Peer-to-Peer trunk
Pfsense+ firewall with NAT and firewall rules
Dynamic public IP allocation by ISP - attached to DDNS domain by pfsense.
softphone - GSwave Lite on android and on iOS
I have been trying to switch matrix gateway from chan to pjsip… i am able to make outgoing calls on the pjsip but incoming calls are not getting anywhere.
in my chan_sip setup, all incomings calls are getting diverted to IVR and it works fine.
Any help is appreciated…
Incoming call sngrep Trace
2024/11/01 14:28:27.185643 192.168.1.240:5060 -> 192.168.1.81:5060
INVITE sip:[email protected] SIP/2.0
From: <sip:[email protected]>;tag=6bddf0-f001a8c0-13c4-672497d6-29c1790d-672497d6
To: <sip:[email protected]>
Call-ID: 6c2968-f001a8c0-13c4-672497d6-4073ab77-672497d6
CSeq: 1 INVITE
Via: SIP/2.0/UDP 192.168.1.240:5060;rport;branch=z9hG4bK-672497d6-e6f11c4e-6916e712
Max-Forwards: 70
Supported: replaces
User-Agent: Matrix-SETUVGFXNG
Contact: <sip:192.168.1.240:5060;transport=udp>
Allow: INVITE,BYE,ACK,CANCEL,REFER,NOTIFY,OPTIONS
Content-Type: application/sdp
Content-Length: 464
v=0
o=- 1323421410 1323421410 IN IP4 192.168.1.240
s=Matrix-SETUVGFXNG
c=IN IP4 192.168.1.240
t=0 0
m=audio 8062 RTP/AVP 18 4 3 100 99 0 8 101
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:4 G723/8000
OUTGOING CALL sngrep trace
2024/11/01 14:27:48.275293 192.168.1.90:57587 -> 192.168.1.81:5160
INVITE sip:[email protected]:5160 SIP/2.0
Via: SIP/2.0/UDP 192.168.1.90:57587;rport;branch=z9hG4bKPjz8-9Wfrb0Gtz1lUOG0vTkeoG6Hap8AVM
Max-Forwards: 70
From: "Puneet Maheshwari" <sip:[email protected]>;tag=Iiqxrz6593M0Nnjn99nRp5BgYi71NFXf
To: sip:[email protected]
Contact: "Puneet Maheshwari" <sip:[email protected]:57587;ob>
Call-ID: VZR7mdI6Mb0iBI668qcHePM1vimwSY7X
CSeq: 9315 INVITE
Allow: PRACK, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS
Supported: replaces, 100rel, norefersub
User-Agent: Telephone 1.6
Content-Type: application/sdp
Content-Length: 476
v=0
o=- 3939440268 3939440268 IN IP4 192.168.1.90
s=pjmedia
b=AS:117
t=0 0
a=X-nat:0
m=audio 4000 RTP/AVP 96 9 8 0 101 102
c=IN IP4 192.168.1.90
b=TIAS:96000
a=rtcp:4001 IN IP4 192.168.1.90
a=sendrecv
a=rtpmap:96 opus/48000/2
a=fmtp:96 useinbandfec=1
a=rtpmap:9 G722/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/48000
a=fmtp:101 0-16
a=rtpmap:102 telephone-event/8000
a=fmtp:102 0-16
a=ssrc:402538590 cname:795399525f7714b8
2024/11/01 14:27:48.801700 192.168.1.81:5160 -> 192.168.1.240:5060
INVITE sip:[email protected]:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.1.81:5160;rport;branch=z9hG4bKPj0dc7afa1-d24a-4f1d-92f4-3a72a8ab4fe7
From: "Puneet_Devices" <sip:[email protected]>;tag=9e95ee78-2b9b-4963-9ad4-582b50350f82
To: <sip:[email protected]>
Contact: <sip:[email protected]:5160>
Call-ID: fee5865d-9917-4c5c-bb3e-43c3abf380d4
CSeq: 11545 INVITE
Allow: OPTIONS, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, REGISTER, SUBSCRIBE, NOTIFY, PUBLISH, MESSAGE, REFER
Supported: 100rel, timer, replaces, norefersub, histinfo
Session-Expires: 1800
Min-SE: 90
Max-Forwards: 70
User-Agent: FPBX-16.0.40.8(18.20.2)
Content-Type: application/sdp
Content-Length: 498
v=0
o=- 1247773936 1247773936 IN IP4 192.168.1.81
s=Asterisk
c=IN IP4 192.168.1.81
t=0 0
m=audio 11962 RTP/AVP 0 8 9 3 111 4 110 117 119 18 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:9 G722/8000
a=rtpmap:3 GSM/8000
a=rtpmap:111 G726-32/8000
a=rtpmap:4 G723/8000
a=rtpmap:110 speex/8000
a=rtpmap:117 speex/16000
a=rtpmap:119 speex/32000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=maxptime:60
a=sendrecv