Skip to content

Commit d52f3f8

Browse files
committed
feature #3454 [Security] Add host option (ghostika)
This PR was merged into the 2.4 branch. Discussion ---------- [Security] Add host option | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | 2.4+ | Fixed tickets | #3453 Host option is missing from documentation and this feature was introduced in 2.4 for the firewall. Commits ------- 6cba192 remove versionadded from book and fix words 3e42b84 Add versionadded tag to security config reference, reference cookbok entry in book cc8d19a line break 0244173 add host to the config page 4fb6e59 Add host config to the security documentation
2 parents 5ba2227 + 6cba192 commit d52f3f8

File tree

3 files changed

+9
-2
lines changed

3 files changed

+9
-2
lines changed

Diff for: book/security.rst

+2-1
Original file line numberDiff line numberDiff line change
@@ -1098,7 +1098,7 @@ Thanks to the SensioFrameworkExtraBundle, you can also secure your controller us
10981098
// ...
10991099
}
11001100

1101-
For more information, see the
1101+
For more information, see the
11021102
:doc:`FrameworkExtraBundle documentation </bundles/SensioFrameworkExtraBundle/annotations/security>`.
11031103

11041104
Securing other Services
@@ -2164,6 +2164,7 @@ Learn more from the Cookbook
21642164
* :doc:`Blacklist users by IP address with a custom voter </cookbook/security/voters>`
21652165
* :doc:`Access Control Lists (ACLs) </cookbook/security/acl>`
21662166
* :doc:`/cookbook/security/remember_me`
2167+
* :doc:`How to Restrict Firewalls to a Specific Host </cookbook/security/host_restriction>`
21672168

21682169
.. _`FOSUserBundle`: https://github.com./FriendsOfSymfony/FOSUserBundle
21692170
.. _`implement the \Serializable interface`: http://php.net/manual/en/class.serializable.php

Diff for: cookbook/security/host_restriction.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ How to Restrict Firewalls to a Specific Host
55
============================================
66

77
.. versionadded:: 2.4
8-
Support for restricting security firewalls to a specific host was added in
8+
Support for restricting security firewalls to a specific host was introduced in
99
Symfony 2.4.
1010

1111
When using the Security component, you can create firewalls that match certain

Diff for: reference/configuration/security.rst

+6
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ Full Default Configuration
1313
The following is the full default configuration for the security system.
1414
Each part will be explained in the next section.
1515

16+
.. versionadded:: 2.4
17+
Support for restricting security firewalls to a specific host was introduced in
18+
Symfony 2.4.
19+
1620
.. configuration-block::
1721

1822
.. code-block:: yaml
@@ -98,6 +102,8 @@ Each part will be explained in the next section.
98102
# Examples:
99103
somename:
100104
pattern: .*
105+
# restrict the firewall to a specific host
106+
host: admin\.example\.com
101107
request_matcher: some.service.id
102108
access_denied_url: /foo/error403
103109
access_denied_handler: some.service.id

0 commit comments

Comments
 (0)