From: Bjoern Schiessle Date: Tue, 8 Oct 2013 18:19:39 +0000 (+0200) Subject: remove username/passswords from URLs before writing the to the log file X-Git-Tag: v5.0.13~44^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=9edd9373e77d1d9fe66e757f63884a77f6193f07;p=nextcloud-server.git remove username/passswords from URLs before writing the to the log file --- diff --git a/lib/log.php b/lib/log.php index 3f3334801e5..e31e2a893c4 100644 --- a/lib/log.php +++ b/lib/log.php @@ -36,6 +36,8 @@ class OC_Log { call_user_func(array(self::$class, 'init')); } $log_class=self::$class; + // remove username/passswords from URLs before writing the to the log file + $message = preg_replace('/\/\/(.*):(.*)@/', '//xxx:xxx@', $message); $log_class::write($app, $message, $level); } }