Hi Jimmy, Thanks for your response. Kindly find my thoughts inlined..

> Question:
> So, the question is: How can we generate a key for Triple DES encryption a=

> write out the same in a file?

Simple answer for 'how to generate a key for a symmetric cipher' is 'use
a pseudo-random generator' to generate key/IV pairs of desired length.

--- This will be sufficient for my case. Is there a way to generate the same=
from the command line,
or we have to generate in a program using "DES_random_key". I could not fin=
d a way to do from the
command line.

How to write out to a file? Simple answer: base64, or raw binary, or etc..

Have you considered if PKCS12 or PEM would suite your application's needs?

--- PEM will suit well.

> I tried the genrsa and dsa options but they seem to generate keys for
> RSA/DSA encryptions. Also, we can specify the length of modulus in those
> keys. But they will not map well in T-Des case.

Don't know how rsa/dsa can help with DES

--- Yes, right. I agree.

This e-mail may contain privileged and confidential information which is the=
property of Persistent Systems Ltd. It is intended only for the use of the=
individual or entity to which it is addressed. If you are not the intended=
recipient, you are not authorized to read, retain, copy, print, distribute=
or use this message. If you have received this communication in error, plea=
se notify the sender and delete all copies of this message. Persistent Syste=
ms Ltd. does not accept any liability for virus infected mails.
__________________________________________________ ____________________
OpenSSL Project http://www.openssl.org
User Support Mailing List openssl-users@openssl.org
Automated List Manager majordomo@openssl.org