8000 Update access_control.rst role · symfony/symfony-docs@b4f4ceb · GitHub
[go: up one dir, main page]

Skip to content

Commit b4f4ceb

Browse files
authored
Update access_control.rst role
I think that there is an error about the second rule's `role` value. It should be `ROLE_USER_PORT` instead of `ROLE_USER_IP`. Correct me if I'm wrong!
1 parent 7af99d4 commit b4f4ceb

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

security/access_control.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ Take the following ``access_control`` entries as an example:
4141
# ...
4242
access_control:
4343
- { path: ^/admin, roles: ROLE_USER_IP, ip: 127.0.0.1 }
44-
- { path: ^/admin, roles: ROLE_USER_IP, ip: 127.0.0.1, port: 8080 }
44+
- { path: ^/admin, roles: ROLE_USER_PORT, ip: 127.0.0.1, port: 8080 }
4545
- { path: ^/admin, roles: ROLE_USER_HOST, host: symfony\.com$ }
4646
- { path: ^/admin, roles: ROLE_USER_METHOD, methods: [POST, PUT] }
4747
- { path: ^/admin, roles: ROLE_USER }
@@ -59,7 +59,7 @@ Take the following ``access_control`` entries as an example:
5959
<config>
6060
<!-- ... -->
6161
<rule path="^/admin" role="ROLE_USER_IP" ip="127.0.0.1" />
62-
<rule path="^/admin" role="ROLE_USER_IP" ip="127.0.0.1" port="8080" />
62+
<rule path="^/admin" role="ROLE_USER_PORT" ip="127.0.0.1" port="8080" />
6363
<rule path="^/admin" role="ROLE_USER_HOST" host="symfony\.com$" />
6464
<rule path="^/admin" role="ROLE_USER_METHOD" methods="POST, PUT" />
6565
<rule path="^/admin" role="ROLE_USER" />
@@ -79,7 +79,7 @@ Take the following ``access_control`` entries as an example:
7979
],
8080
[
8181
'path' => '^/admin',
82-
'role' => 'ROLE_USER_IP',
82+
'role' => 'ROLE_USER_PORT',
8383
'ip' => '127.0.0.1',
8484
'port' => '8080',
8585
),

0 commit comments

Comments
 (0)
0