As for my troubleshooting steps.
I can see my gateway make an outbound SIP OPTIONS ping every 60 seconds to microsoft it looks like this:
OPTIONS sip:sip.pstnhub.microsoft.com:5061;transport=tls SIP/2.0
Via: SIP/2.0/TLS sbc.example.com:5083;rport;branch=z9hG4bKe6HgFv5vDcB1a
Max-Forwards: 70
From: <sip:sip.pstnhub.microsoft.com:5061>;tag=e8S6260DyyFvp
To: <sip:sip.pstnhub.microsoft.com:5061>
Call-ID: 079a560b-82fb-123b-549c-00163e1597f2
CSeq: 54616233 OPTIONS
Contact: <sip:gw+8b28ce16-60d0-40ff-a0d8-9ec4fc1d3842@sbc.example.com:5083;transport=tls;transport=tls;gw=8b28ce16-60d0-40ff-a0d8-9ec4fc1d3842>
User-Agent: FreeSWITCH
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER, NOTIFY
Supported: timer, path, replaces
Allow-Events: talk, hold, conference, refer
Content-Length: 0
Microsoft appropriately and immediately responds with :
SIP/2.0 200 OK
FROM: <sip:sip.pstnhub.microsoft.com:5061>;tag=e8S6260DyyFvp
TO: <sip:sip.pstnhub.microsoft.com:5061>
CSEQ: 54616233 OPTIONS
CALL-ID: 079a560b-82fb-123b-549c-00163e1597f2
VIA: SIP/2.0/TLS sbc.example.com:5083;branch=z9hG4bKe6HgFv5vDcB1a;rport
CONTENT-LENGTH: 0
ALLOW: INVITE,ACK,OPTIONS,CANCEL,BYE,NOTIFY
SERVER: Microsoft.PSTNHub.SIPProxy v.2022.7.18.3 i.USWE2.6
At this point according to https://docs.microsoft.com/en-us/mi...ct-routing/sip-options-tls-certificate-issues
MS is supposed to then send a SIP OPTIONS request to my server, to which I am supposed to respond with a 200 OK and then my trunk should be marked as active and all will be well with the world. However, I never see a sip options request from Microsoft.
Their document says this about this case (For everyone's reference SBC is Fusionpbx to MS, and SIP proxy is MS's side):
"The SBC receives the 200 OK response from the SIP proxy but not the SIP options that were sent from the SIP proxy. If this error occurs, make sure that the FQDN that's listed in the Record-Route or Contact header is correct and resolves to the correct IP address.
Another possible cause for this issue might be firewall rules that are preventing incoming traffic. Make sure that firewall rules are configured to allow incoming connections from all SIP proxy signalling IP addresses."
My FQDN resolves properly on the open internet to a single IP address, and Microsoft is able to send calls there as well. The firewall at this point is wide open to MS on this port, as evidenced by outbound calls from Teams clients working successfully to my FusionPBX machine. I can see normal sip phone call traffic occur with sngrep via my encrypted sip capture translation.
So, I suppose something could still be wrong with my tls configuration, I have tried two separate Letsencrypt certificates, one with only the FQDN and one a wildcard???
I can see my gateway make an outbound SIP OPTIONS ping every 60 seconds to microsoft it looks like this:
OPTIONS sip:sip.pstnhub.microsoft.com:5061;transport=tls SIP/2.0
Via: SIP/2.0/TLS sbc.example.com:5083;rport;branch=z9hG4bKe6HgFv5vDcB1a
Max-Forwards: 70
From: <sip:sip.pstnhub.microsoft.com:5061>;tag=e8S6260DyyFvp
To: <sip:sip.pstnhub.microsoft.com:5061>
Call-ID: 079a560b-82fb-123b-549c-00163e1597f2
CSeq: 54616233 OPTIONS
Contact: <sip:gw+8b28ce16-60d0-40ff-a0d8-9ec4fc1d3842@sbc.example.com:5083;transport=tls;transport=tls;gw=8b28ce16-60d0-40ff-a0d8-9ec4fc1d3842>
User-Agent: FreeSWITCH
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER, NOTIFY
Supported: timer, path, replaces
Allow-Events: talk, hold, conference, refer
Content-Length: 0
Microsoft appropriately and immediately responds with :
SIP/2.0 200 OK
FROM: <sip:sip.pstnhub.microsoft.com:5061>;tag=e8S6260DyyFvp
TO: <sip:sip.pstnhub.microsoft.com:5061>
CSEQ: 54616233 OPTIONS
CALL-ID: 079a560b-82fb-123b-549c-00163e1597f2
VIA: SIP/2.0/TLS sbc.example.com:5083;branch=z9hG4bKe6HgFv5vDcB1a;rport
CONTENT-LENGTH: 0
ALLOW: INVITE,ACK,OPTIONS,CANCEL,BYE,NOTIFY
SERVER: Microsoft.PSTNHub.SIPProxy v.2022.7.18.3 i.USWE2.6
At this point according to https://docs.microsoft.com/en-us/mi...ct-routing/sip-options-tls-certificate-issues
MS is supposed to then send a SIP OPTIONS request to my server, to which I am supposed to respond with a 200 OK and then my trunk should be marked as active and all will be well with the world. However, I never see a sip options request from Microsoft.
Their document says this about this case (For everyone's reference SBC is Fusionpbx to MS, and SIP proxy is MS's side):
"The SBC receives the 200 OK response from the SIP proxy but not the SIP options that were sent from the SIP proxy. If this error occurs, make sure that the FQDN that's listed in the Record-Route or Contact header is correct and resolves to the correct IP address.
Another possible cause for this issue might be firewall rules that are preventing incoming traffic. Make sure that firewall rules are configured to allow incoming connections from all SIP proxy signalling IP addresses."
My FQDN resolves properly on the open internet to a single IP address, and Microsoft is able to send calls there as well. The firewall at this point is wide open to MS on this port, as evidenced by outbound calls from Teams clients working successfully to my FusionPBX machine. I can see normal sip phone call traffic occur with sngrep via my encrypted sip capture translation.
So, I suppose something could still be wrong with my tls configuration, I have tried two separate Letsencrypt certificates, one with only the FQDN and one a wildcard???