Re: scp does not copy, no error msg, ssh works

From: Almut Behrens (almut_behrens_at_gmx.net)
Date: 04/27/05

  • Next message: Chris Boot: "Re: Hardware random on Dell PE SC1425"
    Date: Wed, 27 Apr 2005 20:45:25 +0200
    To: debian-user@lists.debian.org
    
    

    On Wed, Apr 27, 2005 at 01:44:06PM +0200, Marc Mueller wrote:
    > >debug1: Sending command: scp -v -t .
    > >Linux kiste 2.4.26-1-k7 #1 Tue Aug 24 14:08:24 JST 2004 i686 GNU/Linux
    > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    > scp gets confused if there is any output from the target. Check from
    > where this line is generated (.bashrc?) and comment it out.

    On Wed, Apr 27, 2005 at 05:27:35PM +0100, michael wrote:
    > On Wed, 2005-04-27 at 09:54 -0600, Monique Y. Mudama wrote:
    > > On 2005-04-27, Ulrich Scholz penned:
    > > > Thank you, that solved the problem!
    > > >
    > > > It took me quite a while to eliminate the output but without, it
    > > > works!
    > > >
    > > > But why is that a problem?
    > > >
    > > >
    > > > Thanks to all of you,
    > > >
    > > > Uli
    > >
    > > I'm sure I'm not the only person out here wondering which suggestion
    > > solved the problem. Unfortunately, since you didn't quote the person
    > > who made the suggestion, we have no idea.
    >
    > (It wasn't my suggestions that helped so I'll make amends:)
    >
    > I believe it the solution was "if scp gets any string back from the
    > remote host when the connection is authorized then you will get
    > unpredicted results such as no file copied and no warnings"

    In case the OP really wanted to have something like "Linux kiste ..."
    be printed when logging in, he could simply put it in the shell startup
    file that's being sourced for _login_ shells only. In that case, scp
    wouldn't have a problem.

    Most shells have two kinds of startup files. One of them is being
    sourced on every interactive invocation of the shell. The other one
    only when it's a login shell. For bash, the former is ~/.bashrc, and
    the latter is one of ~/.bash_profile, ~/.bash_login, ~/.profile (or
    the respective system-wide variant).
    See bash(1), section INVOCATION for full details.

    Almut

    -- 
    To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org 
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
    

  • Next message: Chris Boot: "Re: Hardware random on Dell PE SC1425"

    Relevant Pages

    • vulnerabilities in scponly
      ... without allowing shell access. ... scponly makes no effort to verify the path to the scp or sftp-server ... arbitrary commands by simply uploading a file. ... However, if this is *NOT* the case, the user could execute arbitrary ...
      (Bugtraq)
    • Re: scp syntax and denied permission
      ... >> this is sort of a newby question but in some regards it might be not. ... > The tilde is interpreted by the shell and ... on the destination system, so if home dirs are different on the 2 boxes, you'll ... >> When I try to copy the next higher directory the scp starts but once ...
      (comp.unix.shell)
    • Re: dummy shell for file transfer accounts
      ... > On some of my systems, I have a bash shell script presenting the user ... > So, if the login shell is executed with a -c flag, it only allows scp ... > the chroot part. ...
      (comp.security.ssh)
    • Re: Difference between SCP and SFTP ?
      ... >>But It's seems that SCP need a user Shell, ... > sftp is just FTP over SSH. ... It's interface is similar to FTP, ...
      (comp.security.ssh)
    • Re: scp exploit
      ... want scp, but not necessarily the ability to pass in commands. ... server's running a restricted shell then the shell ought to filter the ... from sending a command string via ssh containing ";" (or any other shell ...
      (comp.security.ssh)