OpenSSH's scp: ambiguous target - SSH

This is a discussion on OpenSSH's scp: ambiguous target - SSH ; I am using OpenSSH_4.7p1, OpenSSL 0.9.8g 19 Oct 2007, which is the most recent version from cygwin. I issue the following command: scp bookmarks.html \ Administrator@localhost:/c /Documents\ and\ Settings /Administrator /Application\ Data /Mozilla /Firefox /Profiles /XXXXXXXX.default /bookmarks.html For the purposes ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: OpenSSH's scp: ambiguous target

  1. OpenSSH's scp: ambiguous target

    I am using OpenSSH_4.7p1, OpenSSL 0.9.8g 19 Oct 2007, which is the
    most recent version from cygwin. I issue the following command:

    scp bookmarks.html \
    Administrator@localhost:/c
    /Documents\ and\ Settings
    /Administrator
    /Application\ Data
    /Mozilla
    /Firefox
    /Profiles
    /XXXXXXXX.default
    /bookmarks.html

    For the purposes of clarity in this posting only, all forward slashes
    have been prepended with a linebreak and indentation spaces above.
    The actual command looks more like the following, minus any linebreaks
    due to newsreader wrapping:

    scp bookmarks.html Administrator@localhost:/c/Documents\ and\
    Settings/Administrator/Application\ Data/Mozilla/Firefox/Profiles/
    XXXXXXXX.default/bookmarks.html

    I get the message "scp: ambiguous target". Instead of the backslashes
    preceding the spaces, I've tried double-quotes around the entire path
    after the colon -- same result. I also tried double backslashes
    instead of quotes, as per
    http://groups.google.ca/group/debian...3efc2b3a8a72d1,
    though that just causes confusion because the spaces become filename
    separators.

    Thanks for any info on whether this is an error on my part, or a bug.

  2. Solved: OpenSSH's scp: ambiguous target

    The solution seems to be to keep the single-backslashes and use double-
    quotes to enclose the entire path after the colon. I assume that the
    quotes preserve the entire path, including backslashes, for scp to
    deliver to the far end. At the far end, the quotes are gone and the
    single-backslashes ensure that the spaces do not become filename
    delimiters.

    ---------- Forwarded message ----------
    From: AndyMHanc...@gmail.com
    Date: Mar 29, 2:59 pm
    Subject: OpenSSH's scp: ambiguous target
    To: comp.security.ssh


    I am using OpenSSH_4.7p1, OpenSSL 0.9.8g 19 Oct 2007, which is the
    most recent version from cygwin. I issue the following command:

    scp bookmarks.html \
    Administrator@localhost:/c
    /Documents\ and\ Settings
    /Administrator
    /Application\ Data
    /Mozilla
    /Firefox
    /Profiles
    /XXXXXXXX.default
    /bookmarks.html

    For the purposes of clarity in this posting only, all forward slashes
    have been prepended with a linebreak and indentation spaces above.
    The actual command looks more like the following, minus any linebreaks
    due to newsreader wrapping:

    scp bookmarks.html Administrator@localhost:/c/Documents\ and\
    Settings/Administrator/Application\ Data/Mozilla/Firefox/Profiles/
    XXXXXXXX.default/bookmarks.html

    I get the message "scp: ambiguous target". Instead of the backslashes
    preceding the spaces, I've tried double-quotes around the entire path
    after the colon -- same result. I also tried double backslashes
    instead of quotes, as perhttp://groups.google.ca/group/debian.bugs.dist/browse_frm/thread/343e...,
    though that just causes confusion because the spaces become filename
    separators.

    Thanks for any info on whether this is an error on my part, or a bug.

+ Reply to Thread