Skip to content

Commit be9f55a

Browse files
authored
Merge pull request #1978 from nextcloud/dependabot/composer/symfony/http-foundation-6.4.14
build(deps): Bump symfony/http-foundation from 6.4.12 to 6.4.14
2 parents bfa9cc8 + 0f9749a commit be9f55a

File tree

5 files changed

+75
-58
lines changed

5 files changed

+75
-58
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
"stecman/symfony-console-completion": "^0.13.0",
5353
"symfony/console": "^6.4.12",
5454
"symfony/event-dispatcher": "^6.4.8",
55-
"symfony/http-foundation": "^6.4.12",
55+
"symfony/http-foundation": "^6.4.14",
5656
"symfony/mailer": "^6.4",
5757
"symfony/polyfill-intl-grapheme": "^1.31.0",
5858
"symfony/polyfill-intl-normalizer": "^1.31.0",

composer.lock

Lines changed: 26 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

composer/installed.json

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -4595,31 +4595,31 @@
45954595
},
45964596
{
45974597
"name": "symfony/deprecation-contracts",
4598-
"version": "v3.5.0",
4599-
"version_normalized": "3.5.0.0",
4598+
"version": "v3.5.1",
4599+
"version_normalized": "3.5.1.0",
46004600
"source": {
46014601
"type": "git",
46024602
"url": "https://github.com/symfony/deprecation-contracts.git",
4603-
"reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1"
4603+
"reference": "74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6"
46044604
},
46054605
"dist": {
46064606
"type": "zip",
4607-
"url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1",
4608-
"reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1",
4607+
"url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6",
4608+
"reference": "74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6",
46094609
"shasum": ""
46104610
},
46114611
"require": {
46124612
"php": ">=8.1"
46134613
},
4614-
"time": "2024-04-18T09:32:20+00:00",
4614+
"time": "2024-09-25T14:20:29+00:00",
46154615
"type": "library",
46164616
"extra": {
4617+
"thanks": {
4618+
"url": "https://github.com/symfony/contracts",
4619+
"name": "symfony/contracts"
4620+
},
46174621
"branch-alias": {
46184622
"dev-main": "3.5-dev"
4619-
},
4620-
"thanks": {
4621-
"name": "symfony/contracts",
4622-
"url": "https://github.com/symfony/contracts"
46234623
}
46244624
},
46254625
"installation-source": "dist",
@@ -4645,7 +4645,7 @@
46454645
"description": "A generic function and convention to trigger deprecation notices",
46464646
"homepage": "https://symfony.com",
46474647
"support": {
4648-
"source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.0"
4648+
"source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.1"
46494649
},
46504650
"funding": [
46514651
{
@@ -4897,17 +4897,17 @@
48974897
},
48984898
{
48994899
"name": "symfony/http-foundation",
4900-
"version": "v6.4.12",
4901-
"version_normalized": "6.4.12.0",
4900+
"version": "v6.4.14",
4901+
"version_normalized": "6.4.14.0",
49024902
"source": {
49034903
"type": "git",
49044904
"url": "https://github.com/symfony/http-foundation.git",
4905-
"reference": "133ac043875f59c26c55e79cf074562127cce4d2"
4905+
"reference": "ba020a321a95519303a3f09ec2824d34d601c388"
49064906
},
49074907
"dist": {
49084908
"type": "zip",
4909-
"url": "https://api.github.com/repos/symfony/http-foundation/zipball/133ac043875f59c26c55e79cf074562127cce4d2",
4910-
"reference": "133ac043875f59c26c55e79cf074562127cce4d2",
4909+
"url": "https://api.github.com/repos/symfony/http-foundation/zipball/ba020a321a95519303a3f09ec2824d34d601c388",
4910+
"reference": "ba020a321a95519303a3f09ec2824d34d601c388",
49114911
"shasum": ""
49124912
},
49134913
"require": {
@@ -4929,7 +4929,7 @@
49294929
"symfony/mime": "^5.4|^6.0|^7.0",
49304930
"symfony/rate-limiter": "^5.4|^6.0|^7.0"
49314931
},
4932-
"time": "2024-09-20T08:18:25+00:00",
4932+
"time": "2024-11-05T16:39:55+00:00",
49334933
"type": "library",
49344934
"installation-source": "dist",
49354935
"autoload": {
@@ -4957,7 +4957,7 @@
49574957
"description": "Defines an object-oriented layer for the HTTP specification",
49584958
"homepage": "https://symfony.com",
49594959
"support": {
4960-
"source": "https://github.com/symfony/http-foundation/tree/v6.4.12"
4960+
"source": "https://github.com/symfony/http-foundation/tree/v6.4.14"
49614961
},
49624962
"funding": [
49634963
{
@@ -5507,8 +5507,8 @@
55075507
"type": "library",
55085508
"extra": {
55095509
"thanks": {
5510-
"name": "symfony/polyfill",
5511-
"url": "https://github.com/symfony/polyfill"
5510+
"url": "https://github.com/symfony/polyfill",
5511+
"name": "symfony/polyfill"
55125512
}
55135513
},
55145514
"installation-source": "dist",
@@ -5584,8 +5584,8 @@
55845584
"type": "library",
55855585
"extra": {
55865586
"thanks": {
5587-
"name": "symfony/polyfill",
5588-
"url": "https://github.com/symfony/polyfill"
5587+
"url": "https://github.com/symfony/polyfill",
5588+
"name": "symfony/polyfill"
55895589
}
55905590
},
55915591
"installation-source": "dist",
@@ -5667,8 +5667,8 @@
56675667
"type": "library",
56685668
"extra": {
56695669
"thanks": {
5670-
"name": "symfony/polyfill",
5671-
"url": "https://github.com/symfony/polyfill"
5670+
"url": "https://github.com/symfony/polyfill",
5671+
"name": "symfony/polyfill"
56725672
}
56735673
},
56745674
"installation-source": "dist",

composer/installed.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -671,9 +671,9 @@
671671
'dev_requirement' => false,
672672
),
673673
'symfony/deprecation-contracts' => array(
674-
'pretty_version' => 'v3.5.0',
675-
'version' => '3.5.0.0',
676-
'reference' => '0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1',
674+
'pretty_version' => 'v3.5.1',
675+
'version' => '3.5.1.0',
676+
'reference' => '74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6',
677677
'type' => 'library',
678678
'install_path' => __DIR__ . '/../symfony/deprecation-contracts',
679679
'aliases' => array(),
@@ -713,9 +713,9 @@
713713
),
714714
),
715715
'symfony/http-foundation' => array(
716-
'pretty_version' => 'v6.4.12',
717-
'version' => '6.4.12.0',
718-
'reference' => '133ac043875f59c26c55e79cf074562127cce4d2',
716+
'pretty_version' => 'v6.4.14',
717+
'version' => '6.4.14.0',
718+
'reference' => 'ba020a321a95519303a3f09ec2824d34d601c388',
719719
'type' => 'library',
720720
'install_path' => __DIR__ . '/../symfony/http-foundation',
721721
'aliases' => array(),

symfony/http-foundation/Request.php

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Component\HttpFoundation;
1313

14+
use Symfony\Component\HttpFoundation\Exception\BadRequestException;
1415
use Symfony\Component\HttpFoundation\Exception\ConflictingHeadersException;
1516
use Symfony\Component\HttpFoundation\Exception\JsonException;
1617
use Symfony\Component\HttpFoundation\Exception\SessionNotFoundException;
@@ -326,6 +327,8 @@ public static function createFromGlobals(): static
326327
* @param array $files The request files ($_FILES)
327328
* @param array $server The server parameters ($_SERVER)
328329
* @param string|resource|null $content The raw body data
330+
*
331+
* @throws BadRequestException When the URI is invalid
329332
*/
330333
public static function create(string $uri, string $method = 'GET', array $parameters = [], array $cookies = [], array $files = [], array $server = [], $content = null): static
331334
{
@@ -354,6 +357,20 @@ public static function create(string $uri, string $method = 'GET', array $parame
354357
unset($components['fragment']);
355358
}
356359

360+
if (false === $components) {
361+
throw new BadRequestException('Invalid URI.');
362+
}
363+
364+
if (false !== ($i = strpos($uri, '\\')) && $i < strcspn($uri, '?#')) {
365+
throw new BadRequestException('Invalid URI: A URI cannot contain a backslash.');
366+
}
367+
if (\strlen($uri) !== strcspn($uri, "\r\n\t")) {
368+
throw new BadRequestException('Invalid URI: A URI cannot contain CR/LF/TAB characters.');
369+
}
370+
if ('' !== $uri && (\ord($uri[0]) <= 32 || \ord($uri[-1]) <= 32)) {
371+
throw new BadRequestException('Invalid URI: A URI must not start nor end with ASCII control characters or spaces.');
372+
}
373+
357374
if (isset($components['host'])) {
358375
$server['SERVER_NAME'] = $components['host'];
359376
$server['HTTP_HOST'] = $components['host'];
@@ -1231,7 +1248,7 @@ public function getMethod(): string
12311248
}
12321249

12331250
if (!preg_match('/^[A-Z]++$/D', $method)) {
1234-
throw new SuspiciousOperationException(sprintf('Invalid method override "%s".', $method));
1251+
throw new SuspiciousOperationException('Invalid HTTP method override.');
12351252
}
12361253

12371254
return $this->method = $method;

0 commit comments

Comments
 (0)