This extension allows your users to continue to login with their passwords from a previous platform that was using a different hashing algorithm than Flarum.
Installation
composer require migratetoflarum/old-passwords
Updating
composer update migratetoflarum/old-passwords
php flarum migrate
php flarum cache:clear
Documentation
This extension is meant to be used alongside a migration script. There are no settings accessible from the UI (you still need to keep the extension enabled for it to work !)
The migrations add a migratetoflarum_old_password
column to your users
table, which can contain old credentials hashed with different algorithms than bcrypt.
This column must contain a valid JSON-serialized object as described below or null
to not provide an old password.
Once a user was correctly identified via an old password, the password is re-hashed with bcrypt, stored in Flarum password
field and the migratetoflarum_old_password
column is set to null
.
If you somehow manage to have both a bcrypt-hashed password
and migratetoflarum_old_password
value in the database for a user, then the user will be able to login with either password. The password used will override the value of password
and migratetoflarum_old_password
will be set to null
.
Compatible hashings
Check the README on GitHub for an up-to-date list of the options available https://github.com/migratetoflarum/old-passwords
A MigrateToFlarum extension
This is a free extension by MigrateToFlarum, an online forum migration tool (launching soon).
Follow us on Twitter for updates https://twitter.com/MigrateToFlarum
Need a custom Flarum extension ? Contact Clark Winkelmann !
Links