Incorrect processing of SSH upload URL
If a path is a part of an SSH upload URL it is incorrectly processed.
Steps to reproduce
- Prepare an SSH-capable machine, create a directory on it (e.g.
/srv/turris
) a set permissions to write for the user you want to use for upload. Don't jail the user inside his home directory (the problem isn't dependent on this situation but it's necessary to define the test conditions well). - Login to your Turris and try to upload some snapshot, e.g.
schnapps 311 ssh://192.168.1.200/srv/turris
Expected results
The snapshot is uploaded into /srv/turris
on the given machine.
Actual results
The snapshot is not uploaded at all. schnapps
fails to mount (read: Connection reset by peer) and then creates the snapshot tarball in the local directory (/mnt/.remote-snapshots
) despite of no remote filesystem is mounted on it.
Edited by Lukas Jelinek