SSHBackend doesn't handle spaces in path
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Duplicity |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Duplicity version: 0.6.06
Python version: 2.5.2
OS Distro and version: Cygwin 1.7.1
Storage backend: scp
Storage backend system: Debian Linux
Description:
I run duplicity like this:
export SIG_CACHE=
export EXCLUDE_
duplicity full -v4 --archive-dir "$SIG_CACHE" --asynchronous-
specifying an archive-dir which contains spaces and get the following error message:
...
Remote file or directory does not exist in
...
The source of this problem seems to be that the ssh backend does not encapsulate the paths for the sftp commands proper.
The file src/backends/
commands = ["put %s %s%s" %
If this line is replaced by:
commands = ["put \"%s\" \"%s%s\"" %
the error does not occur.
I've attached a patch, which modifies a couple of lines in sshbackend.py accordingly. I've not:
- tested the patch carefully
- checked it for possible side effects
- checked if all relevant lines are patched
- compared this behaviour with scp implementation of this backend
I would appreciate it if somebody could review and apply this patch.
Thank you.
Kuno Ospald
Changed in duplicity: | |
status: | New → Fix Committed |
importance: | Undecided → Medium |
milestone: | none → 0.6.07 |
Changed in duplicity: | |
status: | Fix Committed → Fix Released |