Skip to content

Commit 1ecbb32

Browse files
committed
update upgrade files with CSRF related option info
1 parent 422430e commit 1ecbb32

File tree

2 files changed

+39
-17
lines changed

2 files changed

+39
-17
lines changed

UPGRADE-2.8.md

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,12 @@ All components
1818
Form
1919
----
2020

21+
* The `intention` option was deprecated and will be removed in 3.0 in favor
22+
of the new `csrf_token_id` option.
23+
24+
* The `csrf_provider` option was deprecated and will be removed in 3.0 in favor
25+
of the new `csrf_token_generator` option.
26+
2127
* The "cascade_validation" option was deprecated. Use the "constraints"
2228
option together with the `Valid` constraint instead. Contrary to
2329
"cascade_validation", "constraints" must be set on the respective child forms,
@@ -203,7 +209,7 @@ Form
203209
* In Symfony 2.7 a small BC break was introduced with the new choices_as_values
204210
option. In order to have the choice values populated to the html value attribute
205211
you had to define the choice_value option. This is now not any more needed.
206-
212+
207213
Before:
208214

209215
```php
@@ -221,9 +227,9 @@ Form
221227
},
222228
));
223229
```
224-
230+
225231
After (Symfony 2.8+):
226-
232+
227233
```php
228234
$form->add('status', ChoiceType::class, array(
229235
'choices' => array(
@@ -262,13 +268,13 @@ Form
262268
}
263269
}
264270
```
265-
271+
266272
* The option "options" of the CollectionType has been renamed to "entry_options".
267273
The usage of the option "options" is deprecated and will be removed in Symfony 3.0.
268274

269275
* The option "type" of the CollectionType has been renamed to "entry_type".
270276
The usage of the option "type" is deprecated and will be removed in Symfony 3.0.
271-
As a value for the option you should provide the fully-qualified class name (FQCN)
277+
As a value for the option you should provide the fully-qualified class name (FQCN)
272278
now as well.
273279

274280
* Passing type instances to `Form::add()`, `FormBuilder::add()` and the
@@ -409,8 +415,8 @@ DependencyInjection
409415
</services>
410416
```
411417

412-
* `Symfony\Component\DependencyInjection\ContainerAware` has been deprecated, use
413-
`Symfony\Component\DependencyInjection\ContainerAwareTrait` or implement
418+
* `Symfony\Component\DependencyInjection\ContainerAware` has been deprecated, use
419+
`Symfony\Component\DependencyInjection\ContainerAwareTrait` or implement
414420
`Symfony\Component\DependencyInjection\ContainerAwareInterface` manually
415421

416422
WebProfiler
@@ -522,12 +528,18 @@ Security
522528
* The `intention` option is deprecated for all the authentication listeners,
523529
and will be removed in 3.0. Use the `csrf_token_id` option instead.
524530

531+
* The `csrf_provider` option is deprecated for all the authentication listeners,
532+
and will be removed in 3.0. Use the `csrf_token_generator` option instead.
533+
525534
SecurityBundle
526535
--------------
527536

528537
* The `intention` firewall listener setting is deprecated, and will be removed in 3.0.
529538
Use the `csrf_token_id` option instead.
530539

540+
* The `csrf_provider` firewall listener setting is deprecated, and will be removed in 3.0.
541+
Use the `csrf_token_generator` option instead.
542+
531543
Config
532544
------
533545

UPGRADE-3.0.md

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -264,12 +264,12 @@ UPGRADE FROM 2.x to 3.0
264264
// ...
265265
}
266266
```
267-
267+
268268
* The option "options" of the CollectionType has been renamed to "entry_options".
269269

270270
* The option "type" of the CollectionType has been renamed to "entry_type".
271-
As a value for the option you must provide the fully-qualified class name (FQCN)
272-
now as well.
271+
As a value for the option you must provide the fully-qualified class name (FQCN)
272+
now as well.
273273

274274
* The `FormIntegrationTestCase` and `FormPerformanceTestCase` classes were moved form the `Symfony\Component\Form\Tests` namespace to the `Symfony\Component\Form\Test` namespace.
275275

@@ -317,8 +317,8 @@ UPGRADE FROM 2.x to 3.0
317317

318318
* The `Symfony\Component\Form\Extension\Core\ChoiceList\SimpleChoiceList` class has been removed in
319319
favor of `Symfony\Component\Form\ChoiceList\ArrayChoiceList`.
320-
321-
* The `TimezoneType::getTimezones()` method was removed. You should not use
320+
321+
* The `TimezoneType::getTimezones()` method was removed. You should not use
322322
this method.
323323

324324
* The `Symfony\Component\Form\ChoiceList\ArrayKeyChoiceList` class has been removed in
@@ -365,11 +365,11 @@ UPGRADE FROM 2.x to 3.0
365365
}
366366
}
367367
```
368-
368+
369369
* In Symfony 2.7 a small BC break was introduced with the new choices_as_values
370370
option. In order to have the choice values populated to the html value attribute
371371
you had to define the choice_value option. This is now not any more needed.
372-
372+
373373
Before:
374374

375375
```php
@@ -389,9 +389,9 @@ UPGRADE FROM 2.x to 3.0
389389
},
390390
));
391391
```
392-
392+
393393
After:
394-
394+
395395
```php
396396
$form->add('status', ChoiceType::class, array(
397397
'choices' => array(
@@ -400,7 +400,7 @@ UPGRADE FROM 2.x to 3.0
400400
'Ignored' => Status::IGNORED,
401401
)
402402
));
403-
```
403+
```
404404

405405
* The `request` service was removed. You must inject the `request_stack`
406406
service instead.
@@ -774,6 +774,16 @@ UPGRADE FROM 2.x to 3.0
774774
}
775775
```
776776

777+
* The `intention` option was renamed to `csrf_token_id` for all the authentication listeners.
778+
779+
* The `csrf_provider` option was renamed to `csrf_token_generator` for all the authentication listeners.
780+
781+
### SecurityBundle
782+
783+
* The `intention` firewall listener setting was renamed to `csrf_token_id`.
784+
785+
* The `csrf_provider` firewall listener setting was renamed to `csrf_token_generator`.
786+
777787
### Translator
778788

779789
* The `Translator::setFallbackLocale()` method has been removed in favor of

0 commit comments

Comments
 (0)