Skip to content

Commit

Permalink
ENGCOM-2570: [Backport] FIXED: FTP user and password strings urldecoded
Browse files Browse the repository at this point in the history
Stanislav Idolov authored Jul 31, 2018

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
2 parents 78cddfc + 34ffac7 commit 0cf21a6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/internal/Magento/Framework/System/Ftp.php
Original file line number Diff line number Diff line change
@@ -105,6 +105,12 @@ public function validateConnectionString($string)
if ($data['scheme'] != 'ftp') {
throw new \Exception("Support for scheme unsupported: '{$data['scheme']}'");
}

// Decode user & password strings from URL
foreach (array_intersect(array_keys($data), ['user','pass']) as $key) {
$data[$key] = urldecode($data[$key]);
}

return $data;
}

0 comments on commit 0cf21a6

Please sign in to comment.