Hi everyone,
Having some trouble with openssl
smime...
Goal: To use openssl to create smime messages so
that I can send encrypted email to people from the command line with aid of
sendmail or something similar.
Problem: I'm getting errors using openssl smime and
I don't know why. Below is a description of what I have
done.
The Details
=============
Get certificates in appropriate format; convert
.p7b file to .pem file using openssl
--------------------------------------------------------------------------------------------------------------------
I have certificates for people in outlook
express. Using that tool I can send them encrypted emails. I
exported their certificates into the .p7b format (pkcs7). To use openssl it seems PEM is the preferred format so I
converted the certs from .p7b to .pem via the following command:
$ openssl pkcs7 -in LiamWalker.p7b -inform DER -out
LiamWalker.pem -outform PEM
This generated the appropriate output files so I
assume they are ok. openssl pkcs7 with -print_certs was able to read these
files.
Attempted to produce a email message in SMIME
format:
-----------------------------------------------------------------------------------
I then was experimenting with with the openssl
smime command to try and generate a properly formatted file to myself from
myself. Later I would use sendmail or somethign to actually deliver
the message. I used the following command:
$ openssl smime -encrypt -des3 -nointern -nosigs
-noverify -recip LiamWalker.pem -in msg.txt -out
msg.enc -to "[EMAIL PROTECTED]" -from "[EMAIL PROTECTED]" -subject "Test using
openssl" LiamWalker.pem
The output for this command was as follows:
Loading 'screen' into random state - done unable to load certificate 360:error:0906D06C:PEM routines:PEM_read_bio:no start line:.\crypto\pem\pem_lib. c:662:Expecting: TRUSTED CERTIFICATE Can't read recipient certificate file ./LiamWalker.pem The -to email address matches the email
address in the certificate specified by -recip and the -from email address
matches the email address in the last option (LiamWalker.pem).
Can anyone give me a hint as to what is going on
here?
Thanks,
.maiL
P.S. I assume that you use multiple -to and
-recip options to have the message encrypted to multiple
people?
|
- Re: Error using openssl smime Liam Walker
- Re: Error using openssl smime Dr S N Henson