Handle server extension processing for status_request
protected Vector supportedSignatureAlgorithms;
protected int[] namedCurves;
protected short[] clientECPointFormats, serverECPointFormats;
+ protected CertificateStatusRequest certificateStatusRequest;
protected ProtocolVersion serverVersion;
protected int selectedCipherSuite;
@@ -247,6 +248,8 @@ public void processClientExtensions(Hashtable clientExtensions)
this.namedCurves = TlsECCUtils.getSupportedEllipticCurvesExtension(clientExtensions);
this.clientECPointFormats = TlsECCUtils.getSupportedPointFormatsExtension(clientExtensions);
+
+ this.certificateStatusRequest = TlsExtensionsUtils.getStatusRequestExtension(clientExtensions);
}
/*
@@ -369,6 +372,16 @@ public Hashtable getServerExtensions()
TlsECCUtils.addSupportedPointFormatsExtension(checkServerExtensions(), serverECPointFormats);
}
+ if (this.certificateStatusRequest != null)
+ {
+ /*
+ * RFC 6066 8. If a server returns a "CertificateStatus" message, then the server MUST
+ * have included an extension of type "status_request" with empty "extension_data" in
+ * the extended server hello.
+ */
+ checkServerExtensions().put(TlsExtensionsUtils.EXT_status_request, TlsExtensionsUtils.createEmptyExtensionData());
+ }
+
return serverExtensions;
}
