WordPress: Resetting your password the “hard” way.

November 19th, 2008

more yarnings

If you’ve forgetten your password to your WordPress install it has a nifty email-a-one-time-key-to-retrieve-password flow built in. Which for some reason never works on my box. (probably has to do with how I have Postfix setup doing 2ndary MXing) In the olden days the solution to this problem was to connect your database and UPDATE the user_pass field with an MD5 of your desired new password.

But now we’re living in the future, so things are more complicated. I still connect to my database, and manually UPDATE users set user_pass=$hashed where ID=1, but now I need this handy script to generate the hashed password for me. Hopefully the 3 other people in the world this is useful for will find this blog post.

(And now I might start blogging again)

Photo from sarabbit

2 responses to “WordPress: Resetting your password the “hard” way.”

  1. Tim Bailen says:

    Yep. In fact, according to documentation on WordPress’s site (http://codex.wordpress.org/ResettingYourPassword), newer versions of MySQL can do the MD5 hashing for you.

  2. Kellan says:

    Tim, that wiki is out of date. You used to be able to do it that, but not with the current version of WP.