Right now Gatekeeper does no password policy enforcement, it just uses the password as is. The ability should be added, maybe as a callback somehow, to define a set of rules on the value provided by the user.
Possible implementation:
<?php
Gatekeeper::setPasswordPolicy(function($password) {
if (strlen($password) < 8) {
throw new \Exception('Invalid password length!');
}
});
?>
This would need to be appended to the UserModel somehow so it could be triggered on user create.
Right now Gatekeeper does no password policy enforcement, it just uses the password as is. The ability should be added, maybe as a callback somehow, to define a set of rules on the value provided by the user.
Possible implementation:
This would need to be appended to the
UserModel
somehow so it could be triggered on user create.