From 1ee688edbe5549e11e248ea8549ea1014c599aed Mon Sep 17 00:00:00 2001 From: Stephane Bortzmeyer Date: Wed, 7 Mar 2007 15:16:58 +0000 Subject: [PATCH] #1350714: Removes T/TCP (see RFC 4614 to know why) --- SRC/DETAILS | 3 +-- SRC/INSTALL | 3 --- SRC/README | 1 - SRC/TODO | 3 --- SRC/configure.ac | 30 +----------------------------- SRC/echoping.1.in | 3 --- SRC/echoping.c | 37 ++----------------------------------- SRC/echoping.h | 3 --- Web/details.wml | 3 +-- Web/index.wml | 1 - 10 files changed, 5 insertions(+), 82 deletions(-) diff --git a/SRC/DETAILS b/SRC/DETAILS index 871c867..b18f232 100644 --- a/SRC/DETAILS +++ b/SRC/DETAILS @@ -56,8 +56,7 @@ Unix: - ping, probably available with your system - traceroute, idem (otherwise, see ) - ttcp, the best measurement tool but it needs some control over the - two machines (nothing to do with - the T/TCP protocol) + two machines - Netpipe, it needs some control over the two machines - treno (evaluates available bandwidth for TCP) diff --git a/SRC/INSTALL b/SRC/INSTALL index 4f5367f..af8bdd3 100644 --- a/SRC/INSTALL +++ b/SRC/INSTALL @@ -25,9 +25,6 @@ may not be available on your platform). the GNU TLS library ) --with-ssl[=/where/is/ssl] (add the SSL/TLS support, you will need the OpenSSL library ) ---disable-ttcp (suppress the T/TCP support which is enabled only if - your system supports it - FreeBSD does. See - ) --enable-max-iterations=MAX (limit the number of iterations (-n option for repeated tests) to MAX) --enable-max-request-size=MAX (limit the size of the request (-s option) to MAX) diff --git a/SRC/README b/SRC/README index c4d776e..da0ab91 100644 --- a/SRC/README +++ b/SRC/README @@ -27,7 +27,6 @@ Current features: - supports IPv6 as well as IPv4, - supports IDN (Unicode domain names), - supports plugins written by you, to test even more protocols (see PLUGINS), -- can use T/TCP on systems which support it. Examples of output: diff --git a/SRC/TODO b/SRC/TODO index 0674266..6433b60 100644 --- a/SRC/TODO +++ b/SRC/TODO @@ -18,9 +18,6 @@ Wishes: Display other calculations such as kurtosis. -Check the TCP timeout with T/TCP. Difficult to test, few T/TCP -machines exist. Timeouts on T/TCP connections are a bit experimental. - TCP timeout with long packets seem to confuse Cisco routers. Does someone can reproduce it and perform tests? It seems to work now. diff --git a/SRC/configure.ac b/SRC/configure.ac index d47622c..93fe94f 100644 --- a/SRC/configure.ac +++ b/SRC/configure.ac @@ -119,7 +119,6 @@ AC_ARG_WITH(popt, fi], dnl Default: disable it ) -dnl See T/TCP later dnl Checks for programs. AC_PROG_CC @@ -188,37 +187,11 @@ if test "$GNUTLS" = "1"; then CF_LIB_GNUTLS fi -dnl T/TCP -AC_MSG_CHECKING([T/TCP]) -AC_TRY_COMPILE( - [#include - #include - ], - [int foobar = MSG_EOF;], - [AC_DEFINE(TTCP,,[Transaction TCP support]) - ac_have_ttcp="yes"], - ac_have_ttcp=no) -AC_MSG_RESULT($ac_have_ttcp) -AC_ARG_ENABLE(ttcp, - [ --enable-ttcp T/TCP (Transaction TCP) support], - [if test "$enableval" = "yes"; then - if test $ac_have_ttcp = "yes"; then - AC_DEFINE(TTCP,,[Transaction TCP support]) - TTCP=1 - else - AC_MSG_WARN([No T/TCP support on this system, request ignored]) - fi - fi], - dnl Default: enable it if supported - if test $ac_have_ttcp = "yes"; then - AC_DEFINE(TTCP,,[Transaction TCP support]) - TTCP=1 - fi) - AC_MSG_CHECKING([TCP info from socket]) AC_TRY_COMPILE( [#include #include + /* TODO: including tcp.h may not be necessary */ #include ], [int foobar = SOL_TCP;], @@ -353,7 +326,6 @@ DISPLAY_SETTING(OPENSSL) DISPLAY_SETTING(GNUTLS) DISPLAY_SETTING(SMTP) DISPLAY_SETTING(LIBIDN) -DISPLAY_SETTING(TTCP) DISPLAY_SETTING(TOS) DISPLAY_SETTING(PRIORITY) diff --git a/SRC/echoping.1.in b/SRC/echoping.1.in index 1a3053d..e6d2a53 100644 --- a/SRC/echoping.1.in +++ b/SRC/echoping.1.in @@ -9,7 +9,6 @@ echoping \- tests a remote host with TCP or UDP .RI [-6] .RI [-v] .RI [-V] -.RI [-r] .RI [-f fill] .RI [-t timeout] .RI [-c] @@ -106,8 +105,6 @@ Force the proxy (if you use one) to revalidate data with the original server Use the SSL/TLS (cryptography) protocol. For HTTP tests only. .IP -S Use the SMTP protocol (instead of echo) for the given server. -.IP -r -Use T/TCP (if it has been compiled with it). See the INSTALL file for details. .IP -4 Use only IPv4 (even if the target machine has an IPv6 address) .IP -6 diff --git a/SRC/echoping.c b/SRC/echoping.c index d8c0c34..3a1bb71 100644 --- a/SRC/echoping.c +++ b/SRC/echoping.c @@ -119,7 +119,6 @@ main(argc, argv) icp_opcode opcode = ICP_OP_QUERY; #endif - boolean ttcp = 0; boolean tcp = 0; boolean ssl = 0; @@ -174,8 +173,6 @@ main(argc, argv) "Hostname to use in HTTP Host: header"}, {"icp", 'i', POPT_ARG_STRING, &url, 'i', "ICP protocol, for Web proxies/caches"}, - {"ttcp", 'r', POPT_ARG_NONE, &ttcp, 'r', - "Use the T/TCP protocol (Transaction TCP)"}, {"udp", 'u', POPT_ARG_NONE, &udp, 'u'}, {"timeout", 't', POPT_ARG_INT, &timeout, 't'}, {"fill", 'f', POPT_ARG_STRING, &fill_s, 'f'}, @@ -196,7 +193,6 @@ main(argc, argv) poptContext poptcon; global_options.udp = FALSE; - global_options.ttcp = FALSE; global_options.verbose = FALSE; null_timeval.tv_sec = 0; @@ -386,13 +382,6 @@ main(argc, argv) progname); exit(1); } -#ifndef USE_TTCP - if (ttcp) { - (void) fprintf(stderr, - "%s: not compiled with T/TCP support.\n", progname); - exit(1); - } -#endif #if ! (defined(OPENSSL) || defined(GNUTLS)) if (ssl) { (void) fprintf(stderr, @@ -433,11 +422,6 @@ main(argc, argv) progname); exit(1); } - if (udp && ttcp) { - (void) fprintf(stderr, "%s: UDP and T/TCP are incompatible.\n", - progname); - exit(1); - } if (ssl && http) { strcpy(port_name, DEFAULT_HTTPS_TCP_PORT); } @@ -495,7 +479,6 @@ main(argc, argv) dlerror()); } global_options.udp = udp; - global_options.ttcp = ttcp; global_options.verbose = verbose; if (family == AF_INET) global_options.only_ipv4 = 1; @@ -535,9 +518,6 @@ main(argc, argv) dlerror()); } } - if (!udp && !ttcp) { - tcp = 1; - } if (remaining == 0) { (void) fprintf(stderr, "No host name indicated\n"); usage(poptcon); @@ -928,7 +908,7 @@ main(argc, argv) if (plugin_result == -2) err_quit(""); } else { - if (!ttcp && !icp) { + if (!icp) { /* * Connect to the server. */ @@ -1039,25 +1019,12 @@ main(argc, argv) */ } #endif - } - /* Not T/TCP */ - else { + } else { /* No initial connection */ } if ((port_to_use == USE_ECHO) || (port_to_use == USE_DISCARD) || (port_to_use == USE_HTTP) || (port_to_use == USE_ICP) || (port_to_use == USE_SMTP)) { -#ifdef USE_TTCP - if (ttcp) { - if (sendto(sockfd, sendline, n, MSG_EOF, - res->ai_addr, - res->ai_addrlen) != n) - err_sys("sendto error on socket"); - if (verbose) { - printf("T/TCP connection done\n"); - } - } else -#endif if (!udp) { if (!ssl) { /* diff --git a/SRC/echoping.h b/SRC/echoping.h index a644736..0ff4f1c 100644 --- a/SRC/echoping.h +++ b/SRC/echoping.h @@ -89,9 +89,6 @@ extern int sys_nerr; #ifdef HAVE_SIGACTION #define USE_SIGACTION 1 #endif -#ifdef HAVE_TTCP -#define USE_TTCP 1 -#endif #ifdef HAVE_TOS #define USE_TOS 1 #endif diff --git a/Web/details.wml b/Web/details.wml index 8706922..5e5292c 100644 --- a/Web/details.wml +++ b/Web/details.wml @@ -52,8 +52,7 @@ SunOS need time to recover :-)
  • ping, probably available with your system
  • traceroute, idem (otherwise, see LBL)
  • ttcp, the best measurement tool but it needs some control over the - two machines (nothing to do with - the T/TCP protocol) + two machines
  • Netpipe, it needs some control over the two machines
  • treno (evaluates available bandwidth for TCP)
  • spray is a tool which I dont't know very well. It is available on some diff --git a/Web/index.wml b/Web/index.wml index bd32733..709e5dc 100644 --- a/Web/index.wml +++ b/Web/index.wml @@ -47,7 +47,6 @@ test hosts which aren't yours.
  • can use cryptographic connections with HTTP,
  • uses UDP instead of TCP for the protocols which accept it (like echo),
  • can repeat the test and display various measures about it, -
  • can use T/TCP on systems which support it.

    Known bugs