Bash script for automating cntlm proxy password generation
<p>I want to use the tool cntlm to authenticate via basic authentication against our corporate proxy server, which uses the ntlm protocol.</p>

<p>CNTLM uses a cntlm.conf file to get your proxy authentication credentials.
If you don't want to use your password in plain text, you can generate hashes with the command. (That's what I want!) </p>

<p><code>cntlm -u &lt;user&gt; -d &lt;domain&gt; -f -H</code>. </p>

<p>The problem here is, that we use a rolling password policy here and I want to write a bash script for automating the hash generation, inserting in the config file and restarting the cntlm service.</p>

<p>Unfortunately the above shown command generates the password hashes interactively and I couldn't find a way to wrap this in a bash script.</p>

<p>I am a bash scripting newbie though and could use some advice here ;)</p>