From 46c10c77e1d5f1b46e665995f9030ccd74283af7 Mon Sep 17 00:00:00 2001 From: Stanimir Bozhilov Date: Mon, 26 Sep 2022 11:51:44 +0200 Subject: Fix the JSON content type regex to match all MIME types Signed-off-by: Stanimir Bozhilov --- lib/private/AppFramework/Http/Request.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/private/AppFramework/Http') diff --git a/lib/private/AppFramework/Http/Request.php b/lib/private/AppFramework/Http/Request.php index ee569273a3f..e4219cefd70 100644 --- a/lib/private/AppFramework/Http/Request.php +++ b/lib/private/AppFramework/Http/Request.php @@ -108,7 +108,7 @@ class Request implements \ArrayAccess, \Countable, IRequest { protected $contentDecoded = false; /** @var string */ - protected string $jsonContentTypeRegex = '/application\/(\w+\+)?json/'; + protected string $jsonContentTypeRegex = '{^application/(?:[a-z0-9.-]+\+)?json\b}'; /** * @param array $vars An associative array with the following optional values: -- cgit v1.2.3