diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib/libssl/src/apps/cms.c | 9 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/dgst.c | 8 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/dhparam.c | 10 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/dsaparam.c | 7 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/ecparam.c | 9 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/gendh.c | 10 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/gendsa.c | 11 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/genrsa.c | 9 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/pkcs12.c | 10 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/rand.c | 10 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/req.c | 9 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/s_client.c | 8 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/s_server.c | 7 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/smime.c | 10 | ||||
| -rw-r--r-- | src/lib/libssl/src/apps/ts.c | 7 |
15 files changed, 11 insertions, 123 deletions
diff --git a/src/lib/libssl/src/apps/cms.c b/src/lib/libssl/src/apps/cms.c index 56a7c95630..76178b40e2 100644 --- a/src/lib/libssl/src/apps/cms.c +++ b/src/lib/libssl/src/apps/cms.c | |||
| @@ -127,7 +127,6 @@ cms_main(int argc, char **argv) | |||
| 127 | char *to = NULL, *from = NULL, *subject = NULL; | 127 | char *to = NULL, *from = NULL, *subject = NULL; |
| 128 | char *CAfile = NULL, *CApath = NULL; | 128 | char *CAfile = NULL, *CApath = NULL; |
| 129 | char *passargin = NULL, *passin = NULL; | 129 | char *passargin = NULL, *passin = NULL; |
| 130 | char *inrand = NULL; | ||
| 131 | const EVP_MD *sign_md = NULL; | 130 | const EVP_MD *sign_md = NULL; |
| 132 | int informat = FORMAT_SMIME, outformat = FORMAT_SMIME; | 131 | int informat = FORMAT_SMIME, outformat = FORMAT_SMIME; |
| 133 | int rctformat = FORMAT_SMIME, keyform = FORMAT_PEM; | 132 | int rctformat = FORMAT_SMIME, keyform = FORMAT_PEM; |
| @@ -315,11 +314,6 @@ cms_main(int argc, char **argv) | |||
| 315 | BIO_printf(bio_err, "Invalid OID %s\n", *args); | 314 | BIO_printf(bio_err, "Invalid OID %s\n", *args); |
| 316 | goto argerr; | 315 | goto argerr; |
| 317 | } | 316 | } |
| 318 | } else if (!strcmp(*args, "-rand")) { | ||
| 319 | if (!args[1]) | ||
| 320 | goto argerr; | ||
| 321 | args++; | ||
| 322 | inrand = *args; | ||
| 323 | } | 317 | } |
| 324 | #ifndef OPENSSL_NO_ENGINE | 318 | #ifndef OPENSSL_NO_ENGINE |
| 325 | else if (!strcmp(*args, "-engine")) { | 319 | else if (!strcmp(*args, "-engine")) { |
| @@ -553,9 +547,6 @@ argerr: | |||
| 553 | BIO_printf(bio_err, "-engine e use engine e, possibly a hardware device.\n"); | 547 | BIO_printf(bio_err, "-engine e use engine e, possibly a hardware device.\n"); |
| 554 | #endif | 548 | #endif |
| 555 | BIO_printf(bio_err, "-passin arg input file pass phrase source\n"); | 549 | BIO_printf(bio_err, "-passin arg input file pass phrase source\n"); |
| 556 | BIO_printf(bio_err, "-rand file:file:...\n"); | ||
| 557 | BIO_printf(bio_err, " load the file (or the files in the directory) into\n"); | ||
| 558 | BIO_printf(bio_err, " the random number generator\n"); | ||
| 559 | BIO_printf(bio_err, "cert.pem recipient certificate(s) for encryption\n"); | 550 | BIO_printf(bio_err, "cert.pem recipient certificate(s) for encryption\n"); |
| 560 | goto end; | 551 | goto end; |
| 561 | } | 552 | } |
diff --git a/src/lib/libssl/src/apps/dgst.c b/src/lib/libssl/src/apps/dgst.c index 23b7d40cc5..a862da9865 100644 --- a/src/lib/libssl/src/apps/dgst.c +++ b/src/lib/libssl/src/apps/dgst.c | |||
| @@ -116,7 +116,7 @@ dgst_main(int argc, char **argv) | |||
| 116 | int debug = 0; | 116 | int debug = 0; |
| 117 | int keyform = FORMAT_PEM; | 117 | int keyform = FORMAT_PEM; |
| 118 | const char *outfile = NULL, *keyfile = NULL; | 118 | const char *outfile = NULL, *keyfile = NULL; |
| 119 | const char *sigfile = NULL, *randfile = NULL; | 119 | const char *sigfile = NULL; |
| 120 | int out_bin = -1, want_pub = 0, do_verify = 0; | 120 | int out_bin = -1, want_pub = 0, do_verify = 0; |
| 121 | EVP_PKEY *sigkey = NULL; | 121 | EVP_PKEY *sigkey = NULL; |
| 122 | unsigned char *sigbuf = NULL; | 122 | unsigned char *sigbuf = NULL; |
| @@ -151,11 +151,7 @@ dgst_main(int argc, char **argv) | |||
| 151 | separator = 1; | 151 | separator = 1; |
| 152 | else if (strcmp(*argv, "-r") == 0) | 152 | else if (strcmp(*argv, "-r") == 0) |
| 153 | separator = 2; | 153 | separator = 2; |
| 154 | else if (strcmp(*argv, "-rand") == 0) { | 154 | else if (strcmp(*argv, "-out") == 0) { |
| 155 | if (--argc < 1) | ||
| 156 | break; | ||
| 157 | randfile = *(++argv); | ||
| 158 | } else if (strcmp(*argv, "-out") == 0) { | ||
| 159 | if (--argc < 1) | 155 | if (--argc < 1) |
| 160 | break; | 156 | break; |
| 161 | outfile = *(++argv); | 157 | outfile = *(++argv); |
diff --git a/src/lib/libssl/src/apps/dhparam.c b/src/lib/libssl/src/apps/dhparam.c index 3245e69d75..c35f902b54 100644 --- a/src/lib/libssl/src/apps/dhparam.c +++ b/src/lib/libssl/src/apps/dhparam.c | |||
| @@ -159,7 +159,6 @@ dhparam_main(int argc, char **argv) | |||
| 159 | BIO *in = NULL, *out = NULL; | 159 | BIO *in = NULL, *out = NULL; |
| 160 | int informat, outformat, check = 0, noout = 0, C = 0, ret = 1; | 160 | int informat, outformat, check = 0, noout = 0, C = 0, ret = 1; |
| 161 | char *infile, *outfile, *prog; | 161 | char *infile, *outfile, *prog; |
| 162 | char *inrand = NULL; | ||
| 163 | #ifndef OPENSSL_NO_ENGINE | 162 | #ifndef OPENSSL_NO_ENGINE |
| 164 | char *engine = NULL; | 163 | char *engine = NULL; |
| 165 | #endif | 164 | #endif |
| @@ -217,11 +216,7 @@ dhparam_main(int argc, char **argv) | |||
| 217 | g = 2; | 216 | g = 2; |
| 218 | else if (strcmp(*argv, "-5") == 0) | 217 | else if (strcmp(*argv, "-5") == 0) |
| 219 | g = 5; | 218 | g = 5; |
| 220 | else if (strcmp(*argv, "-rand") == 0) { | 219 | else if (((sscanf(*argv, "%d", &num) == 0) || (num <= 0))) |
| 221 | if (--argc < 1) | ||
| 222 | goto bad; | ||
| 223 | inrand = *(++argv); | ||
| 224 | } else if (((sscanf(*argv, "%d", &num) == 0) || (num <= 0))) | ||
| 225 | goto bad; | 220 | goto bad; |
| 226 | argv++; | 221 | argv++; |
| 227 | argc--; | 222 | argc--; |
| @@ -247,9 +242,6 @@ bad: | |||
| 247 | #ifndef OPENSSL_NO_ENGINE | 242 | #ifndef OPENSSL_NO_ENGINE |
| 248 | BIO_printf(bio_err, " -engine e use engine e, possibly a hardware device.\n"); | 243 | BIO_printf(bio_err, " -engine e use engine e, possibly a hardware device.\n"); |
| 249 | #endif | 244 | #endif |
| 250 | BIO_printf(bio_err, " -rand file:file:...\n"); | ||
| 251 | BIO_printf(bio_err, " - load the file (or the files in the directory) into\n"); | ||
| 252 | BIO_printf(bio_err, " the random number generator\n"); | ||
| 253 | BIO_printf(bio_err, " -noout no output\n"); | 245 | BIO_printf(bio_err, " -noout no output\n"); |
| 254 | goto end; | 246 | goto end; |
| 255 | } | 247 | } |
diff --git a/src/lib/libssl/src/apps/dsaparam.c b/src/lib/libssl/src/apps/dsaparam.c index a4eb5b5dfc..15f022d395 100644 --- a/src/lib/libssl/src/apps/dsaparam.c +++ b/src/lib/libssl/src/apps/dsaparam.c | |||
| @@ -117,7 +117,7 @@ dsaparam_main(int argc, char **argv) | |||
| 117 | int i, badops = 0, text = 0; | 117 | int i, badops = 0, text = 0; |
| 118 | BIO *in = NULL, *out = NULL; | 118 | BIO *in = NULL, *out = NULL; |
| 119 | int informat, outformat, noout = 0, C = 0, ret = 1; | 119 | int informat, outformat, noout = 0, C = 0, ret = 1; |
| 120 | char *infile, *outfile, *prog, *inrand = NULL; | 120 | char *infile, *outfile, *prog; |
| 121 | int numbits = -1, num, genkey = 0; | 121 | int numbits = -1, num, genkey = 0; |
| 122 | #ifndef OPENSSL_NO_ENGINE | 122 | #ifndef OPENSSL_NO_ENGINE |
| 123 | char *engine = NULL; | 123 | char *engine = NULL; |
| @@ -175,10 +175,6 @@ dsaparam_main(int argc, char **argv) | |||
| 175 | C = 1; | 175 | C = 1; |
| 176 | else if (strcmp(*argv, "-genkey") == 0) { | 176 | else if (strcmp(*argv, "-genkey") == 0) { |
| 177 | genkey = 1; | 177 | genkey = 1; |
| 178 | } else if (strcmp(*argv, "-rand") == 0) { | ||
| 179 | if (--argc < 1) | ||
| 180 | goto bad; | ||
| 181 | inrand = *(++argv); | ||
| 182 | } else if (strcmp(*argv, "-noout") == 0) | 178 | } else if (strcmp(*argv, "-noout") == 0) |
| 183 | noout = 1; | 179 | noout = 1; |
| 184 | else if (sscanf(*argv, "%d", &num) == 1) { | 180 | else if (sscanf(*argv, "%d", &num) == 1) { |
| @@ -205,7 +201,6 @@ bad: | |||
| 205 | BIO_printf(bio_err, " -C Output C code\n"); | 201 | BIO_printf(bio_err, " -C Output C code\n"); |
| 206 | BIO_printf(bio_err, " -noout no output\n"); | 202 | BIO_printf(bio_err, " -noout no output\n"); |
| 207 | BIO_printf(bio_err, " -genkey generate a DSA key\n"); | 203 | BIO_printf(bio_err, " -genkey generate a DSA key\n"); |
| 208 | BIO_printf(bio_err, " -rand files to use for random number input\n"); | ||
| 209 | #ifndef OPENSSL_NO_ENGINE | 204 | #ifndef OPENSSL_NO_ENGINE |
| 210 | BIO_printf(bio_err, " -engine e use engine e, possibly a hardware device.\n"); | 205 | BIO_printf(bio_err, " -engine e use engine e, possibly a hardware device.\n"); |
| 211 | #endif | 206 | #endif |
diff --git a/src/lib/libssl/src/apps/ecparam.c b/src/lib/libssl/src/apps/ecparam.c index e5c26c3ad0..70824e58de 100644 --- a/src/lib/libssl/src/apps/ecparam.c +++ b/src/lib/libssl/src/apps/ecparam.c | |||
| @@ -107,7 +107,6 @@ | |||
| 107 | * explicit | 107 | * explicit |
| 108 | * -no_seed - if 'explicit' parameters are chosen do not use the seed | 108 | * -no_seed - if 'explicit' parameters are chosen do not use the seed |
| 109 | * -genkey - generate ec key | 109 | * -genkey - generate ec key |
| 110 | * -rand file - files to use for random number input | ||
| 111 | * -engine e - use engine e, possibly a hardware device | 110 | * -engine e - use engine e, possibly a hardware device |
| 112 | */ | 111 | */ |
| 113 | 112 | ||
| @@ -124,7 +123,7 @@ ecparam_main(int argc, char **argv) | |||
| 124 | int new_form = 0; | 123 | int new_form = 0; |
| 125 | int asn1_flag = OPENSSL_EC_NAMED_CURVE; | 124 | int asn1_flag = OPENSSL_EC_NAMED_CURVE; |
| 126 | int new_asn1_flag = 0; | 125 | int new_asn1_flag = 0; |
| 127 | char *curve_name = NULL, *inrand = NULL; | 126 | char *curve_name = NULL; |
| 128 | int list_curves = 0, no_seed = 0, check = 0, badops = 0, text = 0, | 127 | int list_curves = 0, no_seed = 0, check = 0, badops = 0, text = 0, |
| 129 | i, genkey = 0; | 128 | i, genkey = 0; |
| 130 | char *infile = NULL, *outfile = NULL, *prog; | 129 | char *infile = NULL, *outfile = NULL, *prog; |
| @@ -204,10 +203,6 @@ ecparam_main(int argc, char **argv) | |||
| 204 | noout = 1; | 203 | noout = 1; |
| 205 | else if (strcmp(*argv, "-genkey") == 0) { | 204 | else if (strcmp(*argv, "-genkey") == 0) { |
| 206 | genkey = 1; | 205 | genkey = 1; |
| 207 | } else if (strcmp(*argv, "-rand") == 0) { | ||
| 208 | if (--argc < 1) | ||
| 209 | goto bad; | ||
| 210 | inrand = *(++argv); | ||
| 211 | } else if (strcmp(*argv, "-engine") == 0) { | 206 | } else if (strcmp(*argv, "-engine") == 0) { |
| 212 | if (--argc < 1) | 207 | if (--argc < 1) |
| 213 | goto bad; | 208 | goto bad; |
| @@ -266,8 +261,6 @@ bad: | |||
| 266 | " use the seed\n"); | 261 | " use the seed\n"); |
| 267 | BIO_printf(bio_err, " -genkey generate ec" | 262 | BIO_printf(bio_err, " -genkey generate ec" |
| 268 | " key\n"); | 263 | " key\n"); |
| 269 | BIO_printf(bio_err, " -rand file files to use for" | ||
| 270 | " random number input\n"); | ||
| 271 | BIO_printf(bio_err, " -engine e use engine e, " | 264 | BIO_printf(bio_err, " -engine e use engine e, " |
| 272 | "possibly a hardware device\n"); | 265 | "possibly a hardware device\n"); |
| 273 | goto end; | 266 | goto end; |
diff --git a/src/lib/libssl/src/apps/gendh.c b/src/lib/libssl/src/apps/gendh.c index 53b09985f7..337529dcff 100644 --- a/src/lib/libssl/src/apps/gendh.c +++ b/src/lib/libssl/src/apps/gendh.c | |||
| @@ -97,7 +97,6 @@ gendh_main(int argc, char **argv) | |||
| 97 | int ret = 1, num = DEFBITS; | 97 | int ret = 1, num = DEFBITS; |
| 98 | int g = 2; | 98 | int g = 2; |
| 99 | char *outfile = NULL; | 99 | char *outfile = NULL; |
| 100 | char *inrand = NULL; | ||
| 101 | #ifndef OPENSSL_NO_ENGINE | 100 | #ifndef OPENSSL_NO_ENGINE |
| 102 | char *engine = NULL; | 101 | char *engine = NULL; |
| 103 | #endif | 102 | #endif |
| @@ -131,11 +130,7 @@ gendh_main(int argc, char **argv) | |||
| 131 | engine = *(++argv); | 130 | engine = *(++argv); |
| 132 | } | 131 | } |
| 133 | #endif | 132 | #endif |
| 134 | else if (strcmp(*argv, "-rand") == 0) { | 133 | else |
| 135 | if (--argc < 1) | ||
| 136 | goto bad; | ||
| 137 | inrand = *(++argv); | ||
| 138 | } else | ||
| 139 | break; | 134 | break; |
| 140 | argv++; | 135 | argv++; |
| 141 | argc--; | 136 | argc--; |
| @@ -153,9 +148,6 @@ bad: | |||
| 153 | #ifndef OPENSSL_NO_ENGINE | 148 | #ifndef OPENSSL_NO_ENGINE |
| 154 | BIO_printf(bio_err, " -engine e - use engine e, possibly a hardware device.\n"); | 149 | BIO_printf(bio_err, " -engine e - use engine e, possibly a hardware device.\n"); |
| 155 | #endif | 150 | #endif |
| 156 | BIO_printf(bio_err, " -rand file:file:...\n"); | ||
| 157 | BIO_printf(bio_err, " - load the file (or the files in the directory) into\n"); | ||
| 158 | BIO_printf(bio_err, " the random number generator\n"); | ||
| 159 | goto end; | 151 | goto end; |
| 160 | } | 152 | } |
| 161 | #ifndef OPENSSL_NO_ENGINE | 153 | #ifndef OPENSSL_NO_ENGINE |
diff --git a/src/lib/libssl/src/apps/gendsa.c b/src/lib/libssl/src/apps/gendsa.c index 86e03ed882..14576c71a4 100644 --- a/src/lib/libssl/src/apps/gendsa.c +++ b/src/lib/libssl/src/apps/gendsa.c | |||
| @@ -85,7 +85,7 @@ gendsa_main(int argc, char **argv) | |||
| 85 | DSA *dsa = NULL; | 85 | DSA *dsa = NULL; |
| 86 | int ret = 1; | 86 | int ret = 1; |
| 87 | char *outfile = NULL; | 87 | char *outfile = NULL; |
| 88 | char *inrand = NULL, *dsaparams = NULL; | 88 | char *dsaparams = NULL; |
| 89 | char *passargout = NULL, *passout = NULL; | 89 | char *passargout = NULL, *passout = NULL; |
| 90 | BIO *out = NULL, *in = NULL; | 90 | BIO *out = NULL, *in = NULL; |
| 91 | const EVP_CIPHER *enc = NULL; | 91 | const EVP_CIPHER *enc = NULL; |
| @@ -117,11 +117,7 @@ gendsa_main(int argc, char **argv) | |||
| 117 | engine = *(++argv); | 117 | engine = *(++argv); |
| 118 | } | 118 | } |
| 119 | #endif | 119 | #endif |
| 120 | else if (strcmp(*argv, "-rand") == 0) { | 120 | else if (strcmp(*argv, "-") == 0) |
| 121 | if (--argc < 1) | ||
| 122 | goto bad; | ||
| 123 | inrand = *(++argv); | ||
| 124 | } else if (strcmp(*argv, "-") == 0) | ||
| 125 | goto bad; | 121 | goto bad; |
| 126 | #ifndef OPENSSL_NO_DES | 122 | #ifndef OPENSSL_NO_DES |
| 127 | else if (strcmp(*argv, "-des") == 0) | 123 | else if (strcmp(*argv, "-des") == 0) |
| @@ -179,9 +175,6 @@ bad: | |||
| 179 | #ifndef OPENSSL_NO_ENGINE | 175 | #ifndef OPENSSL_NO_ENGINE |
| 180 | BIO_printf(bio_err, " -engine e - use engine e, possibly a hardware device.\n"); | 176 | BIO_printf(bio_err, " -engine e - use engine e, possibly a hardware device.\n"); |
| 181 | #endif | 177 | #endif |
| 182 | BIO_printf(bio_err, " -rand file:file:...\n"); | ||
| 183 | BIO_printf(bio_err, " - load the file (or the files in the directory) into\n"); | ||
| 184 | BIO_printf(bio_err, " the random number generator\n"); | ||
| 185 | BIO_printf(bio_err, " dsaparam-file\n"); | 178 | BIO_printf(bio_err, " dsaparam-file\n"); |
| 186 | BIO_printf(bio_err, " - a DSA parameter file as generated by the dsaparam command\n"); | 179 | BIO_printf(bio_err, " - a DSA parameter file as generated by the dsaparam command\n"); |
| 187 | goto end; | 180 | goto end; |
diff --git a/src/lib/libssl/src/apps/genrsa.c b/src/lib/libssl/src/apps/genrsa.c index 300b4b0da2..9481dc4218 100644 --- a/src/lib/libssl/src/apps/genrsa.c +++ b/src/lib/libssl/src/apps/genrsa.c | |||
| @@ -106,7 +106,6 @@ genrsa_main(int argc, char **argv) | |||
| 106 | #ifndef OPENSSL_NO_ENGINE | 106 | #ifndef OPENSSL_NO_ENGINE |
| 107 | char *engine = NULL; | 107 | char *engine = NULL; |
| 108 | #endif | 108 | #endif |
| 109 | char *inrand = NULL; | ||
| 110 | BIO *out = NULL; | 109 | BIO *out = NULL; |
| 111 | BIGNUM *bn = BN_new(); | 110 | BIGNUM *bn = BN_new(); |
| 112 | RSA *rsa = NULL; | 111 | RSA *rsa = NULL; |
| @@ -143,11 +142,6 @@ genrsa_main(int argc, char **argv) | |||
| 143 | engine = *(++argv); | 142 | engine = *(++argv); |
| 144 | } | 143 | } |
| 145 | #endif | 144 | #endif |
| 146 | else if (strcmp(*argv, "-rand") == 0) { | ||
| 147 | if (--argc < 1) | ||
| 148 | goto bad; | ||
| 149 | inrand = *(++argv); | ||
| 150 | } | ||
| 151 | #ifndef OPENSSL_NO_DES | 145 | #ifndef OPENSSL_NO_DES |
| 152 | else if (strcmp(*argv, "-des") == 0) | 146 | else if (strcmp(*argv, "-des") == 0) |
| 153 | enc = EVP_des_cbc(); | 147 | enc = EVP_des_cbc(); |
| @@ -206,9 +200,6 @@ bad: | |||
| 206 | #ifndef OPENSSL_NO_ENGINE | 200 | #ifndef OPENSSL_NO_ENGINE |
| 207 | BIO_printf(bio_err, " -engine e use engine e, possibly a hardware device.\n"); | 201 | BIO_printf(bio_err, " -engine e use engine e, possibly a hardware device.\n"); |
| 208 | #endif | 202 | #endif |
| 209 | BIO_printf(bio_err, " -rand file:file:...\n"); | ||
| 210 | BIO_printf(bio_err, " load the file (or the files in the directory) into\n"); | ||
| 211 | BIO_printf(bio_err, " the random number generator\n"); | ||
| 212 | goto err; | 203 | goto err; |
| 213 | } | 204 | } |
| 214 | ERR_load_crypto_strings(); | 205 | ERR_load_crypto_strings(); |
diff --git a/src/lib/libssl/src/apps/pkcs12.c b/src/lib/libssl/src/apps/pkcs12.c index f2f1e05544..45cf59cdf3 100644 --- a/src/lib/libssl/src/apps/pkcs12.c +++ b/src/lib/libssl/src/apps/pkcs12.c | |||
| @@ -124,7 +124,6 @@ pkcs12_main(int argc, char **argv) | |||
| 124 | char *cpass = NULL, *mpass = NULL; | 124 | char *cpass = NULL, *mpass = NULL; |
| 125 | char *passargin = NULL, *passargout = NULL, *passarg = NULL; | 125 | char *passargin = NULL, *passargout = NULL, *passarg = NULL; |
| 126 | char *passin = NULL, *passout = NULL; | 126 | char *passin = NULL, *passout = NULL; |
| 127 | char *inrand = NULL; | ||
| 128 | char *macalg = NULL; | 127 | char *macalg = NULL; |
| 129 | char *CApath = NULL, *CAfile = NULL; | 128 | char *CApath = NULL, *CAfile = NULL; |
| 130 | #ifndef OPENSSL_NO_ENGINE | 129 | #ifndef OPENSSL_NO_ENGINE |
| @@ -214,12 +213,6 @@ pkcs12_main(int argc, char **argv) | |||
| 214 | } else if (!strcmp(*args, "-keypbe")) { | 213 | } else if (!strcmp(*args, "-keypbe")) { |
| 215 | if (!set_pbe(bio_err, &key_pbe, *++args)) | 214 | if (!set_pbe(bio_err, &key_pbe, *++args)) |
| 216 | badarg = 1; | 215 | badarg = 1; |
| 217 | } else if (!strcmp(*args, "-rand")) { | ||
| 218 | if (args[1]) { | ||
| 219 | args++; | ||
| 220 | inrand = *args; | ||
| 221 | } else | ||
| 222 | badarg = 1; | ||
| 223 | } else if (!strcmp(*args, "-inkey")) { | 216 | } else if (!strcmp(*args, "-inkey")) { |
| 224 | if (args[1]) { | 217 | if (args[1]) { |
| 225 | args++; | 218 | args++; |
| @@ -364,9 +357,6 @@ pkcs12_main(int argc, char **argv) | |||
| 364 | #ifndef OPENSSL_NO_ENGINE | 357 | #ifndef OPENSSL_NO_ENGINE |
| 365 | BIO_printf(bio_err, "-engine e use engine e, possibly a hardware device.\n"); | 358 | BIO_printf(bio_err, "-engine e use engine e, possibly a hardware device.\n"); |
| 366 | #endif | 359 | #endif |
| 367 | BIO_printf(bio_err, "-rand file:file:...\n"); | ||
| 368 | BIO_printf(bio_err, " load the file (or the files in the directory) into\n"); | ||
| 369 | BIO_printf(bio_err, " the random number generator\n"); | ||
| 370 | BIO_printf(bio_err, "-CSP name Microsoft CSP name\n"); | 360 | BIO_printf(bio_err, "-CSP name Microsoft CSP name\n"); |
| 371 | BIO_printf(bio_err, "-LMK Add local machine keyset attribute to private key\n"); | 361 | BIO_printf(bio_err, "-LMK Add local machine keyset attribute to private key\n"); |
| 372 | goto end; | 362 | goto end; |
diff --git a/src/lib/libssl/src/apps/rand.c b/src/lib/libssl/src/apps/rand.c index 8606e0a40b..422dcef744 100644 --- a/src/lib/libssl/src/apps/rand.c +++ b/src/lib/libssl/src/apps/rand.c | |||
| @@ -64,7 +64,6 @@ | |||
| 64 | #include <openssl/rand.h> | 64 | #include <openssl/rand.h> |
| 65 | 65 | ||
| 66 | /* -out file - write to file | 66 | /* -out file - write to file |
| 67 | * -rand file:file - PRNG seed files | ||
| 68 | * -base64 - base64 encode output | 67 | * -base64 - base64 encode output |
| 69 | * -hex - hex encode output | 68 | * -hex - hex encode output |
| 70 | * num - write 'num' bytes | 69 | * num - write 'num' bytes |
| @@ -78,7 +77,6 @@ rand_main(int argc, char **argv) | |||
| 78 | int i, r, ret = 1; | 77 | int i, r, ret = 1; |
| 79 | int badopt; | 78 | int badopt; |
| 80 | char *outfile = NULL; | 79 | char *outfile = NULL; |
| 81 | char *inrand = NULL; | ||
| 82 | int base64 = 0; | 80 | int base64 = 0; |
| 83 | int hex = 0; | 81 | int hex = 0; |
| 84 | BIO *out = NULL; | 82 | BIO *out = NULL; |
| @@ -107,12 +105,7 @@ rand_main(int argc, char **argv) | |||
| 107 | badopt = 1; | 105 | badopt = 1; |
| 108 | } | 106 | } |
| 109 | #endif | 107 | #endif |
| 110 | else if (strcmp(argv[i], "-rand") == 0) { | 108 | else if (strcmp(argv[i], "-base64") == 0) { |
| 111 | if ((argv[i + 1] != NULL) && (inrand == NULL)) | ||
| 112 | inrand = argv[++i]; | ||
| 113 | else | ||
| 114 | badopt = 1; | ||
| 115 | } else if (strcmp(argv[i], "-base64") == 0) { | ||
| 116 | if (!base64) | 109 | if (!base64) |
| 117 | base64 = 1; | 110 | base64 = 1; |
| 118 | else | 111 | else |
| @@ -146,7 +139,6 @@ rand_main(int argc, char **argv) | |||
| 146 | #ifndef OPENSSL_NO_ENGINE | 139 | #ifndef OPENSSL_NO_ENGINE |
| 147 | BIO_printf(bio_err, "-engine e - use engine e, possibly a hardware device.\n"); | 140 | BIO_printf(bio_err, "-engine e - use engine e, possibly a hardware device.\n"); |
| 148 | #endif | 141 | #endif |
| 149 | BIO_printf(bio_err, "-rand file:file:... - seed PRNG from files\n"); | ||
| 150 | BIO_printf(bio_err, "-base64 - base64 encode output\n"); | 142 | BIO_printf(bio_err, "-base64 - base64 encode output\n"); |
| 151 | BIO_printf(bio_err, "-hex - hex encode output\n"); | 143 | BIO_printf(bio_err, "-hex - hex encode output\n"); |
| 152 | goto err; | 144 | goto err; |
diff --git a/src/lib/libssl/src/apps/req.c b/src/lib/libssl/src/apps/req.c index 855f11256f..2e9154be16 100644 --- a/src/lib/libssl/src/apps/req.c +++ b/src/lib/libssl/src/apps/req.c | |||
| @@ -115,7 +115,6 @@ | |||
| 115 | * -config file - Load configuration file. | 115 | * -config file - Load configuration file. |
| 116 | * -key file - make a request using key in file (or use it for verification). | 116 | * -key file - make a request using key in file (or use it for verification). |
| 117 | * -keyform arg - key file format. | 117 | * -keyform arg - key file format. |
| 118 | * -rand file(s) - load the file(s) into the PRNG. | ||
| 119 | * -newkey - make a key and a request. | 118 | * -newkey - make a key and a request. |
| 120 | * -modulus - print RSA modulus. | 119 | * -modulus - print RSA modulus. |
| 121 | * -pubkey - output Public Key. | 120 | * -pubkey - output Public Key. |
| @@ -179,7 +178,6 @@ req_main(int argc, char **argv) | |||
| 179 | const EVP_CIPHER *cipher = NULL; | 178 | const EVP_CIPHER *cipher = NULL; |
| 180 | ASN1_INTEGER *serial = NULL; | 179 | ASN1_INTEGER *serial = NULL; |
| 181 | int modulus = 0; | 180 | int modulus = 0; |
| 182 | char *inrand = NULL; | ||
| 183 | char *passargin = NULL, *passargout = NULL; | 181 | char *passargin = NULL, *passargout = NULL; |
| 184 | char *passin = NULL, *passout = NULL; | 182 | char *passin = NULL, *passout = NULL; |
| 185 | char *p; | 183 | char *p; |
| @@ -262,10 +260,6 @@ req_main(int argc, char **argv) | |||
| 262 | if (--argc < 1) | 260 | if (--argc < 1) |
| 263 | goto bad; | 261 | goto bad; |
| 264 | passargout = *(++argv); | 262 | passargout = *(++argv); |
| 265 | } else if (strcmp(*argv, "-rand") == 0) { | ||
| 266 | if (--argc < 1) | ||
| 267 | goto bad; | ||
| 268 | inrand = *(++argv); | ||
| 269 | } else if (strcmp(*argv, "-newkey") == 0) { | 263 | } else if (strcmp(*argv, "-newkey") == 0) { |
| 270 | if (--argc < 1) | 264 | if (--argc < 1) |
| 271 | goto bad; | 265 | goto bad; |
| @@ -381,9 +375,6 @@ bad: | |||
| 381 | BIO_printf(bio_err, " -key file use the private key contained in file\n"); | 375 | BIO_printf(bio_err, " -key file use the private key contained in file\n"); |
| 382 | BIO_printf(bio_err, " -keyform arg key file format\n"); | 376 | BIO_printf(bio_err, " -keyform arg key file format\n"); |
| 383 | BIO_printf(bio_err, " -keyout arg file to send the key to\n"); | 377 | BIO_printf(bio_err, " -keyout arg file to send the key to\n"); |
| 384 | BIO_printf(bio_err, " -rand file:file:...\n"); | ||
| 385 | BIO_printf(bio_err, " load the file (or the files in the directory) into\n"); | ||
| 386 | BIO_printf(bio_err, " the random number generator\n"); | ||
| 387 | BIO_printf(bio_err, " -newkey rsa:bits generate a new RSA key of 'bits' in size\n"); | 378 | BIO_printf(bio_err, " -newkey rsa:bits generate a new RSA key of 'bits' in size\n"); |
| 388 | BIO_printf(bio_err, " -newkey dsa:file generate a new DSA key, parameters taken from CA in 'file'\n"); | 379 | BIO_printf(bio_err, " -newkey dsa:file generate a new DSA key, parameters taken from CA in 'file'\n"); |
| 389 | #ifndef OPENSSL_NO_ECDSA | 380 | #ifndef OPENSSL_NO_ECDSA |
diff --git a/src/lib/libssl/src/apps/s_client.c b/src/lib/libssl/src/apps/s_client.c index 0720dc9f2b..33e4d2a542 100644 --- a/src/lib/libssl/src/apps/s_client.c +++ b/src/lib/libssl/src/apps/s_client.c | |||
| @@ -316,7 +316,6 @@ sc_usage(void) | |||
| 316 | #ifndef OPENSSL_NO_ENGINE | 316 | #ifndef OPENSSL_NO_ENGINE |
| 317 | BIO_printf(bio_err, " -engine id - Initialise and use the specified engine\n"); | 317 | BIO_printf(bio_err, " -engine id - Initialise and use the specified engine\n"); |
| 318 | #endif | 318 | #endif |
| 319 | BIO_printf(bio_err, " -rand file:file:...\n"); | ||
| 320 | BIO_printf(bio_err, " -sess_out arg - file to write SSL session to\n"); | 319 | BIO_printf(bio_err, " -sess_out arg - file to write SSL session to\n"); |
| 321 | BIO_printf(bio_err, " -sess_in arg - file to read SSL session from\n"); | 320 | BIO_printf(bio_err, " -sess_in arg - file to read SSL session from\n"); |
| 322 | #ifndef OPENSSL_NO_TLSEXT | 321 | #ifndef OPENSSL_NO_TLSEXT |
| @@ -437,7 +436,6 @@ s_client_main(int argc, char **argv) | |||
| 437 | const SSL_METHOD *meth = NULL; | 436 | const SSL_METHOD *meth = NULL; |
| 438 | int socket_type = SOCK_STREAM; | 437 | int socket_type = SOCK_STREAM; |
| 439 | BIO *sbio; | 438 | BIO *sbio; |
| 440 | char *inrand = NULL; | ||
| 441 | int mbuf_len = 0; | 439 | int mbuf_len = 0; |
| 442 | struct timeval timeout, *timeoutp; | 440 | struct timeval timeout, *timeoutp; |
| 443 | #ifndef OPENSSL_NO_ENGINE | 441 | #ifndef OPENSSL_NO_ENGINE |
| @@ -692,11 +690,7 @@ s_client_main(int argc, char **argv) | |||
| 692 | ssl_client_engine_id = *(++argv); | 690 | ssl_client_engine_id = *(++argv); |
| 693 | } | 691 | } |
| 694 | #endif | 692 | #endif |
| 695 | else if (strcmp(*argv, "-rand") == 0) { | 693 | else if (strcmp(*argv, "-4") == 0) { |
| 696 | if (--argc < 1) | ||
| 697 | goto bad; | ||
| 698 | inrand = *(++argv); | ||
| 699 | } else if (strcmp(*argv, "-4") == 0) { | ||
| 700 | af = AF_INET; | 694 | af = AF_INET; |
| 701 | } else if (strcmp(*argv, "-6") == 0) { | 695 | } else if (strcmp(*argv, "-6") == 0) { |
| 702 | af = AF_INET6; | 696 | af = AF_INET6; |
diff --git a/src/lib/libssl/src/apps/s_server.c b/src/lib/libssl/src/apps/s_server.c index 450f98c7bc..77384ec201 100644 --- a/src/lib/libssl/src/apps/s_server.c +++ b/src/lib/libssl/src/apps/s_server.c | |||
| @@ -455,7 +455,6 @@ sv_usage(void) | |||
| 455 | BIO_printf(bio_err, " -engine id - Initialise and use the specified engine\n"); | 455 | BIO_printf(bio_err, " -engine id - Initialise and use the specified engine\n"); |
| 456 | #endif | 456 | #endif |
| 457 | BIO_printf(bio_err, " -id_prefix arg - Generate SSL/TLS session IDs prefixed by 'arg'\n"); | 457 | BIO_printf(bio_err, " -id_prefix arg - Generate SSL/TLS session IDs prefixed by 'arg'\n"); |
| 458 | BIO_printf(bio_err, " -rand file:file:...\n"); | ||
| 459 | #ifndef OPENSSL_NO_TLSEXT | 458 | #ifndef OPENSSL_NO_TLSEXT |
| 460 | BIO_printf(bio_err, " -servername host - servername for HostName TLS extension\n"); | 459 | BIO_printf(bio_err, " -servername host - servername for HostName TLS extension\n"); |
| 461 | BIO_printf(bio_err, " -servername_fatal - on mismatch send fatal alert (default warning alert)\n"); | 460 | BIO_printf(bio_err, " -servername_fatal - on mismatch send fatal alert (default warning alert)\n"); |
| @@ -696,7 +695,6 @@ s_server_main(int argc, char *argv[]) | |||
| 696 | const SSL_METHOD *meth = NULL; | 695 | const SSL_METHOD *meth = NULL; |
| 697 | int socket_type = SOCK_STREAM; | 696 | int socket_type = SOCK_STREAM; |
| 698 | ENGINE *e = NULL; | 697 | ENGINE *e = NULL; |
| 699 | char *inrand = NULL; | ||
| 700 | int s_cert_format = FORMAT_PEM, s_key_format = FORMAT_PEM; | 698 | int s_cert_format = FORMAT_PEM, s_key_format = FORMAT_PEM; |
| 701 | char *passarg = NULL, *pass = NULL; | 699 | char *passarg = NULL, *pass = NULL; |
| 702 | char *dpassarg = NULL, *dpass = NULL; | 700 | char *dpassarg = NULL, *dpass = NULL; |
| @@ -969,11 +967,6 @@ s_server_main(int argc, char *argv[]) | |||
| 969 | engine_id = *(++argv); | 967 | engine_id = *(++argv); |
| 970 | } | 968 | } |
| 971 | #endif | 969 | #endif |
| 972 | else if (strcmp(*argv, "-rand") == 0) { | ||
| 973 | if (--argc < 1) | ||
| 974 | goto bad; | ||
| 975 | inrand = *(++argv); | ||
| 976 | } | ||
| 977 | #ifndef OPENSSL_NO_TLSEXT | 970 | #ifndef OPENSSL_NO_TLSEXT |
| 978 | else if (strcmp(*argv, "-servername") == 0) { | 971 | else if (strcmp(*argv, "-servername") == 0) { |
| 979 | if (--argc < 1) | 972 | if (--argc < 1) |
diff --git a/src/lib/libssl/src/apps/smime.c b/src/lib/libssl/src/apps/smime.c index fe5d0f597d..3c3fa9d4be 100644 --- a/src/lib/libssl/src/apps/smime.c +++ b/src/lib/libssl/src/apps/smime.c | |||
| @@ -108,7 +108,6 @@ smime_main(int argc, char **argv) | |||
| 108 | char *to = NULL, *from = NULL, *subject = NULL; | 108 | char *to = NULL, *from = NULL, *subject = NULL; |
| 109 | char *CAfile = NULL, *CApath = NULL; | 109 | char *CAfile = NULL, *CApath = NULL; |
| 110 | char *passargin = NULL, *passin = NULL; | 110 | char *passargin = NULL, *passin = NULL; |
| 111 | char *inrand = NULL; | ||
| 112 | int indef = 0; | 111 | int indef = 0; |
| 113 | const EVP_MD *sign_md = NULL; | 112 | const EVP_MD *sign_md = NULL; |
| 114 | int informat = FORMAT_SMIME, outformat = FORMAT_SMIME; | 113 | int informat = FORMAT_SMIME, outformat = FORMAT_SMIME; |
| @@ -198,12 +197,6 @@ smime_main(int argc, char **argv) | |||
| 198 | flags |= PKCS7_NOOLDMIMETYPE; | 197 | flags |= PKCS7_NOOLDMIMETYPE; |
| 199 | else if (!strcmp(*args, "-crlfeol")) | 198 | else if (!strcmp(*args, "-crlfeol")) |
| 200 | flags |= PKCS7_CRLFEOL; | 199 | flags |= PKCS7_CRLFEOL; |
| 201 | else if (!strcmp(*args, "-rand")) { | ||
| 202 | if (!args[1]) | ||
| 203 | goto argerr; | ||
| 204 | args++; | ||
| 205 | inrand = *args; | ||
| 206 | } | ||
| 207 | #ifndef OPENSSL_NO_ENGINE | 200 | #ifndef OPENSSL_NO_ENGINE |
| 208 | else if (!strcmp(*args, "-engine")) { | 201 | else if (!strcmp(*args, "-engine")) { |
| 209 | if (!args[1]) | 202 | if (!args[1]) |
| @@ -412,9 +405,6 @@ argerr: | |||
| 412 | BIO_printf(bio_err, "-engine e use engine e, possibly a hardware device.\n"); | 405 | BIO_printf(bio_err, "-engine e use engine e, possibly a hardware device.\n"); |
| 413 | #endif | 406 | #endif |
| 414 | BIO_printf(bio_err, "-passin arg input file pass phrase source\n"); | 407 | BIO_printf(bio_err, "-passin arg input file pass phrase source\n"); |
| 415 | BIO_printf(bio_err, "-rand file:file:...\n"); | ||
| 416 | BIO_printf(bio_err, " load the file (or the files in the directory) into\n"); | ||
| 417 | BIO_printf(bio_err, " the random number generator\n"); | ||
| 418 | BIO_printf(bio_err, "cert.pem recipient certificate(s) for encryption\n"); | 408 | BIO_printf(bio_err, "cert.pem recipient certificate(s) for encryption\n"); |
| 419 | goto end; | 409 | goto end; |
| 420 | } | 410 | } |
diff --git a/src/lib/libssl/src/apps/ts.c b/src/lib/libssl/src/apps/ts.c index df2e179ce0..403e99ba73 100644 --- a/src/lib/libssl/src/apps/ts.c +++ b/src/lib/libssl/src/apps/ts.c | |||
| @@ -133,7 +133,6 @@ ts_main(int argc, char **argv) | |||
| 133 | char *data = NULL; | 133 | char *data = NULL; |
| 134 | char *digest = NULL; | 134 | char *digest = NULL; |
| 135 | const EVP_MD *md = NULL; | 135 | const EVP_MD *md = NULL; |
| 136 | char *rnd = NULL; | ||
| 137 | char *policy = NULL; | 136 | char *policy = NULL; |
| 138 | int no_nonce = 0; | 137 | int no_nonce = 0; |
| 139 | int cert = 0; | 138 | int cert = 0; |
| @@ -181,10 +180,6 @@ ts_main(int argc, char **argv) | |||
| 181 | if (argc-- < 1) | 180 | if (argc-- < 1) |
| 182 | goto usage; | 181 | goto usage; |
| 183 | digest = *++argv; | 182 | digest = *++argv; |
| 184 | } else if (strcmp(*argv, "-rand") == 0) { | ||
| 185 | if (argc-- < 1) | ||
| 186 | goto usage; | ||
| 187 | rnd = *++argv; | ||
| 188 | } else if (strcmp(*argv, "-policy") == 0) { | 183 | } else if (strcmp(*argv, "-policy") == 0) { |
| 189 | if (argc-- < 1) | 184 | if (argc-- < 1) |
| 190 | goto usage; | 185 | goto usage; |
| @@ -315,7 +310,7 @@ ts_main(int argc, char **argv) | |||
| 315 | 310 | ||
| 316 | usage: | 311 | usage: |
| 317 | BIO_printf(bio_err, "usage:\n" | 312 | BIO_printf(bio_err, "usage:\n" |
| 318 | "ts -query [-rand file:file:...] [-config configfile] " | 313 | "ts -query [-config configfile] " |
| 319 | "[-data file_to_hash] [-digest digest_bytes]" | 314 | "[-data file_to_hash] [-digest digest_bytes]" |
| 320 | "[-md2|-md4|-md5|-sha|-sha1|-mdc2|-ripemd160] " | 315 | "[-md2|-md4|-md5|-sha|-sha1|-mdc2|-ripemd160] " |
| 321 | "[-policy object_id] [-no_nonce] [-cert] " | 316 | "[-policy object_id] [-no_nonce] [-cert] " |
