How To: Resetting Your Password in WordPress

Sometimes we get so caught up in covering the complex WordPress hacks and offering tips, that we forget to cover many of the things that are often taken for granted.

Today I decided to write a quick post and cover how to reset your password within the WordPress dashboard (for WordPress 2.0+):

  1. Go to the Users tab.
  2. Click on the Your Profile link.
  3. Scroll down to the bottom of the page and enter your desired password in the New Password field.
  4. Click the Update Profile button.

That’s it!  If you are using an older version of WordPress, you’ll want to consult the WordPress Codex.

If you can’t get into your dashboard, you can also reset your password from PHPMyAdmin (only recommended for comfortable advanced users):

  1. Select the WordPress database of the blog you want to reset the password on.
  2. Click on wp_users.
  3. Click the “browse” icon (or “structure”).
  4. Click browse in the user_login field.
  5. Locate the ID number associated with your login and commit it to memory.
  6. Click browse in the user_pass field and find your login.
  7. Click edit.
  8. Delete the numbers and letters next to the ID number.
  9. Enter your desired password (case sensitive).
  10. Select MD5 in the drop-down menu.
  11. Click Go.
  12. Verify your new password works!

If you are not the administrator, you can always contact the administrator to reset your password as well.  Good luck!

Is Your WordPress Site Hackable?

This guest post was written by Hayes Potter, who is a 13 year old programmer and web developer that gives webmasters tips on protecting their website from common hacking techniques. If you have webmaster or WordPress knowledge and are interested in writing a post for Hack WordPress, please contact us.

Today I want to ask all the web masters out there “Is your site hackable?”. I’m a test hacker, and I’ve seen some very popular sites get hacked in some of the simplest ways. Hacking wordpress is actually quite easy if you know what your doing. Two words my friend, “SQL Injections”, most people bypass this thought when they make a blog. Even know wordpress login forms prevent SQL Injections but what about form making plugins? Always check to see if your site is hackable through SQL Injections, for more information on simple hacking with SQL Injection visit my post about it by clicking here.

Also if you have a “robots.txt” file in your home directory, keep in mind that disallowing search engines doesn’t disallow people! Never leave directories with password’s in them, even if it is encrypted. If you have to password protect the director and/or password file. Also always keep your cgi-bin password protected because a lot of file management systems use it to keep passwords that you use. I know some cPanel file management systems do. So always check your site for rogue password files and SQL Injection prevention.

Editor’s Note: If you aren’t very familiar with some of this terminology, your best bet is to always keep your WordPress blogs upgraded to the latest version of WordPress.

Learning More About Javascript Injections

Ok, for those of you who don’t know what javascript injections are, they are ways to manipulate the page source of any web page. Some very simple javascript injections are to simply display an alert box with any text you want. To execute any form of javascript injection enter “javascript:” in the URL bar in your browser, then after the colon you can enter any javascript code in the same way you would in a normal web page. For example if you type in “javascript:var a = “hello world!”; alert(a)” in the URL bar an alert box would pop-up displaying the value of the variable “a”.

Now that you know the basics to javascript injections lets learn how to hack with them, as you should know javascript can manipulate anything on a web page. Here is a simple way to hack into a username on a website. Although the site you try to hack you have to be logged into that site. Once logged in type in the following javascript injection in the URL bar: “javascript:alert(document.cookie)”. This will display the cookie information that the site has on you, look for something like “user_id=xxx” or “PHPSESSID=xxx”. Typically you want to change this string’s value to 1, because the administrator is usually user_id number 1. To change it type in the following in the URL bar: “javascript:void(document.cookie user_id=1);alert(document.cookie);”. Now the user_id’s value should be 1, so refresh the page and you should be logged in as the administrator.

Please remember that you should never mess around with someones site. Always contact the administrator if you find a security hole in their site. Now remember how I said javascript can manipulate anything on a webpage? Well lets start manipulating stuff, for the basics we can just start with forms. Lets say a web page has a form to buy something using a debit card or something like that. Lets say the price for this item is fifty dollars, now lets manipulate this price. Lets say the submit button is a form itself, and it has no other values. In the URL bar type the following: “javascript:void(document.forms[0] = $1.00)”. Ultimately this will change price to one dollar, yes! The “[0]” represents the form number on the page, for example if there are 3 forms on a page. The first one would be labeled “0″ the second one “1″ and the third one “2″.