1 #! /bin/sh /usr/share/dpatch/dpatch-run
2 ## 01_fix_max_bandwidth_docs.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
4 ## All lines beginning with `## DP:' are a description of the patch.
5 ## DP: Fix docs and --help to show --max_bandwidth instead of --maxbandwidth
8 diff -urNad redir-2.2.1~/redir.c redir-2.2.1/redir.c
9 --- redir-2.2.1~/redir.c 1999-12-26 15:50:06.000000000 -0500
10 +++ redir-2.2.1/redir.c 2005-10-22 21:21:56.849499952 -0400
13 /* options for bandwidth */
14 fprintf(stderr, "\t\t--bufsize=<octets>\tsize of the buffer\n");
15 - fprintf(stderr, "\t\t--maxbandwidth=<bit-per-sec>\tlimit the bandwidth\n");
16 + fprintf(stderr, "\t\t--max_bandwidth=<bit-per-sec>\tlimit the bandwidth\n");
17 fprintf(stderr, "\t\t--random_wait=<millisec>\twait before each packet\n");
18 fprintf(stderr, "\t\t--wait_in_out=<flag>\t1 wait for in, 2 out, 3 in&out\n");
19 /* end options for bandwidth */
20 diff -urNad redir-2.2.1~/redir.man redir-2.2.1/redir.man
21 --- redir-2.2.1~/redir.man 1999-12-26 15:52:24.000000000 -0500
22 +++ redir-2.2.1/redir.man 2005-10-22 21:22:28.882630176 -0400
27 -.RB [ \--maxbandwidth=n ]
28 +.RB [ \--max_bandwidth=n ]
29 .RB [ \--random_wait=n ]
30 .RB [ \--wait_in_out=n ]
33 .RB [ \--connect=host:port ]
36 -.RB [ \--maxbandwidth=n ]
37 +.RB [ \--max_bandwidth=n ]
38 .RB [ \--random_wait=n ]
39 .RB [ \--wait_in_out=n ]
44 Set the bufsize (defaut 4096) in bytes. Can be used combined with
45 ---maxbandwidth or --random_wait to simulate a slow connection.
46 +--max_bandwidth or --random_wait to simulate a slow connection.
49 +.B \--max_bandwidth n
50 Reduce the bandwidth to be no more than n bits/sec. The algorithme is
51 basic, the goal is to simulate a slow connection, so there is no pic
54 than the bufsize (see also --bufsize).
57 -Apply --maxbandwidth and --random_wait for input if n=1, output if n=2 and
58 +Apply --max_bandwidth and --random_wait for input if n=1, output if n=2 and
62 #! /bin/sh /usr/share/dpatch/dpatch-run
63 ## 02_use_ntohs.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
65 ## All lines beginning with `## DP:' are a description of the patch.
66 ## DP: use ntohs() to generate comprehensible debug()s and syslog()s.
69 diff -urNad redir-2.2.1~/redir.c redir-2.2.1/redir.c
70 --- redir-2.2.1~/redir.c 1999-12-26 15:50:06.000000000 -0500
71 +++ redir-2.2.1/redir.c 2005-10-22 21:29:55.491735272 -0400
75 debug1("peer IP is %s\n", inet_ntoa(client.sin_addr));
76 - debug1("peer socket is %d\n", client.sin_port);
77 + debug1("peer socket is %d\n", ntohs(client.sin_port));
80 * Double fork here so we don't have to wait later
82 strcpy(tmp2, inet_ntoa(target->sin_addr));
84 syslog(LOG_NOTICE, "connecting %s/%d to %s/%d",
85 - tmp1, client.sin_port,
86 - tmp2, target->sin_port);
87 + tmp1, ntohs(client.sin_port),
88 + tmp2, ntohs(target->sin_port));
94 if (!getpeername(0, (struct sockaddr *) &client, &client_size)) {
95 debug1("peer IP is %s\n", inet_ntoa(client.sin_addr));
96 - debug1("peer socket is %d\n", client.sin_port);
97 + debug1("peer socket is %d\n", ntohs(client.sin_port));
99 if ((targetsock = socket(AF_INET, SOCK_STREAM, 0)) < 0) {
100 perror("target: socket");
101 @@ -1109,8 +1109,8 @@
104 syslog(LOG_NOTICE, "connecting %s/%d to %s/%d",
105 - inet_ntoa(client.sin_addr), client.sin_port,
106 - target_ip, target.sin_port);
107 + inet_ntoa(client.sin_addr), ntohs(client.sin_port),
108 + target_ip, ntohs(target.sin_port));
111 /* Just start copying - one side of the loop is stdin - 0 */
112 #! /bin/sh /usr/share/dpatch/dpatch-run
113 ## 03_fix_tcp_wrappers.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
115 ## All lines beginning with `## DP:' are a description of the patch.
116 ## DP: fix calls to tcp wrappers
119 diff -urNad redir-2.2.1~/redir.c redir-2.2.1/redir.c
120 --- redir-2.2.1~/redir.c 2005-10-22 22:10:11.439455392 -0400
121 +++ redir-2.2.1/redir.c 2005-10-22 22:10:51.625346208 -0400
123 #ifdef USE_TCP_WRAPPERS
124 request_init(&request, RQ_DAEMON, ident, RQ_FILE, clisock, 0);
126 - sock_hostname(&request);
127 - sock_hostaddr(&request);
128 + sock_hostname(request.client);
129 + sock_hostaddr(request.client);
131 if (!hosts_access(&request)) {
133 @@ -1057,8 +1057,8 @@
134 #ifdef USE_TCP_WRAPPERS
135 request_init(&request, RQ_DAEMON, ident, RQ_FILE, 0, 0);
137 - sock_hostname(&request);
138 - sock_hostaddr(&request);
139 + sock_hostname(request.client);
140 + sock_hostaddr(request.client);
142 if (!hosts_access(&request))
144 #! /bin/sh /usr/share/dpatch/dpatch-run
145 ## 04_fix_timeouts.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
147 ## All lines beginning with `## DP:' are a description of the patch.
148 ## DP: Apply a close approximation of Robert de Bath's patch for bug #142382
151 diff -urNad redir-2.2.1~/redir.c redir-2.2.1/redir.c
152 --- redir-2.2.1~/redir.c 2005-10-22 22:44:39.504061784 -0400
153 +++ redir-2.2.1/redir.c 2005-10-22 22:47:14.746461352 -0400
155 /* Record start time */
156 start_time = (unsigned int) time(NULL);
158 - /* Set up timeout */
159 - timeout.tv_sec = timeout_secs;
160 - timeout.tv_usec = 0;
162 /* file descriptor bits */
164 FD_SET(insock, &iofds);
165 @@ -618,14 +614,21 @@
167 (void) memcpy(&c_iofds, &iofds, sizeof(iofds));
169 + /* Set up timeout, Linux returns seconds left in this structure
170 + * so we have to reset it before each select(). */
171 + timeout.tv_sec = timeout_secs;
172 + timeout.tv_usec = 0;
175 if (select(max_fd + 1,
179 (timeout_secs ? &timeout : NULL)) <= 0) {
180 - /* syslog(LLEV,"connection timeout: %d sec",timeout.tv_sec);*/
183 + syslog(LOG_NOTICE,"connection timeout: %d sec",timeout_secs);
188 if(FD_ISSET(insock, &c_iofds)) {
189 #! /bin/sh /usr/share/dpatch/dpatch-run
190 ## 05_pedantic.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
192 ## All lines beginning with `## DP:' are a description of the patch.
193 ## DP: changes to make clean up compilation
196 diff -urNad redir-2.2.1~/Makefile redir-2.2.1/Makefile
197 --- redir-2.2.1~/Makefile 2005-10-22 23:11:41.000000000 -0400
198 +++ redir-2.2.1/Makefile 2005-10-22 23:11:48.818368360 -0400
200 # if your system lacks getopt_long, remove the comment from this line
201 OBJS = redir.o $(GETOPT_OBJS)
203 -CFLAGS = -O2 -Wall $(STR_CFLAGS) $(WRAP_CFLAGS) $(EXTRA_CFLAGS)
204 +CFLAGS = -O2 -Wall --pedantic $(STR_CFLAGS) $(WRAP_CFLAGS) $(EXTRA_CFLAGS)
207 # solaris, and others, may also need these libraries to link
208 diff -urNad redir-2.2.1~/redir.c redir-2.2.1/redir.c
209 --- redir-2.2.1~/redir.c 2005-10-22 23:11:48.282449832 -0400
210 +++ redir-2.2.1/redir.c 2005-10-22 23:12:23.201141384 -0400
212 #include <sys/types.h>
213 #include <sys/socket.h>
214 #include <sys/time.h>
216 #include <sys/wait.h>
217 #include <netinet/in.h>
218 #include <arpa/inet.h>
223 - int socksize = sizeof(struct sockaddr_in);
224 + size_t socksize = sizeof(struct sockaddr_in);
226 struct sockaddr_in newsession;
227 struct sockaddr_in sockname;
229 if(getsockname(localsock, (struct sockaddr *)&sockname, &socksize) < 0) {
230 perror("getsockname");
232 - syslog(LOG_ERR, "getsockname failed: %m");
233 + syslog(LOG_ERR, "getsockname failed: %s",strerror(errno));
241 - syslog(LOG_ERR, "Couldn't fork: %m");
242 + syslog(LOG_ERR, "Couldn't fork: %s",strerror(errno));
249 struct sockaddr_in client;
250 - int clientlen = sizeof(client);
251 + size_t clientlen = sizeof(client);
254 debug("top of accept loop\n");
256 perror("server: accept");
259 - syslog(LOG_ERR, "accept failed: %m");
260 + syslog(LOG_ERR, "accept failed: %s",strerror(errno));
262 /* determine if this error is fatal */
263 switch(accept_errno) {
265 perror("(server) fork");
268 - syslog(LOG_ERR, "(server) fork failed: %m");
269 + syslog(LOG_ERR, "(server) fork failed: %s",strerror(errno));
274 perror("(child) fork");
277 - syslog(LOG_ERR, "(child) fork failed: %m");
278 + syslog(LOG_ERR, "(child) fork failed: %s",strerror(errno));
283 perror("target: socket");
286 - syslog(LOG_ERR, "socket failed: %m");
287 + syslog(LOG_ERR, "socket failed: %s",strerror(errno));
292 only be different if the input value is 0 (let the system pick a
295 - syslog(LOG_ERR, "bind failed: %m");
296 + syslog(LOG_ERR, "bind failed: %s",strerror(errno));
301 perror("target: connect");
304 - syslog(LOG_ERR, "bind failed: %m");
305 + syslog(LOG_ERR, "bind failed: %s",strerror(errno));
310 perror("server: socket");
313 - syslog(LOG_ERR, "socket failed: %m");
314 + syslog(LOG_ERR, "socket failed: %s",strerror(errno));
319 perror("server: bind");
322 - syslog(LOG_ERR, "bind failed: %m");
323 + syslog(LOG_ERR, "bind failed: %s",strerror(errno));
328 perror("server: listen");
331 - syslog(LOG_ERR, "listen failed: %m");
332 + syslog(LOG_ERR, "listen failed: %s",strerror(errno));
336 @@ -1059,7 +1060,7 @@
339 struct sockaddr_in client;
340 - int client_size = sizeof(client);
341 + size_t client_size = sizeof(client);
343 #ifdef USE_TCP_WRAPPERS
344 request_init(&request, RQ_DAEMON, ident, RQ_FILE, 0, 0);
345 @@ -1079,7 +1080,7 @@
346 perror("target: socket");
349 - syslog(LOG_ERR, "targetsock failed: %m");
350 + syslog(LOG_ERR, "targetsock failed: %s",strerror(errno));
354 @@ -1097,7 +1098,7 @@
355 perror("bind_addr: cannot bind to forcerd outgoing addr");
358 - syslog(LOG_ERR, "bind failed: %m");
359 + syslog(LOG_ERR, "bind failed: %s",strerror(errno));
363 @@ -1109,7 +1110,7 @@
364 perror("target: connect");
367 - syslog(LOG_ERR, "connect failed: %m");
368 + syslog(LOG_ERR, "connect failed: %s",strerror(errno));
372 #! /bin/sh /usr/share/dpatch/dpatch-run
373 ## 06_fix_shaper_buffer.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
375 ## All lines beginning with `## DP:' are a description of the patch.
376 ## DP: properly allocate copyloop buffer
379 diff -urNad redir-2.2.1~/redir.c redir-2.2.1/redir.c
380 --- redir-2.2.1~/redir.c 2005-10-22 23:20:05.235901424 -0400
381 +++ redir-2.2.1/redir.c 2005-10-22 23:22:20.198384008 -0400
386 - unsigned int * bufsize,
387 + unsigned int * bufsizeout,
395 - *bufsize = (unsigned int)atol(optarg);
396 + *bufsizeout = (unsigned int)atol(optarg);
401 unsigned long bytes_in = 0;
402 unsigned long bytes_out = 0;
403 unsigned int start_time, end_time;
405 + char* buf = malloc(bufsize);
407 /* Record start time */
408 start_time = (unsigned int) time(NULL);
412 if(FD_ISSET(insock, &c_iofds)) {
413 - if((bytes = read(insock, buf, sizeof(buf))) <= 0)
414 + if((bytes = read(insock, buf, bufsize)) <= 0)
421 if(FD_ISSET(outsock, &c_iofds)) {
422 - if((bytes = read(outsock, buf, sizeof(buf))) <= 0)
423 + if((bytes = read(outsock, buf, bufsize)) <= 0)
425 /* if we're correcting for PASV on ftp redirections, then
426 fix buf and bytes to have the new address, among other
428 syslog(LOG_NOTICE, "disconnect %d secs, %ld in %ld out",
429 (end_time - start_time), bytes_in, bytes_out);
435 #! /bin/sh /usr/share/dpatch/dpatch-run
436 ## 07_cosmetics.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
438 ## All lines beginning with `## DP:' are a description of the patch.
439 ## DP: Cosmetic fixes which could be applied upstream
442 diff -urNad redir-2.2.1~/redir.man redir-2.2.1/redir.man
443 --- redir-2.2.1~/redir.man 2005-10-22 21:41:51.284918168 -0400
444 +++ redir-2.2.1/redir.man 2005-10-22 21:42:42.115190792 -0400
446 Specify program name to be used for TCP wrapper checks and syslog logging.
449 -Timeout and close the connection after n seconds on inactivity.
450 +Timeout and close the connection after n seconds of inactivity.
453 Log information to syslog.
458 -On a linux system with transparany proxying enables, causes redir to
459 +On a linux system with transparent proxying enabled, causes redir to
460 make connections appear as if they had come from their true origin.
461 (see transproxy.txt in the source archive)
463 #! /bin/sh /usr/share/dpatch/dpatch-run
464 ## 08_add_wrappers.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
466 ## All lines beginning with `## DP:' are a description of the patch.
467 ## DP: Enabling TCP wrapper support
471 --- redir-2.2.1.orig/Makefile
472 +++ redir-2.2.1/Makefile
474 # if you would like support for TCP wrappers (and have libwrap.a
475 # installed), remove these comments.
477 -WRAP_CFLAGS = # -DUSE_TCP_WRAPPERS
478 -WRAP_LIBS = # -lwrap
479 +WRAP_CFLAGS = -DUSE_TCP_WRAPPERS
482 # if your system needs any additional libraries (solaris, for example,
483 # needs the ones commented out below), edit this line.
485 #! /bin/sh /usr/share/dpatch/dpatch-run
486 ## 09_add_linux_software_map.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
488 ## All lines beginning with `## DP:' are a description of the patch.
489 ## DP: Add linux software map file
493 --- redir-2.2.1.orig/redir-2.2.lsm
494 +++ redir-2.2.1/redir-2.2.lsm
499 +Entered-date: 15DEC1999
500 +Description: TCP Port redirector (for firewalls etc).
501 +Keywords: tcp port redirector bouncer proxy
502 +Author: sammy@oh.verio.com
503 +Primary-site: sunsite.unc.edu /pub/Linux/system/Network/daemons
504 + 39936 redir-2.2.tar.gz
508 #! /bin/sh /usr/share/dpatch/dpatch-run
509 ## 15_deb_cosmetics.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
511 ## All lines beginning with `## DP:' are a description of the patch.
512 ## DP: Cosmetic changes applicable only to debian
515 diff -urNad redir-2.2.1~/redir.man redir-2.2.1/redir.man
516 --- redir-2.2.1~/redir.man 2005-10-22 21:47:44.067287096 -0400
517 +++ redir-2.2.1/redir.man 2005-10-22 21:48:34.218662928 -0400
520 On a linux system with transparent proxying enabled, causes redir to
521 make connections appear as if they had come from their true origin.
522 -(see transproxy.txt in the source archive)
523 +(see /usr/share/doc/redir/transproxy.txt)
526 Redirects connections through an HTTP proxy which supports the CONNECT
527 #! /bin/sh /usr/share/dpatch/dpatch-run
528 ## 20_do_not_strip.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
530 ## All lines beginning with `## DP:' are a description of the patch.
531 ## DP: don't strip by default. let dh_strip take care of it.
534 diff -urNad redir-2.2.1~/Makefile redir-2.2.1/Makefile
535 --- redir-2.2.1~/Makefile 2007-08-15 14:53:41.908911693 -0400
536 +++ redir-2.2.1/Makefile 2007-08-15 14:53:59.409909018 -0400
538 OBJS = redir.o $(GETOPT_OBJS)
540 CFLAGS = -O2 -Wall --pedantic $(STR_CFLAGS) $(WRAP_CFLAGS) $(EXTRA_CFLAGS)
544 # solaris, and others, may also need these libraries to link
545 # also edit here if you're using the TCP wrappers code
546 #! /bin/sh /usr/share/dpatch/dpatch-run
547 ## 25_fix_setsockopt.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
549 ## All lines beginning with `## DP:' are a description of the patch.
550 ## DP: Ensure that the server socket has SO_REUSEADDR and SO_LINGER set properly.
553 diff -urNad redir~/redir.c redir/redir.c
554 --- redir~/redir.c 2009-03-03 17:35:12.022427586 -0500
555 +++ redir/redir.c 2009-03-03 17:45:28.998426896 -0500
557 /* let's set up some globals... */
560 -unsigned char reuse_addr = 1;
561 -unsigned char linger_opt = 0;
562 +int reuse_addr = 1; /* allow address reuse */
563 +struct linger linger_opt = { 0, 0}; /* do not linger */
564 char * bind_addr = NULL;
565 struct sockaddr_in addr_out;
570 struct sockaddr_in server;
574 * Get a socket to work with. This socket will
576 server.sin_addr.s_addr = htonl(inet_addr("0.0.0.0"));
579 - setsockopt(servsock, SOL_SOCKET, SO_REUSEADDR, &reuse_addr, sizeof(reuse_addr));
580 - setsockopt(servsock, SOL_SOCKET, SO_LINGER, &linger_opt, sizeof(SO_LINGER));
581 + ret = setsockopt(servsock, SOL_SOCKET, SO_REUSEADDR, &reuse_addr, sizeof(reuse_addr));
587 + perror("server: setsockopt (SO_REUSEADDR)");
589 + syslog(LOG_ERR, "setsockopt failed with SO_REUSEADDR: %s",strerror(errno));
593 + ret = setsockopt(servsock, SOL_SOCKET, SO_LINGER, &linger_opt, sizeof(linger_opt));
599 + perror("server: setsockopt (SO_LINGER)");
601 + syslog(LOG_ERR, "setsockopt failed with SO_LINGER: %s",strerror(errno));
607 * Try to bind the address to the socket.
608 #! /bin/sh /usr/share/dpatch/dpatch-run
609 ## 30_fix_manpage.dpatch by Daniel Kahn Gillmor <dkg@fifthhorseman.net>
611 ## All lines beginning with `## DP:' are a description of the patch.
612 ## DP: Clean up questionable formatting in man page.
615 diff -urNad redir~/redir.man redir/redir.man
616 --- redir~/redir.man 2009-03-03 18:55:37.790428922 -0500
617 +++ redir/redir.man 2009-03-03 18:58:48.486428715 -0500
622 -redir \- redirect tcp connections
623 +redir - redirect tcp connections
627 -.RB [ \--laddr=incoming.ip.address ]
628 -.RB [ \--caddr=host ]
632 -.RB [ \--timeout=n ]
633 -.RB [ \--bind_addr=my.other.ip.address ]
635 -.RB [ \--transproxy ]
636 -.RB [ \--connect=host:port ]
639 -.RB [ \--bufsize=n ]
640 -.RB [ \--max_bandwidth=n ]
641 -.RB [ \--random_wait=n ]
642 -.RB [ \--wait_in_out=n ]
643 +.RB [ \-\-laddr=incoming.ip.address ]
644 +.RB [ \-\-caddr=host ]
647 +.RB [ \-\-name=str ]
648 +.RB [ \-\-timeout=n ]
649 +.RB [ \-\-bind_addr=my.other.ip.address ]
650 +.RB [ \-\-ftp=type ]
651 +.RB [ \-\-transproxy ]
652 +.RB [ \-\-connect=host:port ]
655 +.RB [ \-\-bufsize=n ]
656 +.RB [ \-\-max_bandwidth=n ]
657 +.RB [ \-\-random_wait=n ]
658 +.RB [ \-\-wait_in_out=n ]
663 -.RB [ \--caddr=host ]
667 -.RB [ \--timeout=n ]
669 -.RB [ \--transproxy ]
670 -.RB [ \--connect=host:port ]
672 -.RB [ \--bufsize=n ]
673 -.RB [ \--max_bandwidth=n ]
674 -.RB [ \--random_wait=n ]
675 -.RB [ \--wait_in_out=n ]
677 +.RB [ \-\-caddr=host ]
680 +.RB [ \-\-name=str ]
681 +.RB [ \-\-timeout=n ]
682 +.RB [ \-\-ftp=type ]
683 +.RB [ \-\-transproxy ]
684 +.RB [ \-\-connect=host:port ]
686 +.RB [ \-\-bufsize=n ]
687 +.RB [ \-\-max_bandwidth=n ]
688 +.RB [ \-\-random_wait=n ]
689 +.RB [ \-\-wait_in_out=n ]
694 Depending on how redir was compiled, not all options may be available.
699 Specifies port to listen for connections on (when not running from inetd)
703 IP address to bind to when listening for connections (when not
708 Specifies port to connect to.
712 Specifies remote host to connect to. (localhost if omitted)
716 Run as a process started from inetd, with the connection passed as stdin
717 and stdout on startup.
721 Write debug output to stderr or syslog.
725 Specify program name to be used for TCP wrapper checks and syslog logging.
729 Timeout and close the connection after n seconds of inactivity.
733 Log information to syslog.
737 Forces redir to pick a specific address/interface to bind to when it listens
738 for incoming connections.
742 When using redir for an FTP server, this will cause redir to also
743 redirect ftp connections. Type should be specified as either "port",
744 "pasv", or "both", to specify what type of FTP connection to handle.
745 -Note that --transproxy often makes one or the other (generally port)
746 +Note that \-\-transproxy often makes one or the other (generally port)
751 On a linux system with transparent proxying enabled, causes redir to
752 make connections appear as if they had come from their true origin.
753 (see /usr/share/doc/redir/transproxy.txt)
757 Redirects connections through an HTTP proxy which supports the CONNECT
758 -command. Specify the address and port of the proxy using --caddr and
759 ---cport. --connect requires the hostname and port which the HTTP
760 +command. Specify the address and port of the proxy using \-\-caddr and
761 +\-\-cport. \-\-connect requires the hostname and port which the HTTP
762 proxy will be asked to connect to.
766 Set the bufsize (defaut 4096) in bytes. Can be used combined with
767 ---max_bandwidth or --random_wait to simulate a slow connection.
768 +\-\-max_bandwidth or \-\-random_wait to simulate a slow connection.
770 -.B \--max_bandwidth n
771 +.B \-\-max_bandwidth n
772 Reduce the bandwidth to be no more than n bits/sec. The algorithme is
773 basic, the goal is to simulate a slow connection, so there is no pic
777 +.B \-\-random_wait n
778 Wait between 0 and 2 x n milliseconds before each "packet". A "packet" is
779 a bloc of data read in one time by redir. A "packet" size is always less
780 -than the bufsize (see also --bufsize).
781 +than the bufsize (see also \-\-bufsize).
784 -Apply --max_bandwidth and --random_wait for input if n=1, output if n=2 and
785 +.B \-\-wait_in_out n
786 +Apply \-\-max_bandwidth and \-\-random_wait for input if n=1, output if n=2 and