title: Securely passing password to openssl via stdin
body: <p>We know we can encrypt a file with openssl using this command:</p>
  
  <pre><code>openssl aes-256-cbc -a -salt -in twitterpost.txt -out foo.enc -pass stdin
  </code></pre>
  
  <p>The password will be read from stdin. As such, to provide the password beforehand, all we need do is prepend</p>
  
  <pre><code>echo "someGoodPassword" |
  </code></pre>
  
  <p>to the above command. My question is: How can I do this more securely? The above method doesn't look secure enough.</p>
  
  <p>I'd appreciate some comments about this so I can understand this issue better.</p>