Skip to content
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

[1.x] Port security fixes to default login rate limiter #473

Merged
merged 1 commit into from
Jun 18, 2023

Conversation

staudenmeir
Copy link
Contributor

This PR ports two security fixes for MySQL/MariaDB from LoginRateLimiter to the service provider's rate limiter (that Fortify uses on a default installation):

  • Protection against bypass attempts with different combinations of uppercase and lowercase characters (e.g. uSer@example.com): This fix has been included in LoginRateLimiter from the beginning but not in the default rate limiter.
  • Protection against bypass attempts with special characters (e.g. uⓢer@example.com): [1.x] Fix Throttle Bypass Exploit #354 fixed this in LoginRateLimiter but not in the default rate limiter.

I replaced $request->email with the more universal $request->input(Fortify::username()) from LoginRateLimiter.

I also removed the string cast from #333 because it doesn't actually solve the issue it wanted to fix (#332). Passing an array still causes an "Array to string conversion" error.

There aren't any tests for the default rate limiter yet and I'm not sure about the bestway to test them.

The big issue with these vulnerabilities is that they don't get fixed in existing apps since the service provider is a stub file, but we can't really do anything about that.

@taylorotwell taylorotwell merged commit 110dd0d into laravel:1.x Jun 18, 2023
@staudenmeir staudenmeir deleted the default-login-rate-limiter branch May 14, 2024 20:33
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