@@ -3605,11 +3605,11 @@ static void usage(const char *argv0, const char *cmd)
3605
3605
printf ("%1s[ --help ]\n\n" , "" );
3606
3606
}
3607
3607
if (on_list (cmd , cmds_sign )) {
3608
- printf ("%1s[ sign ] -pkcs12 <pkcs12file > | ( [ -certs <certfile > | -spc <certfile > ]\n" , "" );
3608
+ printf ("%1s[ sign ] -pkcs12 <file > | ( [ -certs <file|URI > | -spc <file > ]\n" , "" );
3609
3609
#if !defined(OPENSSL_NO_ENGINE ) || OPENSSL_VERSION_NUMBER >=0x30000000L
3610
- printf ("%12s( -key <keyfile> | ( -key <pkcs11 key URI> -pkcs11module <module> [ -pkcs11cert <pkcs11 cert URI> ] )\n" , "" );
3610
+ printf ("%12s( -key <file| URI> [ -pkcs11module <module> ] [ -pkcs11cert <pkcs11 cert URI> ] )\n" , "" );
3611
3611
#else /* !defined(OPENSSL_NO_ENGINE) || OPENSSL_VERSION_NUMBER>=0x30000000L */
3612
- printf ("%12s-key <keyfile > )\n" , "" );
3612
+ printf ("%12s-key <file|URI > )\n" , "" );
3613
3613
#endif /* !defined(OPENSSL_NO_ENGINE) || OPENSSL_VERSION_NUMBER>=0x30000000L */
3614
3614
#if OPENSSL_VERSION_NUMBER >=0x30000000L
3615
3615
printf ("%12s[ -provider <provider> | " , "" );
@@ -3619,7 +3619,7 @@ static void usage(const char *argv0, const char *cmd)
3619
3619
#endif /* OPENSSL_NO_ENGINE */
3620
3620
#endif /* OPENSSL_VERSION_NUMBER>=0x30000000L */
3621
3621
#ifndef OPENSSL_NO_ENGINE
3622
- printf ("%s( -engine <engine> [ -login ] [ -engineCtrl <command[:parameter]> ] ) ] ) ) \n" , "" );
3622
+ printf ("%s( -engine <engine> [ -login ] [ -engineCtrl <command[:parameter]> ] ) ] )\n" , "" );
3623
3623
#endif /* OPENSSL_NO_ENGINE */
3624
3624
#if OPENSSL_VERSION_NUMBER >=0x30000000L
3625
3625
printf ("%12s[ -nolegacy ]\n" , "" );
@@ -3630,73 +3630,73 @@ static void usage(const char *argv0, const char *cmd)
3630
3630
#endif /* PROVIDE_ASKPASS */
3631
3631
printf ("%1s[ -readpass <file> ]\n" , "" );
3632
3632
printf ("%12s(use \"-\" with readpass to read from stdin)\n" , "" );
3633
- printf ("%12s[ -ac <crosscertfile > ]\n" , "" );
3633
+ printf ("%12s[ -ac <file > ]\n" , "" );
3634
3634
printf ("%12s[ -h {md5,sha1,sha2(56),sha384,sha512} ]\n" , "" );
3635
3635
printf ("%12s[ -n <desc> ] [ -i <url> ] [ -jp <level> ] [ -comm ]\n" , "" );
3636
3636
printf ("%12s[ -ph ]\n" , "" );
3637
3637
printf ("%12s[ -t <timestampurl> [ -t ... ] [ -p <proxy> ] [ -noverifypeer ]\n" , "" );
3638
3638
printf ("%12s[ -ts <timestampurl> [ -ts ... ] [ -p <proxy> ] [ -noverifypeer ] ]\n" , "" );
3639
- printf ("%12s[ -TSA-certs <TSA-certfile > ] [ -TSA-key <TSA-keyfile > ]\n" , "" );
3639
+ printf ("%12s[ -TSA-certs <file > ] [ -TSA-key <file > ]\n" , "" );
3640
3640
printf ("%12s[ -TSA-time <unix-time> ]\n" , "" );
3641
- printf ("%12s[ -HTTPS-CAfile <infile > ]\n" , "" );
3642
- printf ("%12s[ -HTTPS-CRLfile <infile > ]\n" , "" );
3641
+ printf ("%12s[ -HTTPS-CAfile <file > ]\n" , "" );
3642
+ printf ("%12s[ -HTTPS-CRLfile <file > ]\n" , "" );
3643
3643
printf ("%12s[ -time <unix-time> ]\n" , "" );
3644
- printf ("%12s[ -addUnauthenticatedBlob [ -blobFile <blobfile > ] ]\n" , "" );
3644
+ printf ("%12s[ -addUnauthenticatedBlob [ -blobFile <file > ] ]\n" , "" );
3645
3645
printf ("%12s[ -nest ]\n" , "" );
3646
3646
printf ("%12s[ -verbose ]\n" , "" );
3647
3647
printf ("%12s[ -add-msi-dse ]\n" , "" );
3648
3648
printf ("%12s[ -pem ]\n" , "" );
3649
- printf ("%12s[ -in ] <infile > [-out ] <outfile >\n\n" , "" );
3649
+ printf ("%12s[ -in ] <file > [-out ] <file >\n\n" , "" );
3650
3650
}
3651
3651
if (on_list (cmd , cmds_extract_data )) {
3652
3652
printf ("%1sextract-data [ -pem ]\n" , "" );
3653
3653
printf ("%12s[ -h {md5,sha1,sha2(56),sha384,sha512} ]\n" , "" );
3654
3654
printf ("%12s[ -ph ]\n" , "" );
3655
3655
printf ("%12s[ -add-msi-dse ]\n" , "" );
3656
- printf ("%12s[ -in ] <infile > [ -out ] <datafile >\n\n" , "" );
3656
+ printf ("%12s[ -in ] <file > [ -out ] <file >\n\n" , "" );
3657
3657
}
3658
3658
if (on_list (cmd , cmds_add )) {
3659
- printf ("%1sadd [ -addUnauthenticatedBlob [ -blobFile <blobfile > ] ]\n" , "" );
3659
+ printf ("%1sadd [ -addUnauthenticatedBlob [ -blobFile <file > ] ]\n" , "" );
3660
3660
printf ("%12s[ -t <timestampurl> [ -t ... ] [ -p <proxy> ] [ -noverifypeer ]\n" , "" );
3661
3661
printf ("%12s[ -ts <timestampurl> [ -ts ... ] [ -p <proxy> ] [ -noverifypeer ] ]\n" , "" );
3662
- printf ("%12s[ -TSA-certs <TSA-certfile > ] [ -TSA-key <TSA-keyfile > ]\n" , "" );
3662
+ printf ("%12s[ -TSA-certs <file > ] [ -TSA-key <file > ]\n" , "" );
3663
3663
printf ("%12s[ -TSA-time <unix-time> ]\n" , "" );
3664
- printf ("%12s[ -HTTPS-CAfile <infile > ]\n" , "" );
3665
- printf ("%12s[ -HTTPS-CRLfile <infile > ]\n" , "" );
3664
+ printf ("%12s[ -HTTPS-CAfile <file > ]\n" , "" );
3665
+ printf ("%12s[ -HTTPS-CRLfile <file > ]\n" , "" );
3666
3666
printf ("%12s[ -h {md5,sha1,sha2(56),sha384,sha512} ]\n" , "" );
3667
3667
printf ("%12s[ -index <index> ]\n" , "" );
3668
3668
printf ("%12s[ -verbose ]\n" , "" );
3669
3669
printf ("%12s[ -add-msi-dse ]\n" , "" );
3670
- printf ("%12s[ -in ] <infile > [ -out ] <outfile >\n\n" , "" );
3670
+ printf ("%12s[ -in ] <file > [ -out ] <file >\n\n" , "" );
3671
3671
}
3672
3672
if (on_list (cmd , cmds_attach )) {
3673
- printf ("%1sattach-signature [ -sigin ] <sigfile >\n" , "" );
3674
- printf ("%12s[ -CAfile <infile > ]\n" , "" );
3675
- printf ("%12s[ -CRLfile <infile > ]\n" , "" );
3676
- printf ("%12s[ -TSA-CAfile <infile > ]\n" , "" );
3677
- printf ("%12s[ -TSA-CRLfile <infile > ]\n" , "" );
3673
+ printf ("%1sattach-signature [ -sigin ] <file >\n" , "" );
3674
+ printf ("%12s[ -CAfile <file > ]\n" , "" );
3675
+ printf ("%12s[ -CRLfile <file > ]\n" , "" );
3676
+ printf ("%12s[ -TSA-CAfile <file > ]\n" , "" );
3677
+ printf ("%12s[ -TSA-CRLfile <file > ]\n" , "" );
3678
3678
printf ("%12s[ -time <unix-time> ]\n" , "" );
3679
3679
printf ("%12s[ -h {md5,sha1,sha2(56),sha384,sha512} ]\n" , "" );
3680
3680
printf ("%12s[ -require-leaf-hash {md5,sha1,sha2(56),sha384,sha512}:XXXXXXXXXXXX... ]\n" , "" );
3681
3681
printf ("%12s[ -nest ]\n" , "" );
3682
3682
printf ("%12s[ -add-msi-dse ]\n" , "" );
3683
- printf ("%12s[ -in ] <infile > [ -out ] <outfile >\n\n" , "" );
3683
+ printf ("%12s[ -in ] <file > [ -out ] <file >\n\n" , "" );
3684
3684
}
3685
3685
if (on_list (cmd , cmds_extract )) {
3686
3686
printf ("%1sextract-signature [ -pem ]\n" , "" );
3687
- printf ("%12s[ -in ] <infile > [ -out ] <sigfile >\n\n" , "" );
3687
+ printf ("%12s[ -in ] <file > [ -out ] <file >\n\n" , "" );
3688
3688
}
3689
3689
if (on_list (cmd , cmds_remove ))
3690
- printf ("%1sremove-signature [ -in ] <infile > [ -out ] <outfile >\n\n" , "" );
3690
+ printf ("%1sremove-signature [ -in ] <file > [ -out ] <file >\n\n" , "" );
3691
3691
if (on_list (cmd , cmds_verify )) {
3692
- printf ("%1sverify [ -in ] <infile >\n" , "" );
3693
- printf ("%12s[ -c | -catalog <infile > ]\n" , "" );
3694
- printf ("%12s[ -CAfile <infile > ]\n" , "" );
3695
- printf ("%12s[ -CRLfile <infile > ]\n" , "" );
3696
- printf ("%12s[ -HTTPS-CAfile <infile > ]\n" , "" );
3697
- printf ("%12s[ -HTTPS-CRLfile <infile > ]\n" , "" );
3698
- printf ("%12s[ -TSA-CAfile <infile > ]\n" , "" );
3699
- printf ("%12s[ -TSA-CRLfile <infile > ]\n" , "" );
3692
+ printf ("%1sverify [ -in ] <file >\n" , "" );
3693
+ printf ("%12s[ -c | -catalog <file > ]\n" , "" );
3694
+ printf ("%12s[ -CAfile <file > ]\n" , "" );
3695
+ printf ("%12s[ -CRLfile <file > ]\n" , "" );
3696
+ printf ("%12s[ -HTTPS-CAfile <file > ]\n" , "" );
3697
+ printf ("%12s[ -HTTPS-CRLfile <file > ]\n" , "" );
3698
+ printf ("%12s[ -TSA-CAfile <file > ]\n" , "" );
3699
+ printf ("%12s[ -TSA-CRLfile <file > ]\n" , "" );
3700
3700
printf ("%12s[ -p <proxy> ]\n" , "" );
3701
3701
printf ("%12s[ -index <index> ]\n" , "" );
3702
3702
printf ("%12s[ -ignore-timestamp ]\n" , "" );
@@ -3857,7 +3857,7 @@ static void help_for(const char *argv0, const char *cmd)
3857
3857
if (on_list (cmd , cmds_CAfile ))
3858
3858
printf ("%-24s= the file containing one or more trusted certificates in PEM format\n" , "-CAfile" );
3859
3859
if (on_list (cmd , cmds_certs ))
3860
- printf ("%-24s= the signing certificate to use \n" , "-certs, -spc" );
3860
+ printf ("%-24s= certificate chain ( signing cert + intermediates) \n" , "-certs, -spc" );
3861
3861
if (on_list (cmd , cmds_comm ))
3862
3862
printf ("%-24s= set commercial purpose (default: individual purpose)\n" , "-comm" );
3863
3863
if (on_list (cmd , cmds_CRLfile ))
@@ -3882,7 +3882,7 @@ static void help_for(const char *argv0, const char *cmd)
3882
3882
printf ("%-24s= disable legacy mode and don't automatically load the legacy provider\n" , "-nolegacy" );
3883
3883
#endif /* OPENSSL_VERSION_NUMBER>=0x30000000L */
3884
3884
if (on_list (cmd , cmds_key ))
3885
- printf ("%-24s= the private key to use or PKCS#11 URI identifies a key in the token \n" , "-key" );
3885
+ printf ("%-24s= private key (optionally with signing cert) from file or URI \n" , "-key" );
3886
3886
if (on_list (cmd , cmds_n ))
3887
3887
printf ("%-24s= specifies a description of the signed content\n" , "-n" );
3888
3888
if (on_list (cmd , cmds_nest ))
@@ -4364,8 +4364,8 @@ static int read_crypto_params(GLOBAL_OPTIONS *options)
4364
4364
(void )provider_load (options -> provider );
4365
4365
}
4366
4366
#endif /* OPENSSL_VERSION_NUMBER>=0x30000000L */
4367
- /* Load the private key ('-key' option) */
4368
- load_objects_from_store (options -> keyfile , options -> pass , & options -> pkey , NULL , NULL );
4367
+ /* Load the private key and the signing certificate ('-key' option) */
4368
+ load_objects_from_store (options -> keyfile , options -> pass , & options -> pkey , options -> certs , NULL );
4369
4369
}
4370
4370
#if OPENSSL_VERSION_NUMBER < 0x1010108f
4371
4371
/* Workaround for OpenSSL 1.1.1g and older, where the store API does not
0 commit comments