]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
openssl: dhparam: Print warning if -in argument is ignored
authorDaniel Fiala <daniel@openssl.org>
Fri, 29 Apr 2022 07:33:49 +0000 (09:33 +0200)
committerTomas Mraz <tomas@openssl.org>
Wed, 4 May 2022 07:29:17 +0000 (09:29 +0200)
Fixes: openssl#18146
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/18206)

apps/dhparam.c

index a0c0c064aa73306ad5d43ae4058d6138002c758c..b9ce418c61efcb2132527e10640ae692f41ed0d3 100644 (file)
@@ -190,6 +190,10 @@ int dhparam_main(int argc, char **argv)
     if (num) {
         const char *alg = dsaparam ? "DSA" : "DH";
 
+        if (infile != NULL) {
+            BIO_printf(bio_err, "Warning, input file %s ignored\n", infile);
+        }
+
         ctx = EVP_PKEY_CTX_new_from_name(NULL, alg, NULL);
         if (ctx == NULL) {
             BIO_printf(bio_err,