HTTP 495 nginx Client Certificate Error
nginx uses the internal code 495 when it encounters an error verifying a client certificate. This relates to client authentication on the connection terminating at nginx. A custom error page or the default error handler can present a different response code to the client.
Check the certificate the client presented
Verify its validity dates, certificate chain and the trust settings on the nginx instance. If the connection passes through a device that terminates TLS, determine which system actually initiates the next TLS connection and presents the client certificate.
Retest with the configured certificate and route
Use the site’s supported mutual TLS client setup and compare the nginx verification result with a known working connection. A valid client certificate for one service may use a different chain from the one required here. If nginx expected a certificate and received none, see 496.
Use the verification result to narrow the error
On a service you operate, identify the request in nginx's logs. The $ssl_client_verify variable can show FAILED:reason when verification fails. A newly renewed client certificate, for instance, can trigger this if its issuing chain differs from the one the server trusts. Compare the failure with a working client from the same expected issuer and verify which intermediate certificates the client presents. Log the outcome and a request identifier, and keep certificate details limited to what diagnosis requires.
Check which certificate belongs to which connection
An HTTPS setup can have one certificate that the server presents to the browser and another that a mutual TLS client presents to the server. A 495 is about verification of the client certificate at the nginx listener. If there is a terminating proxy in front, correlate its upstream TLS session with the nginx failure. The upstream certificate needs to be issued and configured for that connection according to the service's documented trust policy.