WordPress.org

Ready to get started?Download WordPress

Forums

Encrypt DB_PASSWORD in wp-config.php (3 posts)

  1. csasser
    Member
    Posted 1 year ago #

    I had to change my database connection in WordPress today. Everything is working fine but I had to change the DB password in wp-config.php with a new password. My concern is that the previous password appeared to be encrypted in the wp-config.php.

    How do I get this encrypted again? I reran setup-config.php but this still left the password not encrypted. The old secret keys are in the wp-config.php file. Not sure if this is related.

    /** MySQL database password */
    define('DB_PASSWORD', 'mypassword');

  2. Andrew Bartel
    Member
    Posted 1 year ago #

    It probably wasn't encrypted, just a good password, long with lots of random characters. The only way someone's going to gain access to it is if they have access to your source code, in which case you're in a lot bigger trouble than them just messing with your database.

  3. csasser
    Member
    Posted 1 year ago #

    I went back to my previous backup of wp-config.php and the password was as follows in the file. This is not the password I setup in cPanel for the sql database user for the WordPress database so I am still puzzled.

    /** MySQL database password */
    define('DB_PASSWORD', 'e3wuU99nuq3TW5Gc');

Topic Closed

This topic has been closed to new replies.

About this Topic