SSL_ForceHandshake returns a PRErrorCode, which is used for all sorts of
IO-related errors. It is not defined which subset of error codes might be
returned by the function, so there's no clean way of turning the error code
into something useful to the application. The error code is currently thrown
away by SSLSocket.forceHandshake for this reason.

Patrick wrote:

> Hello,
>
> I have a client application which gets a SocketException error in
> SSLSocket's forceHandshake() when it uses an invalid certificate. That's
> good however the SocketException message only gives me
> "SSL_ForceHandshake returned an error". What is the best way for the
> client to get a more meaningful reason from the server? I did not see a
> mechanism already built in NSS/JSS for the client to retrieve the reason
> from the SSLSocket (I beleice the socket is closed)
>
> -- Patrick


Reply via email to