Re: Passing SFTP options when using SCP

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

 



On Wed, 7 Dec 2022 at 10:46, Thorsten Glaser <t.glaser@xxxxxxxxx> wrote:
> On Tue, 6 Dec 2022, Chris Rapier wrote:
> > Just curious. If there isn't I'll try to come up with a method and share it
> > when I'm done.

There's not currently.  Those are arguments 3 and 4 to do_init().  In
sftp.c they're:
    conn = do_init(in, out, copy_buffer_len, num_requests, limit_kbps);

but in scp.c they're hard coded as:
    return do_init(*reminp, *remoutp, 32768, 64, limit_kbps);

> Mapping them all into ‘-o’-style long options would be good.
> Perhaps even use -o and ssh(1) should just reject those that
> are file transfer-only.

That would probably be messy.  Right now -o options are handled by
ssh's config file parser and scp/sftp have no knowledge of any of
that, they just pass -o options through to ssh.  You'd probably have
to add a dependency on readconf.c, and you'd end up with two classes
of config keywords that work differently.  That would likely be a
source of confusion ("Why can't I set SFTPBufferSize in
~/.ssh/config?").

scp's -B -r and -R are all taken.  -s and -S (for "sftp thing") are
also taken.  -b is available, as is -n/-N ("number of requests").

-- 
Darren Tucker (dtucker at dtucker.net)
GPG key 11EAA6FA / A86E 3E07 5B19 5880 E860  37F4 9357 ECEF 11EA A6FA (new)
    Good judgement comes with experience. Unfortunately, the experience
usually comes from bad judgement.
_______________________________________________
openssh-unix-dev mailing list
openssh-unix-dev@xxxxxxxxxxx
https://lists.mindrot.org/mailman/listinfo/openssh-unix-dev




[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux