[2.8] Modify 2.8 upgrade doc - key option is deprecated.

This commit is contained in:
Sam Partington 2017-08-08 11:23:31 +01:00 committed by Fabien Potencier
parent 684975ddf3
commit 2309fd91d8
1 changed files with 89 additions and 0 deletions

View File

@ -546,6 +546,95 @@ Security
* The `VoterInterface::supportsClass` and `supportsAttribute` methods were
deprecated and will be removed from the interface in 3.0.
* The the `key` setting of `anonymous`, `remember_me` and `http_digest`
is deprecated, and will be removed in 3.0. Use `secret` instead.
Before:
```yaml
security:
# ...
firewalls:
default:
# ...
anonymous: { key: "%secret%" }
remember_me:
key: "%secret%"
http_digest:
key: "%secret%"
```
```xml
<!-- ... -->
<config>
<!-- ... -->
<firewall>
<!-- ... -->
<anonymous key="%secret%"/>
<remember-me key="%secret%"/>
<http-digest key="%secret%"/>
</firewall>
</config>
```
```php
// ...
$container->loadFromExtension('security', array(
// ...
'firewalls' => array(
// ...
'anonymous' => array('key' => '%secret%'),
'remember_me' => array('key' => '%secret%'),
'http_digest' => array('key' => '%secret%'),
),
));
```
After:
```yaml
security:
# ...
firewalls:
default:
# ...
anonymous: { secret: "%secret%" }
remember_me:
secret: "%secret%"
http_digest:
secret: "%secret%"
```
```xml
<!-- ... -->
<config>
<!-- ... -->
<firewall>
<!-- ... -->
<anonymous secret="%secret%"/>
<remember-me secret="%secret%"/>
<http-digest secret="%secret%"/>
</firewall>
</config>
```
```php
// ...
$container->loadFromExtension('security', array(
// ...
'firewalls' => array(
// ...
'anonymous' => array('secret' => '%secret%'),
'remember_me' => array('secret' => '%secret%'),
'http_digest' => array('secret' => '%secret%'),
),
));
```
* The `intention` option is deprecated for all the authentication listeners,
and will be removed in 3.0. Use the `csrf_token_id` option instead.