sruupl / batflat

Lightweight, fast and easy CMS for free. Bootstrap ready. https://batflat.org
MIT License
134 stars 54 forks source link

Password Reset #23

Closed volomike closed 6 years ago

volomike commented 6 years ago

It's bound to happen. You might want to explain how to do a password reset if you're a superadmin. For instance, on WordPress, you copy a reset script into a certain directory and run it, and then you can login and change the main WordPress password.

What I ended up doing was installing a separate install, grabbing the password, and updating the SQLite table on the other install, in order to reset the password.

michu2k commented 6 years ago

Exacly. You need to copy the password from a sepereate install and update the SQLite table.

klocus commented 6 years ago

You can copy a password hash form /inc/modules/users/users.info.php :)

$2y$10$pgRnDiukCbiYVqsamMM3ROWViSRqbyCCL33N8.ykBKZx0dlplXe9i

You have to paste it in column "password", table "users". It's "admin" password.

bsquare20 commented 3 years ago

Hello

i'm unable to reset admin password. please let me know the step by step process to reset the password.

michu2k commented 3 years ago

Hi @bsquare20

NOTE: Before making any changes to the database, make sure you have a copy of the database

  1. Download the DB browser https://sqlitebrowser.org/
  2. Open your database file with this program. path (inc/data/databse.sdb)
  3. Find the user in the users table and in the password column replace the password hash with this one: $2y$10$pgRnDiukCbiYVqsamMM3ROWViSRqbyCCL33N8.ykBKZx0dlplXe9i and save changes ofc
  4. Now you can log in with your username and admin password