Perform DANE-EE(3) name checks by default
[openssl.git] / crypto / x509 / x509_vfy.c
index 469a0a869366091c3261740f566c0e7eecf409c7..ee1c9af977509f104fccc44e7385a87a263c00f2 100644 (file)
@@ -2765,6 +2765,10 @@ static int dane_verify(X509_STORE_CTX *ctx)
         /* Callback invoked as needed */
         if (!check_leaf_suiteb(ctx, cert))
             return 0;
+        /* Callback invoked as needed */
+        if ((dane->flags & DANE_FLAG_NO_DANE_EE_NAMECHECKS) == 0 &&
+            !check_id(ctx))
+            return 0;
         /* Bypass internal_verify(), issue depth 0 success callback */
         ctx->error_depth = 0;
         ctx->current_cert = cert;