Skip to content

[6.0] Remove new password validation from broker #29480

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 9, 2019
Merged

[6.0] Remove new password validation from broker #29480

merged 1 commit into from
Aug 9, 2019

Conversation

driesvints
Copy link
Member

@driesvints driesvints commented Aug 9, 2019

These changes remove all hardcoded validation for a new password from the PasswordBroker. The reason for this is because this is a hardcoded constraint in validation and thus limits people from building password reset forms with their specific flow. The validation is already done within the ResetsPassword trait and is only duplicated in the Broker. The Broker also seems like the wrong place to do this as it only facilitates the retrieval of the user and the token validation (which is still the correct place for these two).

This also allows us to remove the https://github.com/laravel/laravel/blob/develop/resources/lang/en/passwords.php#L16 language line.

This basically doesn't contain any breaking changes for people's apps other than the api changes and if people were already overriding this behavior. Existing apps with the default Auth scaffolding will continue to work as-is.

See #25957 (comment)

These changes remove all hardcoded valdation from the PasswordBroker. The reason for this is because this is a hardcoded constraint in validation and thus limits people from building password reset forms with their specific flow. The validation is already done within the ResetsPassword trait and is only duplicated in the Broker. The Broker also seems like the wrong place to do this as it only facilitates the retrieval of the user and the token validation (which is still the correct place for these two).

This also allows us to remove the https://github.com/laravel/laravel/blob/develop/resources/lang/en/passwords.php#L16 language line.

See #25957 (comment)
@taylorotwell taylorotwell merged commit 6ea47d6 into laravel:master Aug 9, 2019
@driesvints driesvints deleted the remove-password-broker-validation branch August 9, 2019 14:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants