[freeside] Small Patch

ivan ivan at 420.am
Tue Jul 18 05:37:15 PDT 2000


On Thu, Jul 13, 2000 at 01:08:10PM -0500, Kenny Elliott wrote:
> > Hmm, I'm not certain about this patch.  *All* of the scp commands in
> > svc_acct.export, not just the ones you patched, copy a file
> > to a file.
> 
> Yes this is quite possible. I was just trying to track down this one
> problem.
> 
> > This seems to work with both "classic" ssh1 and OpenSSH.
> > You are using
> > the commercial SSH 2?  Is this behavior documented?  What's
> > the error
> > message you get when it fails?
> 
> Yes, I'm using the Commercial version of SSH 2.
> 
> The only mention in the scp2 manpage is..
> 
>   This option specifies, that scp2 should copy direc­tories
> recursively. Does not follow symbolic links.
> 
> The error is..
> 
> warning: Destination file is not a directory.
> warning: Exiting.
> 
> 
> > I think I'd be more comfortable with something that chose
> > the appopriate
> > flags for your each of scp.  In this case you wouldn't need
> > to check the
> > version as such; you could probably stat the source file,
> > and only turn on
> > the scp `-r' if it's a directory (in perl, if `-d
> > $filename' is true).
> 
> Yes. That would be best. Perhaps though there should be a
> configuration option instead of checking all of the possible locations
> of ssh2.

Umm, that's what PATH is for.

You don't need to do any specific checking for ssh2 to fix your particular
problem, you simply need to check the source file in the scp and turn off
the `-r' flag if it's a directory.  I'd expect that this wouldn't cause
any problems with the commercial SSH 1 or OpenSSH. 

> 
> > The `-q' flag is a separate issue.
> >
> > The ssh 1.2.26 scp manpage says:
> >
> >        -q    Turn off statistics display.
> >
> > The openssh 1.2.3 scp manpages says:
> >
> > 	-q      Disables the progress meter.
> >
> > What does the commercial SSH 2 scp manpage say about -q?
> >
> > (Hmm, I wonder if -q turns off error reporting in all versions)
> 
> It does not mention the -q switch however running scp with -q does run
> it in "quite" mode. It return no statistics or errors with the -q
> switch.

Well, the statstics have to be turned off, that's obvious.  If the
commercial SSH 2 also turns off error messages and doesn't provide a way
to control them separately, than I'd call that a design flaw.

-- 
meow
_ivan



More information about the freeside-users mailing list