]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
x509_vfy.c: extend documenting comment for X509_STORE_CTX_purpose_inherit()
authorDr. David von Oheimb <dev@ddvo.net>
Mon, 9 Dec 2024 21:03:30 +0000 (22:03 +0100)
committerTomas Mraz <tomas@openssl.org>
Tue, 9 Sep 2025 07:50:05 +0000 (09:50 +0200)
Reviewed-by: Paul Dale <ppzgs1@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/18764)

crypto/x509/x509_vfy.c

index 83c32915c0b6830a8d0695e2e0eefd8c34672641..1a7b35d0668d7f76ef70fa7d03a4a1262322385f 100644 (file)
@@ -2606,12 +2606,15 @@ int X509_STORE_CTX_set_trust(X509_STORE_CTX *ctx, int trust)
 }
 
 /*
- * This function is used to set the X509_STORE_CTX purpose and trust values.
+ * Use this function to set the X509_STORE_CTX purpose and/or trust id values.
+ * The |def_purpose| argument is used if the given purpose value is 0.
+ * The |purpose| is unchanged if also the def_purpose argument is 0.
+ * The |trust| is unchanged if the given trust value is X509_TRUST_DEFAULT.
  * This is intended to be used when another structure has its own trust and
- * purpose values which (if set) will be inherited by the ctx. If they aren't
- * set then we will usually have a default purpose in mind which should then
- * be used to set the trust value. An example of this is SSL use: an SSL
- * structure will have its own purpose and trust settings which the
+ * purpose values, which (if set) will be inherited by the |ctx|. If they aren't
+ * set then we will usually have a default purpose in mind, which should then
+ * be used to set the trust id. An example of this is SSL use: an SSL
+ * structure will have its own purpose and trust settings, which the
  * application can set: if they aren't set then we use the default of SSL
  * client/server.
  */