Skip to content

Commit 103d38a

Browse files
Restrict the allowed characters between the brackets. This is necessary because it might include nested brackets. (#44908)
"[13804] [Fri Nov 11 16:37:08 2022] [::1]" would resolve into "[Fri Nov 11 16:37:08 2022] [::1"
1 parent 8d47416 commit 103d38a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Illuminate/Foundation/Console/ServeCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ protected function handleProcessOutput()
289289
protected function getDateFromLine($line)
290290
{
291291
$regex = env('PHP_CLI_SERVER_WORKERS', 1) > 1
292-
? '/^\[\d+]\s\[(.*)]/'
292+
? '/^\[\d+]\s\[([a-zA-Z0-9: ]+)\]/'
293293
: '/^\[([^\]]+)\]/';
294294

295295
preg_match($regex, $line, $matches);

0 commit comments

Comments
 (0)