tto / docs / misc / send sip options with sipexer

download sipexer

provide the tls cert and key in unencrypted pem format [openssl]

./sipexer -sd -su -contact-uri "<sip:sbc01.dr.example.com:5061;transport=tls>" -tls-certificate ./cert.pem -tls-key ./cert.key tls:sip.pstnhub.microsoft.com:5061

[info] [sipexer.go:1578] main.SIPExerDialogLoop(): local socket address: 192.168.178.142:52372 (tls)
[info] [sipexer.go:1579] main.SIPExerDialogLoop(): local via address: 192.168.178.142:52372
[info] [sipexer.go:1580] main.SIPExerDialogLoop(): sending to tls 52.114.76.76:5061: [[---
OPTIONS sip:bob@sip.pstnhub.microsoft.com:5061;transport=tls SIP/2.0
Via: SIP/2.0/TLS 192.168.178.142:52372;rport;branch=z9hG4bKSG.675f3506-8cb7-45d0-a31f-de2db81cf893
From: <sip:alice@sip.pstnhub.microsoft.com>;tag=704c9365-d73d-4c45-92b6-24d185912729
To: <sip:bob@sip.pstnhub.microsoft.com>
Call-ID: c5df6372-df25-4632-8ff9-c64d2930e4ad
CSeq: 676148 OPTIONS
Date: Tue, 29 Aug 2023 12:55:54 CEST
Contact: <sip:sbc01.dr.example.com:5061;transport=tls>
User-Agent: SIPExer v1.1.0
Max-Forwards: 10
Content-Length: 0

[info] [sipexer.go:1582] main.SIPExerDialogLoop(): ---]]

[info] [sipexer.go:1633] main.SIPExerDialogLoop(): response-received: from=52.114.76.76:5061 bytes=733 data=[[---
SIP/2.0 403 Forbidden
FROM: <sip:alice@sip.pstnhub.microsoft.com>;tag=704c9365-d73d-4c45-92b6-24d185912729
TO: <sip:bob@sip.pstnhub.microsoft.com>
CSEQ: 676148 OPTIONS
CALL-ID: c5df6372-df25-4632-8ff9-c64d2930e4ad
VIA: SIP/2.0/TLS 192.168.178.142:52372;branch=z9hG4bKSG.675f3506-8cb7-45d0-a31f-de2db81cf893;rport
REASON: Q.850;cause=63;text="1940c42c-5960-4e4e-9735-8029d47f63d2;SBC certificate is not issued correctly. Provided trunk FQDN 'sbc01.dr.example.com' is not included in certificate's CN or SAN list. Certificate allows following FQDNs only: example.com, *.example.com"
CONTENT-LENGTH: 0
ALLOW: INVITE,ACK,OPTIONS,CANCEL,BYE,NOTIFY
SERVER: Microsoft.PSTNHub.SIPProxy v.2023.6.29.3 i.EUNO.10