1
0
Fork 0

Correctly extract username/password from URL

pull/6728/merge
gregory 2017-10-11 15:55:31 +03:00 committed by Jordi Boggiano
parent 065b662d5b
commit 8a136d18e5
1 changed files with 1 additions and 1 deletions

View File

@ -224,7 +224,7 @@ class RemoteFilesystem
$this->redirects = 1; // The first request counts.
// capture username/password from URL if there is one
if (preg_match('{^https?://(.+):(.+)@([^/]+)}i', $fileUrl, $match)) {
if (preg_match('{^https?://([^:]+):([^@]+)@([^/]+)}i', $fileUrl, $match)) {
$this->io->setAuthentication($originUrl, urldecode($match[1]), urldecode($match[2]));
}