提交 e9d09283 编写于 作者: M mullan

6915939: Exception should be thrown if OCSP SingleResponses contain unresolved critical extensions

Reviewed-by: xuelei
上级 d79d21f4
......@@ -574,10 +574,18 @@ public final class OCSPResponse {
(singleExtDer.length);
for (int i = 0; i < singleExtDer.length; i++) {
Extension ext = new Extension(singleExtDer[i]);
singleExtensions.put(ext.getId(), ext);
if (DEBUG != null) {
DEBUG.println("OCSP single extension: " + ext);
}
// We don't support any extensions yet. Therefore, if it
// is critical we must throw an exception because we
// don't know how to process it.
if (ext.isCritical()) {
throw new IOException(
"Unsupported OCSP critical extension: " +
ext.getExtensionId());
}
singleExtensions.put(ext.getId(), ext);
}
} else {
singleExtensions = Collections.emptyMap();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册