Skip to content

[Security] fix #39249, default entry_point compiler pass was returning too early #39261

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
Dec 1, 2020

Conversation

romaricdrigon
Copy link
Contributor

@romaricdrigon romaricdrigon commented Dec 1, 2020

Q A
Branch? 5.2 (bug introduced in 5.2.0, after RC2)
Bug fix? yes
New feature? no
Deprecations? no
Tickets Fix #39249
License MIT
Doc PR N/A

A return instead of continue was making compiler pass return after the first firewall. Hence subsequents firewalls never had a default entrypoint set.
This issue would occur with all firewalls, with any type of authenticator, though I saw it first with http_basic - because it is a bit more opaque and harder to debug.

@romaricdrigon romaricdrigon changed the base branch from 5.x to 5.2 December 1, 2020 08:51
Copy link
Member

@wouterj wouterj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for report & debugging this issue! And sorry for introducing it 😔

@romaricdrigon
Copy link
Contributor Author

You are welcome, with as many contributions you do that's fair :)

There's another issue in 5.2.0 security, I'm working an issue and a patch on it, to come in a few minutes too.

@chalasr
Copy link
Member

chalasr commented Dec 1, 2020

Good catch, thanks @romaricdrigon.

@chalasr chalasr merged commit 0b48115 into symfony:5.2 Dec 1, 2020
@romaricdrigon romaricdrigon deleted the fix-39249 branch December 1, 2020 09:46
@fabpot fabpot mentioned this pull request Dec 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Security][5.2.0 only bug] Default entry_point selection does not work for 2nd firewall
4 participants