title: entering password into openssl command from shell script
body: <p>I am trying to convert a p12 to a pem from a shell script without any user input. 
  I can have the password as a variable within the script.</p>
  
  <p>so when I call:</p>
  
  <pre><code>openssl pkcs12 -in *.p12 -out cert.pem -nodes
  </code></pre>
  
  <p>The terminal prints "Enter Import Password:" and waits for input.</p>
  
  <p>I tried to pipe the password in with:</p>
  
  <pre><code>echo $PASS | openssl pkcs12 -in *.p12 -out cert.pem -nodes
  </code></pre>
  
  <p>as well as trying to use a flag with the openssl command but can't figure out how to do this.</p>