1
0
Fork 0

apply patch

pull/5723/head
Rob Bast 2016-09-27 14:45:33 +02:00
parent b4fd19aae4
commit e60eff5f2e
No known key found for this signature in database
GPG Key ID: 73076E35E6165F39
1 changed files with 3 additions and 3 deletions

View File

@ -44,12 +44,12 @@ class ProcessExecutor
public function execute($command, &$output = null, $cwd = null)
{
if ($this->io && $this->io->isDebug()) {
$safeCommand = preg_replace_callback('{(://)(?P<user>[^:/\s]+):(?P<password>[^@\s/]+)}i', function ($m) {
$safeCommand = preg_replace_callback('{://(?P<user>[^:/\s]+):(?P<password>[^@\s/]+)@}i', function ($m) {
if (preg_match('{^[a-f0-9]{12,}$}', $m['user'])) {
return '://***:***';
return '://***:***@';
}
return '://'.$m['user'].':***';
return '://'.$m['user'].':***@';
}, $command);
$this->io->writeError('Executing command ('.($cwd ?: 'CWD').'): '.$safeCommand);
}