Skip to content

Conversation

pdewit
Copy link
Contributor

@pdewit pdewit commented Sep 16, 2025

I saw that a can function was added to the $allowedAttributes array in PR #54648 but this did not actually work for route groups. This has the potential for security issues in applications that assume can works because it's in the allowedAttributes array when it actually doesn't, which for untested endpoints means you could potentially access unauthorized routes. This change adds it to the route middleware when assigning it to the route actions, which makes it work.

The test failed before this PR but works after the changes.

@taylorotwell taylorotwell merged commit 0aff8d8 into laravel:12.x Sep 17, 2025
65 checks passed
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