1

Starting apache httpd prompts for a passphrase string text like below

$ echo -n "mypassword" | /web/apps/perf/apache/2.4.46/https-model/bin/apachectl -k start
Apache/2.4.46 mod_ssl (Pass Phrase Dialog)
Some of your private key files are encrypted for security reasons.
In order to read them you have to provide the pass phrases.

Private key model.com:443:0 (/web/apps/perf/apache/2.4.46/https-model/ssl/model.key)
Enter pass phrase:

I tried the below options to pass the password non-intractively but none of them work.

  1. echo -n "mypassword" | /web/apps/perf/apache/2.4.46/https-model/bin/apachectl -k start
  2. echo "mypassword" >> /web/apps/perf/apache/2.4.46/https-model/bin/apachectl -k start
  3. /web/apps/perf/apache/2.4.46/https-model/bin/apachectl -k start << echo "mypassword"
  4. /web/apps/perf/apache/2.4.46/https-model/bin/apachectl -k start << cat mypasswordfile (where mypasswordfile is a file having the password.)

Can you please suggest?

Ashar
  • 2,942
  • 10
  • 58
  • 122
  • The passphrase is there to protect the keys. If you store the passphrase on disk, in order to not enter it manually, you might as well store the keys unprotected. – Olaf Kock Aug 16 '21 at 13:12
  • The passphrase will be in ansible vault. What is the issue with that @OlafKock? – Ashar Aug 16 '21 at 14:14

0 Answers0