Reset Pam_Tally2

To unlock a locked account, you need to run pam_tally2, which is a tool that keeps tracked of failed logins. Pam_tally2 is installed on most Linux systems. To unlock an account, just run the following commands:

pam_tally2 --user=ulysses --reset

Have the user login again. It should work.

Free SSL Certificates

I picked up a free SSL certificate from SSLForFree.com. It’s good for 90 days. Not a bad deal. Wished it was longer. Without further ado, the site is now running on https! Check out the secure lock next to my domain! I’ve added a redirect to force visitors to use https instead. It’s a good exercise on how to convert any site from http to https. I learned how to configure Apache and how to use certificates. Anyways, plan to do them for my other websites.

Random Salt

Occasionally, I’m asked to provide a random list of characters that will be used as a salt for hashing a password or some data of some sort. The primary function of salts are to create a random one-way function typically used to fight against dictionary or rainbow table attacks. Here’s a neat command that you can generate from the Bash shell. It will generate a 32 random character string.

$ tr -c -d '0123456789abcdefghijklmnopqrstuvwxyz' </dev/urandom | dd bs=32 count=1 2>/dev/null;echo

The result is: ynhgunq3ppnirhhp3vxpmvdw5b2uuc2f