1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-02 08:42:48 +00:00
freebsd/contrib/tnftp
Hiroki Sato 43092b7d08 Fix poor performance of ftp(1) due to small SO_SNDBUF and SO_RCVBUF.
ftp(1) from vendor/tnftp always tried the following for
every TCP connection:

1. Get the current buffer length of SO_SNDBUF and SO_RCVBUF
   by getsockopt(2).

2. Invoke setsockopt(2) to set them to the same values
   after checking if they are in a range between 8 KiB to 8 MiB.

This behavior broke dynamic buffer sizing enabled by
default (net.inet.tcp.{recv,send}buf_auto sysctls) and
led to a very poor transfer rate.  The fetch(1) utility
does not have this problem.

This change prevents SO_SNDBUF and SO_RCVBUF from configuring
when the buffer auto-sizing is enabled unless the buffer sizes are
explicitly specified.

PR:		240827
Spotted by:	Yuichiro NAITO
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D23732
2020-02-27 19:49:59 +00:00
..
src Fix poor performance of ftp(1) due to small SO_SNDBUF and SO_RCVBUF. 2020-02-27 19:49:59 +00:00
ChangeLog
COPYING
INSTALL
Makefile.am
Makefile.in
NEWS
README
THANKS
tnftp.h
todo

WHAT IS TNFTP?
--------------

`tnftp' is a `port' of the NetBSD FTP client to other systems.
See http://www.NetBSD.org/ for more details about NetBSD.

tnftp was formerly known as `lukemftp'
It was renamed to `tnftp' by Luke Mewburn in February 2003.

The enhancements over the standard ftp client in 4.4BSD (and
derivatives) include:
	* command-line editing within ftp
	* command-line fetching of URLS, including support for:
	    - http proxies (see $http_proxy, $ftp_proxy)
	    - authentication
	* configurable prompt
	* context sensitive command and filename completion
	* dynamic progress bar
	* feature negotiation extensions from RFC 2389
	  (see `feat' and `remopts')
	* extensions to ftp from the IETF ftpext working group
	  (see `mlsd' and `mlst')
	* IPv6 support (from the WIDE project)
	* modification time preservation
	* paging of local and remote files, and of directory listings
	  (see `lpage', `page', `pdir')
	* passive mode support, with fallback to active mode
	* retrieval of filenames listed in a given file (see `fget')
	* `set option' override of ftp environment variables
	* TIS Firewall Toolkit gate ftp proxy support (see `gate')
	* transfer-rate throttling (see `-T', `rate')
	* uploading of files on the command line (see `-u')
	* (Dante) SOCKS5 support

Previous features, currently disabled until a test system is available:
	* SOCKS4 support


INSTALLATION
------------

Refer to `INSTALL' for more information on how to compile and install tnftp.


FEEDBACK / BUG REPORTS
----------------------

Please email feedback back to the maintainer:
	Luke Mewburn <lukem@NetBSD.org>.


COPYRIGHT
---------

tnftp is covered by a BSD-style copyright notice.
Please refer to the file `COPYING' for more information.


AVAILABILITY
------------

The primary ftp site for tnftp is:
	ftp://ftp.NetBSD.org/pub/NetBSD/misc/tnftp/


DOCUMENT REFERENCE
------------------
$NetBSD: README,v 1.10 2007/08/06 01:58:57 lukem Exp $