Security application
<p>i am developing a password storage software. To enter into the application we have to login with valid details.</p>

<p>Now when i press home key, the application should log of automatically and then start all over again from security perspective. It should logout everytime the home key is pressed.
How do i do it?</p>
