From 81a01b0f2bef50eb04b8620f276401648e00b793 Mon Sep 17 00:00:00 2001 From: Mark Janssen Date: Mon, 16 Jan 2006 15:51:04 +0000 Subject: [PATCH] HP-Nonstop/Tandem compile fix Workaround for broken proxies git-svn-id: https://proxytunnel.svn.sourceforge.net/svnroot/proxytunnel/trunk/proxytunnel@84 bc163920-b10d-0410-b2c5-a5491ca2ceef --- CHANGES | 2 ++ Makefile | 2 +- cmdline.c | 2 ++ config.h | 2 +- debian/changelog | 7 +++++++ debian/proxytunnel.substvars | 2 +- http.c | 8 ++++++++ 7 files changed, 22 insertions(+), 3 deletions(-) diff --git a/CHANGES b/CHANGES index bd4e849..8c6630f 100755 --- a/CHANGES +++ b/CHANGES @@ -1,6 +1,8 @@ Changes to proxytunnel version 1.5.x -- not yet released - Small change to make compiler on tandem/hp-nonstop happy + by Roberto Veldhoven +- Small change to work around broken proxies by Stephane Engel Changes to proxytunnel version 1.5.2 -- Fri Dec 16 09:27:11 CET 2005 diff --git a/Makefile b/Makefile index 7c0eb9c..adade9c 100755 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ # Please uncomment the appropriate settings CC = gcc -CFLAGS = -Wall -DHAVE_GETOPT_LONG +CFLAGS = -Wall -DHAVE_GETOPT_LONG -DWITH_NTLM LDFLAGS = -lssl INSTALLPATH = $(DESTDIR)/usr/local/bin MANPATH = $(DESTDIR)/usr/man/man1 diff --git a/cmdline.c b/cmdline.c index 8f62eb9..d0e94dd 100755 --- a/cmdline.c +++ b/cmdline.c @@ -66,8 +66,10 @@ cmdline_parser_print_help (void) " -s STRING --pass=STRING Password to send to HTTPS proxy for auth\n" " -U STRING --uservar=STRING Env var with Username for HTTPS proxy auth\n" " -S STRING --passvar=STRING Env var with Password for HTTPS proxy auth\n" +#ifdef WITH_NTLM " -N --ntlm Use NTLM Based Authentication\n" " -t STRING --domain=STRING NTLM Domain (default: autodetect)\n" +#endif " -H STRING --header=STRING Add STRING to HTTP headers sent to proxy\n\n" " If you don't provide -s or -S you will be prompted for a password.\n" "\nMiscellaneous options:\n" diff --git a/config.h b/config.h index 152ba3b..7b66d7f 100755 --- a/config.h +++ b/config.h @@ -17,7 +17,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#define VERSION "1.5.1" +#define VERSION "1.5.2" #define PACKAGE "Proxytunnel" #define PURPOSE "Build generic tunnels through HTTPS proxies" #define AUTHORS "Jos Visser (Muppet) , Mark Janssen (Maniac) " diff --git a/debian/changelog b/debian/changelog index 6ec8d33..decbd14 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +proxytunnel (1.5.2-1) unstable; urgency=high + + * New version + * NTLM Cleanups, removed md[45] code in favour of using libssl + + -- Mark Janssen Fri, 16 Dec 2005 10:00:00 +0200 + proxytunnel (1.5.0-1) unstable; urgency=high * New version diff --git a/debian/proxytunnel.substvars b/debian/proxytunnel.substvars index b7d6055..a5542a1 100644 --- a/debian/proxytunnel.substvars +++ b/debian/proxytunnel.substvars @@ -1 +1 @@ -shlibs:Depends=libc6 (>= 2.3.2.ds1-4) +shlibs:Depends=libc6 (>= 2.3.4-1), libssl0.9.7 diff --git a/http.c b/http.c index 3cacc49..3e6d83c 100644 --- a/http.c +++ b/http.c @@ -39,6 +39,14 @@ void analyze_HTTP() { char *p = strtok( buf, " "); + /* + * Strip html error pages for faulty proxies + * by: Stephane Engel + */ + while (strncmp( p, "HTTP/", 5) != 0 ) + { + readline(); p = strtok( buf, " "); } + if (strcmp( p, "HTTP/1.0" ) != 0 && strcmp( p, "HTTP/1.1" ) != 0) { message( "Unsupported HTTP version number %s\n", p );