OpenSSH/scp ->> F-Secure SSH server Problems

mouring at etoh.eviladmin.org mouring at etoh.eviladmin.org
Thu Mar 8 03:20:30 EST 2001


On Wed, 7 Mar 2001, Davis, Ricardo C. wrote:

> Thanks for your reply, Ben.
> 
> If I'm reading your response correctly, 'scp' actually uses SSH1 protocol to
> transfer files.  My assumption was that 'scp', by using the 'ssh' client,
> would operate based on the settings in the /etc/ssh/ssh_config file.  In
> this file the site-wide default settings I have "Protocol 2", that is that
> the 'ssh' client would always use SSH2 protocol unless I specify SSH1
> protocol at the command line.  I guess I was wrong here.  However, reading
> the 'man' pages for 'scp' and 'ssh' would lead to the conclusion that is
> possible.  To satisfy my curiosity, I tried using the scp '-o' option to
> pass the '-2' option to 'ssh' -- which forces 'ssh' to force SSH2.  The
> result:
> 

scp can use protocol 1 or protocol 2 as it's transport.  

Both of theses work well:
  scp '-o Protocol 2' file  karla:
  scp '-o Protocol 1' file  karla:

However, when Tatu's company put out SSH 2.x program they decided to drop
the rcp concept and implement scp over top of sftp.  Since F-secure used
SSH Corp's code (IIRC).  They have the same limitation.

=-) I refuse to make comments on the illogicness of this.  But 'scp'
(OpenSSH and ssh-1.2.x) is not the same transfer protocol as 'scp2'
(SSH-2.x, f-secure, etc).

So OpenSSH supports the former, but not the latter at this
moment.  However, sftp (as of the latest snapshot, or soon) supports -b
batchmode which allows the following:

sftp -b batchfile  user at site

or

echo "put file /tmp/path/" | sftp user at site


Granted it's not as nice as "scp2 file user at site:", but it works all the
same.  

If anyone wishes to provide patches to create scp2 using our existing sftp
code feel free.  I personally am waiting for a bit more sftp functionality
before doing it (recursive get/put at least need to go in before scp2
would be useful).   I think someone could write a rought scp2 patch in a
day or two.  Damien has done a nice job at splitting common code into
thier own .c files.

My current project is libedit + sftp (history, tab completion framework,
etc).  The framework is done, but I have some clean up before I present it
to the OpenBSD group.


- Ben






More information about the openssh-unix-dev mailing list