--------------------- PatchSet 2589 Date: 2001/07/09 20:25:11 Author: serassio Branch: nt-2_3 Tag: (none) Log: Enabled full Process Filedescriptor Allocation cachemgr features Members: Readme.txt:1.1.2.2->1.1.2.3(DEAD) WIN32-ChangeLog.txt:1.1.2.4->1.1.2.5(DEAD) doc/WIN32-ChangeLog.txt:1.1->1.1.2.1 doc/readme.txt:1.1->1.1.2.1 src/stat.c:1.1.1.3.4.1.2.2->1.1.1.3.4.1.2.3 src/useragent.c:1.1.1.3.4.1.2.6->1.1.1.3.4.1.2.7 --- squid/Readme.txt Wed Feb 14 00:53:48 2007 +++ /dev/null Wed Feb 14 00:52:54 2007 @@ -1,64 +0,0 @@ -Free Squid NT 2.3 STABLE 4 for Windows NT 4 - -(native port of Squid 2.3 STABLE 4, plus 09/01/2001 tarball update and many NT service enhancement, derived from the Harvest project) -Current features: - -Run as a native Windows NT Service (No CygWin Unix emulation, compiled with MS VC 6.0) -Use PSAPI.LIB for rusage emulation -Internal DNS looks in registry for configured DNS, resolv.conf no more needed -External DNS helper run as a DLL plug-in and use internal NT DNS resolver, so hosts file if used. -All squid -k switches (check, debug, interrupt, kill, parse, reconfigure, rotate, shutdown) works -Native Windows NT Authenticator working as DLL plug-in, is possible to authenticante against a single NT Server, a single or a trusted NT Domain. User access allowed by NT User Group membership -NCSA Authenticator working as DLL plug-in -Working htpasswd and chhpasswd.cgi for NCSA password support -LDAP Authenticator working as DLL plug-in (NOT YET TESTED !!!) -Working Cachemgr CGI interface -Code Merged with main Head 09/01/2001 tarball -Buffered Disk I/O -Current ChangeLog - -Install: -Read the CompileOptions.txt file -Edit the squid.conf (use path with '/' char, NOT '\') -Manually create ALL the directories specified in squid.conf, except the contents of the cache directory -squid -z (creates the cache directories) -squid -i (installs the SquidNT2.3Stable4 beta service) - - -Authenticators configuration: -Edit the squid.conf -Specify the FULL DLL path (with .dll suffix) in the authenticate_program directive plus the correct parameter - See the original authenticator documentation - - -External DNS Helper Plug-in configuration: -Edit the squid.conf -Specify the FULL DLL path (with .dll suffix) in the cache_dns_program directive - - -Uninstall: -squid -r (removes the SquidNT2.3Stable4 beta service) - - -Usage: -Start: Control Panel/Services: choose "Start" for the "SquidNT2.3Stable4 beta" service. -Stop: Control Panel/Services: choose "Stop" for the "SquidNT2.3Stable4 beta" service. -squid -f file Set Windows NT Registry to use given config-file instead of default config-file -squid -h Print help message. -squid -k reconfigure | rotate | shutdown | interrupt | kill | debug | check -Send signal to running copy and exit. -squid -v Print version. - -The results of the rest of the (original) cmdline switches is undeterminate (for the moment). - - -Compiling: -Compile environment needed: - -MS Visual Studio C++ 6.0 -Native Perl for NT -Native sed for NT -PSAPI files from MS SDK - -No warranties of any kind. No time for support, sorry. Use at your own risk. - -Original Port and some enhancements by Romeo Anghelache (see the ChangeLog) --- squid/WIN32-ChangeLog.txt Wed Feb 14 00:53:48 2007 +++ /dev/null Wed Feb 14 00:52:54 2007 @@ -1,41 +0,0 @@ -Squid 2.3 Stable 4 for WIN32 Change Log - -Plese note, that ALL the Windows NT source addition are encapsulated between -#ifdef _SQUID_MSWIN_ - #endif sections. - -16 Nov 2000 - Initial WIN32 port (Romeo Anghelache) -03 Dec 2000 - Added more service functionality, so squid -k works (Guido Serassio) - - Added PSAPI.LIB for rusage emulation (Guido Serassio) - - Merged with 21/11/2000 main Head tarball (Guido Serassio) - - Internal DNS looks in registry for configured DNS (Guido Serassio) - - Added WIN32 EXE file version information (Guido Serassio) -06 Dec 2000 - cachemgr.exe done (Romeo Anghelache) - - patched comm_select to handle service_not_available in win32 (Romeo Anghelache) -09 Dec 2000 - Fixed a problem with log files rotate (Guido Serassio) - - Added native Windows NT Authenticator working as DLL (Guido Serassio) -10 Dec 2000 - Added NCSA Authenticator working as DLL (Guido Serassio) - - Added crypt function to source (Guido Serassio) - - Ported htpasswd and chhpasswd.cgi for NCSA password support (Guido Serassio) - - Added dnsserver helper running as DLL (Guido Serassio) -11 Dec 2000 - Added LDAP Authenticator working as DLL - NOT YET TESTED !!! (Guido Serassio) -14 Dec 2000 - Disk I/O is now buffered (Romeo Anghelache) -21 Dec 2000 - Merged with 21/12/2000 main Head tarball (Guido Serassio) -11 Jan 2001 - Merged with 09/01/2001 main Head tarball (Guido Serassio) -28 Jan 2001 - Restored use of perl scripts, sed and cf_gen during compile phase - No more - code enhancement (Guido Serassio) -10 Feb 2001 - Fixed a problem with fatal errors handling (Guido Serassio) -04 Mar 2001 - Merged with 03/03/2001 main Head tarball (Guido Serassio) -12 Mar 2001 - Enabled -f switch to set Windows NT Registry with an alternate config-file - and fixed the config-file not found error when running as a service (Guido Serassio) -16 Jun 2001 - Fixed a bug in the native Windows NT Authenticator when authentication is made - against a NT domain (Guido Serassio) - - Fixed a bug in free disk space determination - (Guido Serassio) - - Fixed various memory leaks (Backported patches) - (Guido Serassio) -17 Jun 2001 - Backported WIN32 code from 2.5 DEVEL. Now is possible to run multiple instances of - Squid service and a full traditional command line mode is available for - debugging purpose (Guido serassio) -18 Jun 2001 - Fixed a multi cache dir bug - (Guido Serassio) -29 Jun 2001 - Fixed a bug in Useragent Log - (Guido Serassio) -02 Jul 2001 - Partially fixed FD problems and 100% CPU load problems - (Guido Serassio) -07 Jul 2001 - Fixed a "non caching" bug - (Guido Serassio) - --- /dev/null Wed Feb 14 00:52:54 2007 +++ squid/doc/WIN32-ChangeLog.txt Wed Feb 14 00:53:48 2007 @@ -0,0 +1,42 @@ +Squid 2.3 Stable 4 for WIN32 Change Log + +Plese note, that ALL the Windows NT source addition are encapsulated between +#ifdef _SQUID_MSWIN_ - #endif sections. + +16 Nov 2000 - Initial WIN32 port (Romeo Anghelache) +03 Dec 2000 - Added more service functionality, so squid -k works (Guido Serassio) + - Added PSAPI.LIB for rusage emulation (Guido Serassio) + - Merged with 21/11/2000 main Head tarball (Guido Serassio) + - Internal DNS looks in registry for configured DNS (Guido Serassio) + - Added WIN32 EXE file version information (Guido Serassio) +06 Dec 2000 - cachemgr.exe done (Romeo Anghelache) + - patched comm_select to handle service_not_available in win32 (Romeo Anghelache) +09 Dec 2000 - Fixed a problem with log files rotate (Guido Serassio) + - Added native Windows NT Authenticator working as DLL (Guido Serassio) +10 Dec 2000 - Added NCSA Authenticator working as DLL (Guido Serassio) + - Added crypt function to source (Guido Serassio) + - Ported htpasswd and chhpasswd.cgi for NCSA password support (Guido Serassio) + - Added dnsserver helper running as DLL (Guido Serassio) +11 Dec 2000 - Added LDAP Authenticator working as DLL - NOT YET TESTED !!! (Guido Serassio) +14 Dec 2000 - Disk I/O is now buffered (Romeo Anghelache) +21 Dec 2000 - Merged with 21/12/2000 main Head tarball (Guido Serassio) +11 Jan 2001 - Merged with 09/01/2001 main Head tarball (Guido Serassio) +28 Jan 2001 - Restored use of perl scripts, sed and cf_gen during compile phase - No more + code enhancement (Guido Serassio) +10 Feb 2001 - Fixed a problem with fatal errors handling (Guido Serassio) +04 Mar 2001 - Merged with 03/03/2001 main Head tarball (Guido Serassio) +12 Mar 2001 - Enabled -f switch to set Windows NT Registry with an alternate config-file + and fixed the config-file not found error when running as a service (Guido Serassio) +16 Jun 2001 - Fixed a bug in the native Windows NT Authenticator when authentication is made + against a NT domain (Guido Serassio) + - Fixed a bug in free disk space determination - (Guido Serassio) + - Fixed various memory leaks (Backported patches) - (Guido Serassio) +17 Jun 2001 - Backported WIN32 code from 2.5 DEVEL. Now is possible to run multiple instances of + Squid service and a full traditional command line mode is available for + debugging purpose (Guido serassio) +18 Jun 2001 - Fixed a multi cache dir bug - (Guido Serassio) +29 Jun 2001 - Fixed a bug in Useragent Log - (Guido Serassio) +02 Jul 2001 - Partially fixed FD problems and 100% CPU load problems - (Guido Serassio) +07 Jul 2001 - Fixed a "non caching" bug - (Guido Serassio) +09 Jul 2001 - Enabled full "Process Filedescriptor Allocation" cachemgr features - (Guido Serassio) + --- /dev/null Wed Feb 14 00:52:54 2007 +++ squid/doc/readme.txt Wed Feb 14 00:53:48 2007 @@ -0,0 +1,64 @@ +Free Squid NT 2.3 STABLE 4 for Windows NT 4 + +(native port of Squid 2.3 STABLE 4, plus 09/01/2001 tarball update and many NT service enhancement, derived from the Harvest project) +Current features: + +Run as a native Windows NT Service (No CygWin Unix emulation, compiled with MS VC 6.0) +Use PSAPI.LIB for rusage emulation +Internal DNS looks in registry for configured DNS, resolv.conf no more needed +External DNS helper run as a DLL plug-in and use internal NT DNS resolver, so hosts file if used. +All squid -k switches (check, debug, interrupt, kill, parse, reconfigure, rotate, shutdown) works +Native Windows NT Authenticator working as DLL plug-in, is possible to authenticante against a single NT Server, a single or a trusted NT Domain. User access allowed by NT User Group membership +NCSA Authenticator working as DLL plug-in +Working htpasswd and chhpasswd.cgi for NCSA password support +LDAP Authenticator working as DLL plug-in (NOT YET TESTED !!!) +Working Cachemgr CGI interface +Code Merged with main Head 09/01/2001 tarball +Buffered Disk I/O +Current ChangeLog + +Install: +Read the CompileOptions.txt file +Edit the squid.conf (use path with '/' char, NOT '\') +Manually create ALL the directories specified in squid.conf, except the contents of the cache directory +squid -z (creates the cache directories) +squid -i (installs the SquidNT2.3Stable4 beta service) + + +Authenticators configuration: +Edit the squid.conf +Specify the FULL DLL path (with .dll suffix) in the authenticate_program directive plus the correct parameter - See the original authenticator documentation + + +External DNS Helper Plug-in configuration: +Edit the squid.conf +Specify the FULL DLL path (with .dll suffix) in the cache_dns_program directive + + +Uninstall: +squid -r (removes the SquidNT2.3Stable4 beta service) + + +Usage: +Start: Control Panel/Services: choose "Start" for the "SquidNT2.3Stable4 beta" service. +Stop: Control Panel/Services: choose "Stop" for the "SquidNT2.3Stable4 beta" service. +squid -f file Set Windows NT Registry to use given config-file instead of default config-file +squid -h Print help message. +squid -k reconfigure | rotate | shutdown | interrupt | kill | debug | check +Send signal to running copy and exit. +squid -v Print version. + +The results of the rest of the (original) cmdline switches is undeterminate (for the moment). + + +Compiling: +Compile environment needed: + +MS Visual Studio C++ 6.0 +Native Perl for NT +Native sed for NT +PSAPI files from MS SDK + +No warranties of any kind. No time for support, sorry. Use at your own risk. + +Original Port and some enhancements by Romeo Anghelache (see the ChangeLog) Index: squid/src/stat.c =================================================================== RCS file: /cvsroot/squid-sf//squid/src/stat.c,v retrieving revision 1.1.1.3.4.1.2.2 retrieving revision 1.1.1.3.4.1.2.3 diff -u -r1.1.1.3.4.1.2.2 -r1.1.1.3.4.1.2.3 --- squid/src/stat.c 3 Jun 2001 19:41:48 -0000 1.1.1.3.4.1.2.2 +++ squid/src/stat.c 9 Jul 2001 20:25:11 -0000 1.1.1.3.4.1.2.3 @@ -1,6 +1,6 @@ /* - * $Id: stat.c,v 1.1.1.3.4.1.2.2 2001/06/03 19:41:48 serassio Exp $ + * $Id: stat.c,v 1.1.1.3.4.1.2.3 2001/07/09 20:25:11 serassio Exp $ * * DEBUG: section 18 Cache Manager Statistics * AUTHOR: Harvest Derived @@ -392,6 +392,16 @@ #endif static const char * +#ifdef _SQUID_MSWIN_ +sdRemoteAddr(const sde * f) +{ + LOCAL_ARRAY(char, buf, 32); + if (f->type != FD_SOCKET) + return null_string; + snprintf(buf, 32, "%s.%d", f->ipaddr, (int) f->remote_port); + return buf; +} +#endif fdRemoteAddr(const fde * f) { LOCAL_ARRAY(char, buf, 32); @@ -406,6 +416,9 @@ { int i; fde *f; +#ifdef _SQUID_MSWIN_ + sde *s; +#endif storeAppendPrintf(sentry, "Active file descriptors:\n"); storeAppendPrintf(sentry, "%-4s %-6s %-4s %-7s* %-7s* %-21s %s\n", "File", @@ -431,6 +444,23 @@ fdRemoteAddr(f), f->desc); } +#ifdef _SQUID_MSWIN_ + for (i = 0; i < Squid_MaxFD; i++) { + s = &sd_table[i]; + if (!s->flags.open) + continue; + storeAppendPrintf(sentry, "%4d %-6.6s %4d %7d%c %7d%c %-21s %s\n", + i, + fdTypeStr[s->type], + s->timeout_handler ? (int) (s->timeout - squid_curtime) / 60 : 0, + s->bytes_read, + s->read_handler ? '*' : ' ', + s->bytes_written, + s->write_handler ? '*' : ' ', + sdRemoteAddr(s), + s->desc); + } +#endif } static void Index: squid/src/useragent.c =================================================================== RCS file: /cvsroot/squid-sf//squid/src/useragent.c,v retrieving revision 1.1.1.3.4.1.2.6 retrieving revision 1.1.1.3.4.1.2.7 diff -u -r1.1.1.3.4.1.2.6 -r1.1.1.3.4.1.2.7 --- squid/src/useragent.c 8 Jul 2001 10:32:00 -0000 1.1.1.3.4.1.2.6 +++ squid/src/useragent.c 9 Jul 2001 20:25:11 -0000 1.1.1.3.4.1.2.7 @@ -1,6 +1,6 @@ /* - * $Id: useragent.c,v 1.1.1.3.4.1.2.6 2001/07/08 10:32:00 serassio Exp $ + * $Id: useragent.c,v 1.1.1.3.4.1.2.7 2001/07/09 20:25:11 serassio Exp $ * * DEBUG: section 40 User-Agent logging * AUTHOR: Joe Ramey @@ -135,7 +135,7 @@ { #if USE_USERAGENT_LOG if (cache_useragent_log) - fclose(cache_useragent_log); + fclose(cache_useragent_log); cache_useragent_log = NULL; #endif }