Check isSSL after other checks (NPE)
@@ -784,14 +784,13 @@ else if (TlsUtils.isSSL(tlsServerContext))
protected void handleAlertWarningMessage(short alertDescription)
throws IOException
- {
- if (TlsUtils.isSSL(tlsServerContext))
{
/*
* SSL 3.0 If the server has sent a certificate request Message, the client must send
* either the certificate message or a no_certificate alert.
*/
- if (AlertDescription.no_certificate == alertDescription && null != certificateRequest)
+ if (AlertDescription.no_certificate == alertDescription && null != certificateRequest
+ && TlsUtils.isSSL(tlsServerContext))
{
switch (this.connection_state)
{
@@ -808,7 +807,6 @@ protected void handleAlertWarningMessage(short alertDescription)
}
}
}
- }
super.handleAlertWarningMessage(alertDescription);
}
