summaryrefslogtreecommitdiffstats
path: root/crypto/openssl/apps/smime.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/openssl/apps/smime.c')
-rw-r--r--crypto/openssl/apps/smime.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/crypto/openssl/apps/smime.c b/crypto/openssl/apps/smime.c
index 250fd69..830f18c 100644
--- a/crypto/openssl/apps/smime.c
+++ b/crypto/openssl/apps/smime.c
@@ -161,6 +161,14 @@ int MAIN(int argc, char **argv)
else if (!strcmp(*args,"-aes256"))
cipher = EVP_aes_256_cbc();
#endif
+#ifndef OPENSSL_NO_CAMELLIA
+ else if (!strcmp(*args,"-camellia128"))
+ cipher = EVP_camellia_128_cbc();
+ else if (!strcmp(*args,"-camellia192"))
+ cipher = EVP_camellia_192_cbc();
+ else if (!strcmp(*args,"-camellia256"))
+ cipher = EVP_camellia_256_cbc();
+#endif
else if (!strcmp (*args, "-text"))
flags |= PKCS7_TEXT;
else if (!strcmp (*args, "-nointern"))
@@ -424,6 +432,10 @@ int MAIN(int argc, char **argv)
BIO_printf (bio_err, "-aes128, -aes192, -aes256\n");
BIO_printf (bio_err, " encrypt PEM output with cbc aes\n");
#endif
+#ifndef OPENSSL_NO_CAMELLIA
+ BIO_printf (bio_err, "-camellia128, -camellia192, -camellia256\n");
+ BIO_printf (bio_err, " encrypt PEM output with cbc camellia\n");
+#endif
BIO_printf (bio_err, "-nointern don't search certificates in message for signer\n");
BIO_printf (bio_err, "-nosigs don't verify message signature\n");
BIO_printf (bio_err, "-noverify don't verify signers certificate\n");
@@ -638,12 +650,6 @@ int MAIN(int argc, char **argv)
if ((flags & PKCS7_DETACHED) && (outformat == FORMAT_SMIME))
flags |= PKCS7_STREAM;
p7 = PKCS7_sign(signer, key, other, in, flags);
- /* Don't need to rewind for partial signing */
- if (!(flags & PKCS7_STREAM) && (BIO_reset(in) != 0))
- {
- BIO_printf(bio_err, "Can't rewind input file\n");
- goto end;
- }
}
else
{
OpenPOWER on IntegriCloud