How to read the user login password by python script?
<p>I have written the python script for switch off/on the monitor at a particular time using following command in my .py file.</p>

<pre><code>passwd='Mypassword'    
subprocess.call('echo %s|sudo -S vbetool dpms on' % passwd, shell=True)
</code></pre>

<p>it works properly, but here i need to defined my password manually, but i need the system to automatically retrieve the password. </p>

<p>Is there any options available for the same, please let me know.</p>
