From: robertc <> Date: Sun, 3 Aug 2003 14:09:00 +0000 (+0000) Subject: Various patches from Pawel Worach X-Git-Tag: SQUID_3_0_PRE3~50 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7928e47555c8dcac776930baf8ceb9fbc709b9d6;p=thirdparty%2Fsquid.git Various patches from Pawel Worach [patch] make trans. ipfilter compile one else too many? [patch] update .cvsignore files Make all .cvsignore files up-to-date and add some new ones to libTrie. [patch] make ntlm_auth compile on freebsd 5.x I have no idea how portable this is but freebsd doesn't use malloc.h anymore. # grep error /usr/include/malloc.h #error " has been replaced by " [patch] make auth_ntlm compile if NTLM_FAIL_OPEN is defined ntlm/auth_ntlm.cc: In function `stateful_helper_callback_t authenticateNTLMHandleReply(void*, void*, char*)': ntlm/auth_ntlm.cc:601: error: invalid conversion from `void*' to ` ntlm_helper_state_t*' [patch] make useragent and referer log stuff compile Can't use class RefCount where a bool is expected says gcc 3.3.1 I guess this is the right fix :) [patch] pam_auth has to be installed setuid root pam_auth has to be setuid root for it to work. this could apply to 2.5 too. --- diff --git a/.cvsignore b/.cvsignore index cdfff08ace..ce401912e5 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1,4 +1,3 @@ Makefile config.* autom4te* -makefile diff --git a/helpers/.cvsignore b/helpers/.cvsignore index 7bda5c8c88..f3c7a7c5da 100644 --- a/helpers/.cvsignore +++ b/helpers/.cvsignore @@ -1,2 +1 @@ -.cvsignore Makefile diff --git a/helpers/basic_auth/LDAP/.cvsignore b/helpers/basic_auth/LDAP/.cvsignore index 63f8570f9f..3ecf279f01 100644 --- a/helpers/basic_auth/LDAP/.cvsignore +++ b/helpers/basic_auth/LDAP/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +squid_ldap_auth diff --git a/helpers/basic_auth/MSNT/.cvsignore b/helpers/basic_auth/MSNT/.cvsignore index 63f8570f9f..b6e9dda390 100644 --- a/helpers/basic_auth/MSNT/.cvsignore +++ b/helpers/basic_auth/MSNT/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +msnt_auth diff --git a/helpers/basic_auth/NCSA/.cvsignore b/helpers/basic_auth/NCSA/.cvsignore index 63f8570f9f..d224ea88e5 100644 --- a/helpers/basic_auth/NCSA/.cvsignore +++ b/helpers/basic_auth/NCSA/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +ncsa_auth diff --git a/helpers/basic_auth/PAM/.cvsignore b/helpers/basic_auth/PAM/.cvsignore index 63f8570f9f..29e2d7b160 100644 --- a/helpers/basic_auth/PAM/.cvsignore +++ b/helpers/basic_auth/PAM/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +pam_auth diff --git a/helpers/basic_auth/PAM/Makefile.am b/helpers/basic_auth/PAM/Makefile.am index 1578cadd88..d8bf599fe8 100644 --- a/helpers/basic_auth/PAM/Makefile.am +++ b/helpers/basic_auth/PAM/Makefile.am @@ -1,7 +1,7 @@ # # Makefile for the Squid PAM authentication helper # -# $Id: Makefile.am,v 1.5 2003/01/23 00:35:35 robertc Exp $ +# $Id: Makefile.am,v 1.6 2003/08/03 08:09:07 robertc Exp $ # # Uncomment and customize the following to suit your needs: # @@ -12,3 +12,7 @@ man_MANS = pam_auth.8 EXTRA_DIST = pam_auth.8 libexec_PROGRAMS = pam_auth LDADD = -L$(top_builddir)/lib -lmiscutil -lpam $(XTRA_LIBS) + +install-exec-hook: + chown root $(libexecdir)/pam_auth || true + chmod u+s $(libexecdir)/pam_auth || true diff --git a/helpers/basic_auth/PAM/Makefile.in b/helpers/basic_auth/PAM/Makefile.in index 6873bf3c4a..dd25c783cf 100644 --- a/helpers/basic_auth/PAM/Makefile.in +++ b/helpers/basic_auth/PAM/Makefile.in @@ -17,7 +17,7 @@ # # Makefile for the Squid PAM authentication helper # -# $Id: Makefile.in,v 1.44 2003/07/23 00:13:44 hno Exp $ +# $Id: Makefile.in,v 1.45 2003/08/03 08:09:07 robertc Exp $ # # Uncomment and customize the following to suit your needs: # @@ -499,6 +499,8 @@ info-am: install-data-am: install-man install-exec-am: install-libexecPROGRAMS + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-info: install-info-am @@ -538,6 +540,10 @@ uninstall-man: uninstall-man8 ps ps-am tags uninstall uninstall-am uninstall-info-am \ uninstall-libexecPROGRAMS uninstall-man uninstall-man8 + +install-exec-hook: + chown root $(libexecdir)/pam_auth || true + chmod u+s $(libexecdir)/pam_auth || true # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/helpers/basic_auth/SMB/.cvsignore b/helpers/basic_auth/SMB/.cvsignore index 63f8570f9f..09593ba8da 100644 --- a/helpers/basic_auth/SMB/.cvsignore +++ b/helpers/basic_auth/SMB/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +smb_auth diff --git a/helpers/basic_auth/getpwnam/.cvsignore b/helpers/basic_auth/getpwnam/.cvsignore index 63f8570f9f..13ebf81cb3 100644 --- a/helpers/basic_auth/getpwnam/.cvsignore +++ b/helpers/basic_auth/getpwnam/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +getpwname_auth diff --git a/helpers/basic_auth/winbind/.cvsignore b/helpers/basic_auth/winbind/.cvsignore index 63f8570f9f..59dafef00f 100644 --- a/helpers/basic_auth/winbind/.cvsignore +++ b/helpers/basic_auth/winbind/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +wb_auth diff --git a/helpers/digest_auth/password/.cvsignore b/helpers/digest_auth/password/.cvsignore index 63f8570f9f..50106a2acc 100644 --- a/helpers/digest_auth/password/.cvsignore +++ b/helpers/digest_auth/password/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +digest_pw_auth diff --git a/helpers/ntlm_auth/SMB/.cvsignore b/helpers/ntlm_auth/SMB/.cvsignore index 63f8570f9f..26c24fc146 100644 --- a/helpers/ntlm_auth/SMB/.cvsignore +++ b/helpers/ntlm_auth/SMB/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +ntlm_auth diff --git a/helpers/ntlm_auth/SMB/smbval/rfcnb-util.c b/helpers/ntlm_auth/SMB/smbval/rfcnb-util.c index 5df94e37fe..a293dab9dd 100644 --- a/helpers/ntlm_auth/SMB/smbval/rfcnb-util.c +++ b/helpers/ntlm_auth/SMB/smbval/rfcnb-util.c @@ -24,7 +24,7 @@ */ #include -#include +#include #include "std-includes.h" #include "rfcnb-priv.h" diff --git a/helpers/ntlm_auth/SMB/smbval/session.c b/helpers/ntlm_auth/SMB/smbval/session.c index f646ecdb11..361a8f886a 100644 --- a/helpers/ntlm_auth/SMB/smbval/session.c +++ b/helpers/ntlm_auth/SMB/smbval/session.c @@ -23,7 +23,6 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -#include #include #include diff --git a/helpers/ntlm_auth/SMB/smbval/smblib-util.c b/helpers/ntlm_auth/SMB/smbval/smblib-util.c index ffb1fccb8e..5c5ea7f8c7 100644 --- a/helpers/ntlm_auth/SMB/smbval/smblib-util.c +++ b/helpers/ntlm_auth/SMB/smbval/smblib-util.c @@ -24,7 +24,7 @@ */ #include "smblib-priv.h" -#include +#include #include #include "rfcnb.h" diff --git a/helpers/ntlm_auth/SMB/smbval/smblib.c b/helpers/ntlm_auth/SMB/smbval/smblib.c index 996141bdcd..0e71e5db97 100644 --- a/helpers/ntlm_auth/SMB/smbval/smblib.c +++ b/helpers/ntlm_auth/SMB/smbval/smblib.c @@ -25,7 +25,7 @@ */ #include "config.h" -#include +#include #include #include diff --git a/helpers/ntlm_auth/fakeauth/.cvsignore b/helpers/ntlm_auth/fakeauth/.cvsignore index 63f8570f9f..a809eec86a 100644 --- a/helpers/ntlm_auth/fakeauth/.cvsignore +++ b/helpers/ntlm_auth/fakeauth/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +fakeauth_auth diff --git a/helpers/ntlm_auth/winbind/.cvsignore b/helpers/ntlm_auth/winbind/.cvsignore index 63f8570f9f..f92311e747 100644 --- a/helpers/ntlm_auth/winbind/.cvsignore +++ b/helpers/ntlm_auth/winbind/.cvsignore @@ -1,2 +1,3 @@ .deps Makefile +wb_ntlmauth diff --git a/lib/libTrie/.cvsignore b/lib/libTrie/.cvsignore index cdfff08ace..22f800cb63 100644 --- a/lib/libTrie/.cvsignore +++ b/lib/libTrie/.cvsignore @@ -1,4 +1,4 @@ Makefile config.* autom4te* -makefile +stamp-h1 diff --git a/src/.cvsignore b/src/.cvsignore index e94fcf0e7e..5ef4e288c8 100644 --- a/src/.cvsignore +++ b/src/.cvsignore @@ -1,18 +1,17 @@ .deps Makefile -auth_modules.c +auth_modules.cc +cachemgr.cgi cf.data +cf_gen cf_gen_defines.h -cf_parser.c cf_parser.h -globals.c -repl_modules.c -squid.conf -squid.conf.default -store_modules.c -string_arrays.c -cachemgr -cf_gen +dnsserver +globals.cc +pinger +repl_modules.cc squid +squid.conf.default squidclient +string_arrays.c unlinkd diff --git a/src/IPInterception.cc b/src/IPInterception.cc index c658f312b9..c1944f810e 100644 --- a/src/IPInterception.cc +++ b/src/IPInterception.cc @@ -1,6 +1,6 @@ /* - * $Id: IPInterception.cc,v 1.6 2003/02/21 22:50:05 robertc Exp $ + * $Id: IPInterception.cc,v 1.7 2003/08/03 08:09:26 robertc Exp $ * * DEBUG: section 89 NAT / IP Interception * AUTHOR: Robert Collins @@ -149,11 +149,6 @@ clientNatLookup(int fd, struct sockaddr_in me, struct sockaddr_in peer, struct s return 0; } - else - { - return -1; - } -} } #elif LINUX_NETFILTER diff --git a/src/auth/basic/.cvsignore b/src/auth/basic/.cvsignore index 0881ecd5b6..ec96903b9d 100644 --- a/src/auth/basic/.cvsignore +++ b/src/auth/basic/.cvsignore @@ -1,2 +1,2 @@ +.deps .dirstamp -Makefile diff --git a/src/auth/digest/.cvsignore b/src/auth/digest/.cvsignore index 0881ecd5b6..ec96903b9d 100644 --- a/src/auth/digest/.cvsignore +++ b/src/auth/digest/.cvsignore @@ -1,2 +1,2 @@ +.deps .dirstamp -Makefile diff --git a/src/auth/ntlm/.cvsignore b/src/auth/ntlm/.cvsignore index f3c7a7c5da..ec96903b9d 100644 --- a/src/auth/ntlm/.cvsignore +++ b/src/auth/ntlm/.cvsignore @@ -1 +1,2 @@ -Makefile +.deps +.dirstamp diff --git a/src/auth/ntlm/auth_ntlm.cc b/src/auth/ntlm/auth_ntlm.cc index ce18661ed4..c4d1ac1c5d 100644 --- a/src/auth/ntlm/auth_ntlm.cc +++ b/src/auth/ntlm/auth_ntlm.cc @@ -1,6 +1,6 @@ /* - * $Id: auth_ntlm.cc,v 1.34 2003/07/14 14:16:21 robertc Exp $ + * $Id: auth_ntlm.cc,v 1.35 2003/08/03 08:09:30 robertc Exp $ * * DEBUG: section 29 NTLM Authenticator * AUTHOR: Robert Collins @@ -598,7 +598,7 @@ authenticateNTLMHandleReply(void *data, void *lastserver, char *reply) /* we only expect LD when finishing the handshake */ assert(ntlm_request->auth_state == AUTHENTICATE_STATE_RESPONSE); ntlm_user->username = xstrndup(reply, MAX_LOGIN_SZ); - helperstate = helperStatefulServerGetData(ntlm_request->authserver); + helperstate = static_cast(helperStatefulServerGetData(ntlm_request->authserver)); ntlm_request->authserver = NULL; /* BH code: mark helper as broken */ /* mark it for starving */ diff --git a/src/client_side_request.cc b/src/client_side_request.cc index 43cfc176b5..5763cd3c7b 100644 --- a/src/client_side_request.cc +++ b/src/client_side_request.cc @@ -1,6 +1,6 @@ /* - * $Id: client_side_request.cc,v 1.28 2003/07/14 15:07:21 robertc Exp $ + * $Id: client_side_request.cc,v 1.29 2003/08/03 08:09:26 robertc Exp $ * * DEBUG: section 85 Client-side Request Routines * AUTHOR: Robert Collins (Originally Duane Wessels in client_side.c) @@ -674,13 +674,13 @@ clientInterpretRequestHeaders(clientHttpRequest * http) #if USE_USERAGENT_LOG if ((str = httpHeaderGetStr(req_hdr, HDR_USER_AGENT))) - logUserAgent(fqdnFromAddr(http->getConn() ? http->getConn()->log_addr : no_addr), str); + logUserAgent(fqdnFromAddr(http->getConn().getRaw() ? http->getConn()->log_addr : no_addr), str); #endif #if USE_REFERER_LOG if ((str = httpHeaderGetStr(req_hdr, HDR_REFERER))) - logReferer(fqdnFromAddr(http->getConn() ? http->getConn()->log_addr : no_addr), str, http->log_uri); + logReferer(fqdnFromAddr(http->getConn().getRaw() ? http->getConn()->log_addr : no_addr), str, http->log_uri); #endif #if FORW_VIA_DB diff --git a/src/fs/aufs/.cvsignore b/src/fs/aufs/.cvsignore index 0881ecd5b6..ec96903b9d 100644 --- a/src/fs/aufs/.cvsignore +++ b/src/fs/aufs/.cvsignore @@ -1,2 +1,2 @@ +.deps .dirstamp -Makefile diff --git a/src/fs/coss/.cvsignore b/src/fs/coss/.cvsignore index f3c7a7c5da..ec96903b9d 100644 --- a/src/fs/coss/.cvsignore +++ b/src/fs/coss/.cvsignore @@ -1 +1,2 @@ -Makefile +.deps +.dirstamp diff --git a/src/fs/diskd/.cvsignore b/src/fs/diskd/.cvsignore index ba68552b4e..2e618e39f1 100644 --- a/src/fs/diskd/.cvsignore +++ b/src/fs/diskd/.cvsignore @@ -1,3 +1,3 @@ .deps -Makefile +.dirstamp diskd diff --git a/src/fs/null/.cvsignore b/src/fs/null/.cvsignore index 0881ecd5b6..ec96903b9d 100644 --- a/src/fs/null/.cvsignore +++ b/src/fs/null/.cvsignore @@ -1,2 +1,2 @@ +.deps .dirstamp -Makefile diff --git a/src/fs/ufs/.cvsignore b/src/fs/ufs/.cvsignore index 0881ecd5b6..ec96903b9d 100644 --- a/src/fs/ufs/.cvsignore +++ b/src/fs/ufs/.cvsignore @@ -1,2 +1,2 @@ +.deps .dirstamp -Makefile diff --git a/src/repl/.cvsignore b/src/repl/.cvsignore index a09ad2358e..63f8570f9f 100644 --- a/src/repl/.cvsignore +++ b/src/repl/.cvsignore @@ -1,3 +1,2 @@ .deps Makefile -stamp diff --git a/src/repl/heap/.cvsignore b/src/repl/heap/.cvsignore index f3c7a7c5da..5d91176542 100644 --- a/src/repl/heap/.cvsignore +++ b/src/repl/heap/.cvsignore @@ -1 +1,3 @@ +.deps +.dirstamp Makefile diff --git a/src/repl/lru/.cvsignore b/src/repl/lru/.cvsignore index 0881ecd5b6..5d91176542 100644 --- a/src/repl/lru/.cvsignore +++ b/src/repl/lru/.cvsignore @@ -1,2 +1,3 @@ +.deps .dirstamp Makefile