fix: SftpUploader uses StrictHostKeyChecking=no — vulnerable to MITM #182
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
SftpUploader.php:210,238passes-o StrictHostKeyChecking=noto both scp and ssh commands. This disables SSH host key verification on every connection, making SFTP uploads vulnerable to man-in-the-middle attacks.Location
src/Engine/SftpUploader.php:210(buildScpCommand)src/Engine/SftpUploader.php:238(buildSshCommand)Fix
Change to
StrictHostKeyChecking=accept-new— trusts on first connect, rejects if the key changes. Optionally allow users to provide a known_hosts path in the profile config.Branch created:
feature/182-fix-sftpuploader-uses-stricthostkeycheck