From 9b3361ce8740226ae60bbc0a525d617e43286843 Mon Sep 17 00:00:00 2001
From: Vincent Petry <vincent@nextcloud.com>
Date: Fri, 4 Dec 2020 09:22:30 +0100
Subject: [PATCH] Don't log params of imagecreatefromstring

To prevent flooding the log with actual image data.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
---
 lib/private/Log/ExceptionSerializer.php | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lib/private/Log/ExceptionSerializer.php b/lib/private/Log/ExceptionSerializer.php
index a2bc1963003..339a6604ed1 100644
--- a/lib/private/Log/ExceptionSerializer.php
+++ b/lib/private/Log/ExceptionSerializer.php
@@ -86,6 +86,9 @@ class ExceptionSerializer {
 
 		// files_external: UserStoragesController
 		'update',
+
+		// Preview providers, don't log big data strings
+		'imagecreatefromstring',
 	];
 
 	public const methodsWithSensitiveParametersByClass = [
-- 
GitLab