summaryrefslogtreecommitdiff
path: root/src/usr.bin/openssl/verify.c
diff options
context:
space:
mode:
authortb <>2023-04-14 15:27:13 +0000
committertb <>2023-04-14 15:27:13 +0000
commit1a5bd4cb78097710de5283a737286c1b65609dc7 (patch)
tree7aed66c51404da4ea67dbb87b6191ab6c0e9a5ee /src/usr.bin/openssl/verify.c
parentbe3f11b57177567c1f951c5428261d6d8d9ee729 (diff)
downloadopenbsd-1a5bd4cb78097710de5283a737286c1b65609dc7.tar.gz
openbsd-1a5bd4cb78097710de5283a737286c1b65609dc7.tar.bz2
openbsd-1a5bd4cb78097710de5283a737286c1b65609dc7.zip
Drop policy printing from openssl
Nothing really uses the policy tree. It's desgined with built-in DoS capabilities directly from the RFC. It will be removed from the attack surface and replaced with something equivalent that doesn't grow exponentially with the depth. This removes the only reason the policy tree itself ever leaked out of the library. ok jsing
Diffstat (limited to 'src/usr.bin/openssl/verify.c')
-rw-r--r--src/usr.bin/openssl/verify.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/usr.bin/openssl/verify.c b/src/usr.bin/openssl/verify.c
index b412623991..b4e0f33f6a 100644
--- a/src/usr.bin/openssl/verify.c
+++ b/src/usr.bin/openssl/verify.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: verify.c,v 1.16 2023/03/06 14:32:06 tb Exp $ */ 1/* $OpenBSD: verify.c,v 1.17 2023/04/14 15:27:13 tb Exp $ */
2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
@@ -427,7 +427,6 @@ cb(int ok, X509_STORE_CTX *ctx)
427 X509_verify_cert_error_string(cert_error)); 427 X509_verify_cert_error_string(cert_error));
428 switch (cert_error) { 428 switch (cert_error) {
429 case X509_V_ERR_NO_EXPLICIT_POLICY: 429 case X509_V_ERR_NO_EXPLICIT_POLICY:
430 policies_print(NULL, ctx);
431 case X509_V_ERR_CERT_HAS_EXPIRED: 430 case X509_V_ERR_CERT_HAS_EXPIRED:
432 431
433 /* 432 /*
@@ -452,8 +451,6 @@ cb(int ok, X509_STORE_CTX *ctx)
452 return ok; 451 return ok;
453 452
454 } 453 }
455 if (cert_error == X509_V_OK && ok == 2)
456 policies_print(NULL, ctx);
457 if (!cfg.verbose) 454 if (!cfg.verbose)
458 ERR_clear_error(); 455 ERR_clear_error();
459 return (ok); 456 return (ok);