Die.

---

libsloth

In bash, you could:
export LD_PRELOAD=/usr/local/lib/libsloth.so
export BYTES_PER_SECOND=10000
wget ...
In tcsh, you might:
setenv LD_PRELOAD /usr/local/lib/libsloth.so
setenv BYTES_PER_SECOND 10000
ncftp ...
Or in /etc/hosts.allow, for a service run by inetd using tcp_wrappers for access control. Using this method, you can even set different rate limits for different remote sites:
in.ftpd:10.0.0.0/255.0.0.0:setenv LD_PRELOAD /usr/local/lib/libsloth.so:setenv BYTES_PER_SECOND 10000:allow
in.ftpd:ALL:allow

(Beware that you need a copy of libsloth.so also in ~ftp/usr/local/lib/ if you use an ftpd that runs an external ls, such as wu-ftpd.)

---
webmaster @ die.net
Back