Under Windows you can use WriteConsole to specify the passphrase but it is a
little intricate program (create a process, create a console, inherit the
console, redirect standard input...) and I don't know if there are
equivalent solution for other systems.
Nicolas Roumiantzeff.
>Norberto Silva wrote:
>>
>> Hi,
>>
>> I am in the process of trying to automate the generation of RSA private
>> keys using openssl genrsa.
>> In particular, I am trying to redirect user input via a temporary file
>> containing the pass phrase (and , of course,
>> a confirming pass phrase on the next line). In other words I have a file
>> phrase.inp with the first two lines
>> containing (pass phrase is "secret"):
>>
>> secret
>> secret
>>
>> Then I want to automate the generation of the rsa key via the command
>>
>> openssl genrsa -des3 -out myKey.key 1024 < phrase.inp
>>
>> The problem I encounter is that genrsa is still prompting the user
>> rather than taking the contents of
>> phrase.inp as input. Is there anyway around this?
>>
______________________________________________________________________
OpenSSL Project http://www.openssl.org
User Support Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]