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

[Security] Rename firewalls’ pattern to path #31496

Open
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
4 participants
@MatTheCat
Copy link
Contributor

commented May 14, 2019

Q A
Branch? master
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? yes
Tests pass? yes
Fixed tickets N/A
License MIT
Doc PR maybe symfony/symfony-docs#11574

The same way pattern has been replaced by path in the routing component (cf. #5989) consistency would be better if the security component did the same.

@linaori

This comment has been minimized.

Copy link
Contributor

commented May 14, 2019

The difference is that the path in a route is an actual path and the pattern in the firewall is a regular expression. I'm not sure this will improve DX, possibly even hurt DX because developers might not know that it allows more than a static path.

I'm 👎 on this change for that reason as pattern is accurate here.

@MatTheCat

This comment has been minimized.

Copy link
Contributor Author

commented May 14, 2019

developers might not know that it allows more than a static path

It is the same for host. Maybe path_pattern/host_pattern then?

@MatTheCat

This comment has been minimized.

Copy link
Contributor Author

commented May 14, 2019

That being said access controls also use path for a pattern. So the firewall is the only place where an option matching a path is not named path.

DX would come from consistency here.

@MatTheCat MatTheCat force-pushed the MatTheCat:deprecate_firewall_pattern branch from 09e95cd to 2e38cc6 May 15, 2019

@nicolas-grekas nicolas-grekas added this to the next milestone May 20, 2019

@MatTheCat MatTheCat force-pushed the MatTheCat:deprecate_firewall_pattern branch from 2e38cc6 to f1f4c83 May 26, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.