July 2008 Archives
Tue Jul 22 21:40:42 IST 2008
SPG - Simple Password Generator
I have been using unique passwords for (almost) all the websites I have accounts on, and have a handy script to do the task for me. The idea is simple and came from a comment on a blog post. You just need to remember one secret passphrase. Every time you need a unique password, append that secret to a unique string identifying the use (the website URL, or the domain name), hash the result and use the first n characters of it as the password. Unique, and there's only one thing to remember.
The script is useful enough, and I'm finally getting around to releasing it. There are other password generators (like Crypt::RandPasswd, Data::SimplePassword, String::MkPasswd, Text::Password::Pronounceable, Crypt::PassGen etc.), but they focus on creating random passwords - leaving it upon the user to manage and remember them.
This might be useful as a firefox extension as well. I eventually plan to convert it to one, but if someone else wants to do it, or has already done so - even better. It's a very simple idea, and I'm sure it can be implemented purely in chrome/javascript.
I need a place to announce it and I will let this be that place.
The script is useful enough, and I'm finally getting around to releasing it. There are other password generators (like Crypt::RandPasswd, Data::SimplePassword, String::MkPasswd, Text::Password::Pronounceable, Crypt::PassGen etc.), but they focus on creating random passwords - leaving it upon the user to manage and remember them.
This might be useful as a firefox extension as well. I eventually plan to convert it to one, but if someone else wants to do it, or has already done so - even better. It's a very simple idea, and I'm sure it can be implemented purely in chrome/javascript.
I need a place to announce it and I will let this be that place.
Sat Jul 12 12:52:53 IST 2008
Gutsy to Hardy - upgrade hiccups
So I decided to upgrade to Hardy after doing a Wubi install on a couple of machines. With some gotchas of course.
I couldn't login. Not even as root. It wouldn't even ask for a password, but straightaway said "login failed" (on the console) and "authentication failed" (gdm).
That seemed like a PAM problem and it was. My encrypted HOME setup uses pam_encfs which had a problem loading into PAM.
The fix : a recompile, but after the patch mentioned in this bug.
Also, my network profiles stopped working - which turned out to be because of sudo. Adding a 'env_keep=NETSCHEME' to the Defaults in sudoers fix that too.
Sat Jul 5 12:20:17 IST 2008
Location aware GTD trick
I have my gtdo to manage the TODOs, and it shows me the list every time I open a terminal (via a 't ls' in my .bashrc). But what to do when my '@work' TODO list grows long and is shown to me on every terminal spawn, even at home?
what I also have is my network profiles setup. Till today, my office profile was called "office" - which I changed to "work". This makes my profile name the same as my context name ('work' and '@work' - we can manage the @ in the context). Do I need to say more? :)
Every time I do a 'NETSCHEME="work" sudo ifup ath0' and the network comes up, the '/var/run/network/ifstate' contains a line like 'ath0=ath0-home'. Which means, I can get the profile I'm using. Which means, if I name my profiles carefully, I can get the location I'm at. Which then means, if I name my contexts carefully, I can get the relevant context.
Adding this:
By the way, I *could* scan for known SSIDs and select a network (and hence a location and a context) automagically, but I don't do that yet - one of the reasons being that I *think* there might be an information leak hidden somewhere. But I haven't thought it through. But I might, and then I might get around to doing it.
what I also have is my network profiles setup. Till today, my office profile was called "office" - which I changed to "work". This makes my profile name the same as my context name ('work' and '@work' - we can manage the @ in the context). Do I need to say more? :)
Every time I do a 'NETSCHEME="work" sudo ifup ath0' and the network comes up, the '/var/run/network/ifstate' contains a line like 'ath0=ath0-home'. Which means, I can get the profile I'm using. Which means, if I name my profiles carefully, I can get the location I'm at. Which then means, if I name my contexts carefully, I can get the relevant context.
Adding this:
LOCATION=`grep -m 1 '-' /var/run/network/ifstate | awk -F '-' '{ print $2 }'`
t ls @$LOCATION
to my .bashrc works like magic.By the way, I *could* scan for known SSIDs and select a network (and hence a location and a context) automagically, but I don't do that yet - one of the reasons being that I *think* there might be an information leak hidden somewhere. But I haven't thought it through. But I might, and then I might get around to doing it.