Commit Graph

18257 Commits

Author SHA1 Message Date
Bernhard Schussek
5feda5e9a6 [Intl] Removed non-working $fallback argument from ArrayAccessibleResourceBundle 2014-09-11 18:28:58 +02:00
Fabien Potencier
b33d6377df bug #11497 Use separated function to resolve command and related arguments (JJK801)
This PR was submitted for the master branch but it was merged into the 2.3 branch instead (closes #11497).

Discussion
----------

Use separated function to resolve command and related arguments

Hi,

This PR split command and related arguments resolution into two distinct functions.

It will help to solve the HHVM issue sensiolabs/SensioDistributionBundle#150 .

Thanks,

Jérémy

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | yes
| BC breaks?    | yes
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | ~
| License       | MIT
| Doc PR        | ~

Commits
-------

ee75af0 Use separated function to resolve command and related arguments
2014-09-11 18:27:13 +02:00
Jérémy JOURDIN
ee75af0c89 Use separated function to resolve command and related arguments 2014-09-11 18:27:13 +02:00
Daniel Beyer
a5e3fc9e8a [SwiftmailerBridge] Bump allowed versions of swiftmailer
Current version of Swiftmailer is 5.2.1, while (previously to this commit)
the version installed by composer was 5.0.3.

This is rather important, since 5.2.1 closes a security issue that 5.0.3 is
vulnarable to (https://github.com/swiftmailer/swiftmailer/issues/494).
2014-09-10 18:06:23 +02:00
Fabien Potencier
a45e3da3e4 minor #11822 [Security] Use hash_equals for constant-time string comparison (again) (dunglas)
This PR was merged into the 2.3 branch.

Discussion
----------

[Security] Use hash_equals for constant-time string comparison (again)

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Use the `hash_equals` function (introduced in PHP 5.6) for timing attack safe string comparison when available.

Add in the DocBlock that length will leak (https://github.com/symfony/symfony/pull/11797#issuecomment-53990712).

Commits
-------

3071557 [Security] Add more tests for StringUtils::equals
03bd74b [Security] Use hash_equals for constant-time string comparison
2014-09-10 15:18:42 +02:00
Fabien Potencier
e86fe91d70 feature #11549 [Bundle][FrameworkBundle] make the stopwatch service always available (xabbuh)
This PR was merged into the 2.6-dev branch.

Discussion
----------

[Bundle][FrameworkBundle] make the stopwatch service always available

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #11347
| License       | MIT
| Doc PR        |

Previously, one had to be careful to check if the ``debug.stopwatch`` service was available before using it. Otherwise, the application would break in the prod environment.

Commits
-------

ffc4090 make the stopwatch service always available
2014-09-10 15:16:43 +02:00
Fabien Potencier
d4e056c877 bug #11374 [DI] Added safeguards against invalid config in the YamlFileLoader (stof)
This PR was merged into the 2.3 branch.

Discussion
----------

[DI] Added safeguards against invalid config in the YamlFileLoader

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #11333
| License       | MIT
| Doc PR        | n/a

Exceptions explaining the mistake are better than fatal errors or weird notices appearing when trying to deal with such invalid data.

The XML file loader is not affected by this because the data are validated with the XSD before being processed

Commits
-------

5183501 [DI] Added safeguards against invalid config in the YamlFileLoader
2014-09-10 15:14:47 +02:00
Fabien Potencier
aa16baf2d4 bug #11897 [FrameworkBundle] Remove invalid markup (flack)
This PR was submitted for the 2.5 branch but it was merged into the 2.3 branch instead (closes #11897).

Discussion
----------

[FrameworkBundle] Remove invalid markup

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #11896
| License       | MIT
| Doc PR        | n/a

Commits
-------

1fe8e31 [FrameworkBundle] Remove invalid markup
2014-09-10 15:06:13 +02:00
flack
1fe8e31514 [FrameworkBundle] Remove invalid markup 2014-09-10 15:06:13 +02:00
Fabien Potencier
f5b4b115ba minor #11891 [Intl] Added "internal" tag to all classes under Symfony\Component\Intl\ResourceBundle (webmozart)
This PR was merged into the 2.3 branch.

Discussion
----------

[Intl] Added "internal" tag to all classes under Symfony\Component\Intl\ResourceBundle

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | yes?
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

We didn't have this tag yet when this component was first written. The code in that
namespace is only used for resource bundle generation and was never meant for public
use.

We need to include in the update notes that users should check for usage of these classes.

Commits
-------

7fd5e8b [Intl] Added "internal" tag to all classes under Symfony\Component\Intl\ResourceBundle
2014-09-09 16:58:14 +02:00
Bernhard Schussek
7fd5e8b201 [Intl] Added "internal" tag to all classes under Symfony\Component\Intl\ResourceBundle
We didn't have this tag yet when this component was first written. The code in that
namespace is only used for resource bundle generation and was never meant for public
use.
2014-09-09 16:20:39 +02:00
Fabien Potencier
900ca18539 feature #11869 #11652 [HttpKernel] Remove unused method Kernel::isClassInActiveBundle (hacfi)
This PR was squashed before being merged into the 2.6-dev branch (closes #11869).

Discussion
----------

#11652 [HttpKernel] Remove unused method Kernel::isClassInActiveBundle

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | yes, deprecation targets 3.0
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | #11652
| License       | MIT
| Doc PR        | - (Not mentioned in the docs)

Commits
-------

a777fd7 #11652 [HttpKernel] Remove unused method Kernel::isClassInActiveBundle
2014-09-08 21:56:38 +02:00
Philipp Wahala
a777fd78e5 #11652 [HttpKernel] Remove unused method Kernel::isClassInActiveBundle 2014-09-08 21:56:26 +02:00
Fabien Potencier
5764482af6 feature #11869 #11652 [HttpKernel] Remove unused method Kernel::isClassInActiveBundle (hacfi)
This PR was squashed before being merged into the 2.6-dev branch (closes #11869).

Discussion
----------

#11652 [HttpKernel] Remove unused method Kernel::isClassInActiveBundle

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | yes, deprecation targets 3.0
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | #11652
| License       | MIT
| Doc PR        | - (Not mentioned in the docs)

Commits
-------

86873f2 #11652 [HttpKernel] Remove unused method Kernel::isClassInActiveBundle
2014-09-08 21:56:12 +02:00
Philipp Wahala
86873f29f8 #11652 [HttpKernel] Remove unused method Kernel::isClassInActiveBundle 2014-09-08 21:56:05 +02:00
Fabien Potencier
91fb103a70 minor #11844 [FrameworkBundle] improve handling router script paths (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] improve handling router script paths

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

The `server:run` command switches the working directory before starting the built-in web server. Therefore, the path to a custom router script had to be specified based on the document root path and not based on the user's working directory.

Another option is to update the documentation (as started in symfony/symfony-docs#4194). Though I think the current behaviour is a bug. The intended behaviour can be derived from the command's help message:

> ```
If you have custom docroot directory layout, you can specify your own
 router script using --router option:

>   ./app/console server:run --router=app/config/router.php
```

As you can see, the path is specified based on the current working directory.

Commits
-------

0a16cf2 improve handling router script paths
2014-09-08 20:50:54 +02:00
Fabien Potencier
7f56b35fc5 feature #11805 [Monolog] added NotFoundActivationStrategy from MonologBundle (fabpot)
This PR was merged into the 2.6-dev branch.

Discussion
----------

[Monolog] added NotFoundActivationStrategy from MonologBundle

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

The NotFoundActivationStrategy class from MonologBundle is totally independent of the framework and should be part of the bridge instead. That would allow people to use it easily with Silex for instance.

ping @Seldaek

Commits
-------

b064d2f [Monolog] changed the not found activation strategy to use the request stack
1a239af [Monolog] added NotFoundActivationStrategy from MonologBundle
2014-09-08 13:55:02 +02:00
Fabien Potencier
f4c9c976d8 minor #11868 Remove routes for removed WebProfiler actions (Briareos)
This PR was submitted for the master branch but it was merged into the 2.3 branch instead (closes #11868).

Discussion
----------

Remove routes for removed WebProfiler actions

The import/export functionality was moved to commands in f38536ab79, but the routes were not removed.

Commits
-------

1421449 Remove routes for removed WebProfiler actions
2014-09-06 18:09:55 +02:00
Milos Colakovic
1421449991 Remove routes for removed WebProfiler actions
The import/export functionality was moved to commands in f38536ab79, but the routes were not removed.
2014-09-06 18:09:54 +02:00
Fabien Potencier
b064d2f0fd [Monolog] changed the not found activation strategy to use the request stack 2014-09-06 12:17:39 +02:00
Fabien Potencier
784df79956 feature #11373 [FrameworkBundle][Translation] moved cache to Translation component (new PR) (aitboudad, OwlyCode)
This PR was merged into the 2.6-dev branch.

Discussion
----------

[FrameworkBundle][Translation] moved cache to Translation component (new PR)

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #10628
| License       | MIT
| Doc PR        |

This supersedes the PR #11197 (while including the changes made by it). I removed the `$options` argument for `Symfony\Component\Translation\Translator` and replaced it by a public method `enableCache($cacheDir, $debug = false)`. It aims to solve what @fabpot said about passing an array of options in #11197 <s>while not modifying the existing constructors</s>.

Commits
-------

30fed6a [Translation][Cache] Removed the options from the arguments of Translator
8b2d9a8 [FrameworkBundle][Translation] moved cache to Translation component
2014-09-05 15:44:59 +02:00
Fabien Potencier
1893633fb3 bug #11860 [Security] Fix usage of unexistent method in DoctrineAclCache. (mauchede)
This PR was submitted for the master branch but it was merged into the 2.3 branch instead (closes #11860).

Discussion
----------

[Security] Fix usage of unexistent method in DoctrineAclCache.

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #10328
| License       | MIT
| Doc PR        |

The method `deleteByPrefix` does not exist. I replaced it by `deleteAll`: as @guilhermeblanco said, this method is not available in the interface `Cache` but it is present in the abstract class `CacheProvider`.

Commits
-------

131abd8 [Security] Fix usage of unexistent method in DoctrineAclCache.
2014-09-05 15:11:41 +02:00
Morgan Auchede
131abd816f [Security] Fix usage of unexistent method in DoctrineAclCache. 2014-09-05 15:11:41 +02:00
Tristan Maindron
30fed6a620 [Translation][Cache] Removed the options from the arguments of Translator
Fixed phpdoc

Aligned variables and description

Removed enableCache and added cache setup in constructor

Added tests for locales with . and @ with caching
2014-09-05 13:44:55 +02:00
Fabien Potencier
cfe60a4a47 bug #11850 [YAML] properly mask escape sequences in quoted strings (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[YAML] properly mask escape sequences in quoted strings

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #11789
| License       | MIT
| Doc PR        |

Commits
-------

a7d0cf2 properly mask escape sequences in quoted strings
2014-09-05 12:07:58 +02:00
Fabien Potencier
8897e58670 bug #11856 [FrameworkBundle] backport more error information from 2.6 to 2.3 (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] backport more error information from 2.6 to 2.3

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #11724
| License       | MIT
| Doc PR        |

Commits
-------

87449e0 backport more error information from 2.6 to 2.3
2014-09-05 10:46:07 +02:00
Christian Flothmann
87449e04f2 backport more error information from 2.6 to 2.3
The commit on master was:

server:run command: provide more error information

The server:run command didn't provide many information when the executed
command exited unexpectedly. Now, the process' exit code is passed through
and an error message is displayed.
2014-09-05 10:17:01 +02:00
Abdellatif Ait boudad
8b2d9a8d4d [FrameworkBundle][Translation] moved cache to Translation component
[Translation][Cache] removed accessors for options.
2014-09-05 10:11:24 +02:00
Romain Neutron
888f0eb3f5 minor #11842 [Process] add missing exceptions to docblock (xabbuh)
This PR was merged into the 2.5 branch.

Discussion
----------

[Process] add missing exceptions to docblock

| Q             | A
| ------------- | ---
| Fixed tickets |
| License       | MIT

Commits
-------

1be80c6 add missing exceptions to docblock
2014-09-05 09:43:27 +02:00
Fabien Potencier
eb1e3c344c minor #11851 [HttpKernel] Escape SSI virtual in generated response (Jérémy Derussé)
This PR was merged into the 2.6-dev branch.

Discussion
----------

[HttpKernel] Escape SSI virtual in generated response

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | NA

If a template with an `<!--#inlude -->` tag  is configured with an "virtual" containing a `'` ; the HttpCache will generate invalide php code.

See #11845 for the same issue on `<esi>` tags

Commits
-------

b50a434 Fix CS
1862427 Escape SSI virtual in generated response
2014-09-05 09:37:13 +02:00
Fabien Potencier
7e5ec59fc8 minor #11845 [HttpKernel] Escape ESI url in generated response (Jérémy Derussé)
This PR was merged into the 2.3 branch.

Discussion
----------

[HttpKernel] Escape ESI url in generated response

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | NA

If a template with an `<esi>` tag  is configured with an URL containing a `'` (in  `src` or `alt`) ; the HttpCache will generate invalide php code.

It's not a security issue, given the template and the `<esi>` tag is written by the developper, but, as the character quote is allowed in URL (https://tools.ietf.org/html/rfc3986) it coud be a potential bug.

Commits
-------

b044c45 Escape parameter on generated response
2014-09-05 09:35:40 +02:00
Fabien Potencier
43b10bc732 bug #11854 [FileSystem] Fix Throw Exception on copying from an unreadable file (Jérémy Derussé)
This PR was merged into the 2.6-dev branch.

Discussion
----------

[FileSystem] Fix Throw Exception on copying from an unreadable file

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | NA

Two commits on `Filesystem::copy`  was merged on diffrentes branches c056a9c426 and cd5da9b3c8 but on the merge operation a `@fopen` was transformed to `fopen` . Thas why, actualy, travis is down on master branch (https://travis-ci.org/symfony/symfony/jobs/34427199#L434)

Commits
-------

b30317e Ignore warning on fopen
2014-09-05 07:17:16 +02:00
Kévin Dunglas
3071557ec8 [Security] Add more tests for StringUtils::equals 2014-09-04 23:39:11 +02:00
Kévin Dunglas
03bd74bdea [Security] Use hash_equals for constant-time string comparison 2014-09-04 23:37:08 +02:00
Jérémy Derussé
b30317e5f3 Ignore warning on fopen 2014-09-04 23:09:17 +02:00
Christian Flothmann
a7d0cf2070 properly mask escape sequences in quoted strings 2014-09-04 22:00:25 +02:00
Jérémy Derussé
b50a4345f6 Fix CS 2014-09-04 21:31:49 +02:00
Jérémy Derussé
18624270bb Escape SSI virtual in generated response 2014-09-04 20:59:01 +02:00
Fabien Potencier
80536d012d bug #11843 [Yaml] improve error message when detecting unquoted asterisks (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[Yaml] improve error message when detecting unquoted asterisks

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #11835
| License       | MIT
| Doc PR        |

Asterisks in unquoted strings are used in YAML to reference variables. Before Symfony 2.3.19, Symfony 2.4.9 and Symfony 2.5.4, unquoted asterisks in inlined YAML code were treated as regular strings. This was fixed for the inline parser in #11677. However, an unquoted * character now led to an error message like this:

```
PHP Warning:  array_key_exists(): The first argument should be either a string or an integer in vendor/symfony/symfony/src/Symfony/Component/Yaml/Inline.php on line 409

  [Symfony\Component\Yaml\Exception\ParseException]
  Reference "" does not exist at line 171 (near "- { foo: * }").
```

Commits
-------

854e07b improve error when detecting unquoted asterisks
2014-09-04 11:57:59 +02:00
Christian Flothmann
1be80c64d2 add missing exceptions to docblock 2014-09-03 22:47:09 +02:00
Jérémy Derussé
b044c45679 Escape parameter on generated response 2014-09-03 22:47:06 +02:00
Christian Flothmann
0a16cf2102 improve handling router script paths
The `server:run` command switches the working directory before
starting the built-in web server. Therefore, the path to a custom
router script had to be specified based on the document root path
and not based on the user's working directory.
2014-09-03 22:34:28 +02:00
Christian Flothmann
854e07b1de improve error when detecting unquoted asterisks
Asterisks in unquoted strings are used in YAML to reference
variables. Before Symfony 2.3.19, Symfony 2.4.9 and Symfony 2.5.4,
unquoted asterisks in inlined YAML code were treated as regular
strings. This was fixed for the inline parser in #11677. However, an
unquoted * character now led to an error message like this:

```
PHP Warning:  array_key_exists(): The first argument should be either a string or an integer in vendor/symfony/symfony/src/Symfony/Component/Yaml/Inline.php on line 409

  [Symfony\Component\Yaml\Exception\ParseException]
  Reference "" does not exist at line 171 (near "- { foo: * }").
```
2014-09-03 21:08:43 +02:00
Fabien Potencier
afb82e83af bumped Symfony version to 2.5.5 2014-09-03 14:51:22 +02:00
Fabien Potencier
8d6b59b0bd bumped Symfony version to 2.4.10 2014-09-03 14:51:14 +02:00
Fabien Potencier
1033dc59cd bumped Symfony version to 2.3.20 2014-09-03 14:50:59 +02:00
Fabien Potencier
3a369dddea updated VERSION for 2.5.4 2014-09-03 11:51:48 +02:00
Fabien Potencier
56855cdc07 updated CHANGELOG for 2.5.4 2014-09-03 11:51:41 +02:00
Fabien Potencier
6266883049 updated VERSION for 2.4.9 2014-09-03 11:50:20 +02:00
Fabien Potencier
0c3200e5fc updated CHANGELOG for 2.4.9 2014-09-03 11:50:09 +02:00