Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> -pass is way more convenient: > > pass -c my/password > > is far quicker and several orders of magnitude less annoying than > > gpg -dao passwordfile.gpg > <unlock private key> > <copy password> > <kill terminal> > <use password> > <clear clipboard>

I agree with your sentiment, but if you keep your passwordfile well-formed, say:

    site.com username password
    #assume no spaces in password or username -- or use tabs
You could throw something like:

    gpg -dao passwordfile.gpg|awk "/${1}/ { print \$3 }" | xclip &&
     sleep 15 ; echo XXXXXXXXXXXXXXXXXXXXXXXXXX | xclip
In a script. With an agent managing your gpg passphrase (or not, depending on your pranoia) such a scheme would get most of the way there.

Not sure why you would want to kill the terminal, but you could just <command-run> or whatever said script...

In fact, for clearing your clipboard, just selecting some text should be enough -- but I supppose it might be considered a feature to have it in the script, in case one forgets.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: