SIP TLS handshake failed
The TLS handshake is the exchange that sets up an encrypted session before any SIP is sent. The client says hello with the versions and ciphers it supports, the server answers with its choice and its certificate, and both derive keys. When this fails there is no session, so the SIP request is never sent and the error is reported at the transport level.
A failed handshake is different from a certificate problem, although the two are easy to confuse in logs. If the server's certificate arrived and the client then rejected it, the cause is in that certificate. If no certificate arrived at all, look at the port, the TLS settings and the network path first.
Error messages you may see
wrong version numbertls: first record does not look like a TLS handshakeremote error: tls: handshake failureread: connection reset by peer
Common causes
- The port answers plain SIP over TCP rather than TLS, often because TLS was never switched on for it, so the server reads the ClientHello as garbage.
- Client and server share no TLS version, typically a server stuck on TLS 1.0 facing a client that requires 1.2.
- There is no cipher suite or key exchange curve that both sides accept, which happens with tightly restricted cipher lists.
- The server requires a client certificate and the client has none to present.
- A firewall, NAT device or load balancer resets or drops the connection, or the handshake is too slow for the peer's timeout.
How to fix it
- Connect to the host and port with openssl s_client: a wrong version number error means the port is not speaking TLS.
- Check that the SIP server has a TLS listener on that exact port with a certificate and key loaded, and restart it after changes.
- Allow TLS 1.2 with current ECDHE cipher suites, and compare the server's list with what the peer documents.
- Take a packet capture: a reset right after the ClientHello points at the server or a firewall, while long silence points at the network path.
Platform notes
- Genesys Cloud BYOC: Genesys allows 500 ms for the TLS handshake on BYOC Cloud trunks and supports TLS 1.2, so a slow SBC or one limited to older versions fails there first.
- Microsoft Teams Direct Routing: If the connection closes right away and no OPTIONS are exchanged, Microsoft points first at the TLS version, which should be 1.2 or higher, and then at firewalls or routers on the path that close the connection.
How the free check shows it
When no TLS session could be set up, the free check reports TLS handshake failed in place of a response code. If the server sent a certificate before it ended the handshake, the certificate rows still appear, which separates a rejected client from a port that does not speak TLS. On a TLS Route a handshake failure fails the line check like any other missing answer, while certificate problems on their own never do.
Questions
Does a failed handshake mean the server is down?
Not necessarily. The server may be up and answering plain SIP, or TLS with settings this client cannot use. A TCP connection that opens and then fails at TLS proves that the host is reachable.
Why does the handshake work from one client and fail from another?
Each client offers its own versions, ciphers and SNI name, so a server can share settings with one and not the other. Compare what each one offers in a packet capture.