------------------------------------------------------------ revno: 12303 revision-id: kinkie@squid-cache.org-20120828191213-12bx12k9mj4zqq1o parent: squid3@treenet.co.nz-20120828130448-iqiy6eq4oj3k3b25 committer: Francesco Chemolli branch nick: trunk timestamp: Tue 2012-08-28 21:12:13 +0200 message: protos.h refactoring, part one. Refactor many function prototypes from protos.h to more specific header files. Change linkage for moved prototypes to c++. ------------------------------------------------------------ # Bazaar merge directive format 2 (Bazaar 0.90) # revision_id: kinkie@squid-cache.org-20120828191213-12bx12k9mj4zqq1o # target_branch: http://bzr.squid-cache.org/bzr/squid3/trunk/ # testament_sha1: 02b6c288aea335cd822fae43f3f06c0531da06e1 # timestamp: 2012-08-28 19:51:41 +0000 # source_branch: http://bzr.squid-cache.org/bzr/squid3/trunk/ # base_revision_id: squid3@treenet.co.nz-20120828130448-\ # iqiy6eq4oj3k3b25 # # Begin patch === modified file 'src/CacheDigest.cc' --- src/CacheDigest.cc 2012-08-14 11:53:07 +0000 +++ src/CacheDigest.cc 2012-08-28 19:12:13 +0000 @@ -35,12 +35,17 @@ #include "squid.h" #include "md5.h" +#include "Mem.h" #include "protos.h" #include "StatCounters.h" #include "Store.h" +#include "store_key_md5.h" #if USE_CACHE_DIGESTS +#include "CacheDigest.h" +#include "structs.h" + /* local types */ typedef struct { === added file 'src/CacheDigest.h' --- src/CacheDigest.h 1970-01-01 00:00:00 +0000 +++ src/CacheDigest.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,55 @@ +/* + * DEBUG: section 70 Cache Digest + * AUTHOR: Alex Rousskov + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + +#ifndef SQUID_CACHEDIGEST_H_ +#define SQUID_CACHEDIGEST_H_ + +#include "typedefs.h" +class CacheDigestGuessStats; +class StoreEntry; + +extern CacheDigest *cacheDigestCreate(int capacity, int bpe); +extern void cacheDigestDestroy(CacheDigest * cd); +extern CacheDigest *cacheDigestClone(const CacheDigest * cd); +extern void cacheDigestClear(CacheDigest * cd); +extern void cacheDigestChangeCap(CacheDigest * cd, int new_cap); +extern int cacheDigestTest(const CacheDigest * cd, const cache_key * key); +extern void cacheDigestAdd(CacheDigest * cd, const cache_key * key); +extern void cacheDigestDel(CacheDigest * cd, const cache_key * key); +extern size_t cacheDigestCalcMaskSize(int cap, int bpe); +extern int cacheDigestBitUtil(const CacheDigest * cd); +extern void cacheDigestGuessStatsUpdate(CacheDigestGuessStats * stats, int real_hit, int guess_hit); +extern void cacheDigestGuessStatsReport(const CacheDigestGuessStats * stats, StoreEntry * sentry, const char *label); +extern void cacheDigestReport(CacheDigest * cd, const char *label, StoreEntry * e); + + +#endif /* SQUID_CACHEDIGEST_H_ */ === modified file 'src/ConfigParser.cc' --- src/ConfigParser.cc 2012-08-14 11:53:07 +0000 +++ src/ConfigParser.cc 2012-08-28 19:12:13 +0000 @@ -34,6 +34,7 @@ */ #include "squid.h" +#include "cache_cf.h" #include "ConfigParser.h" #include "Debug.h" #include "globals.h" === modified file 'src/DelaySpec.cc' --- src/DelaySpec.cc 2012-08-14 11:53:07 +0000 +++ src/DelaySpec.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,7 @@ #include "squid.h" #if USE_DELAY_POOLS +#include "cache_cf.h" #include "DelaySpec.h" #include "Parsing.h" #include "protos.h" === modified file 'src/DiskIO/AIO/AIODiskFile.cc' --- src/DiskIO/AIO/AIODiskFile.cc 2012-08-15 15:17:32 +0000 +++ src/DiskIO/AIO/AIODiskFile.cc 2012-08-28 19:12:13 +0000 @@ -50,6 +50,7 @@ #include "DiskIO/IORequestor.h" #include "DiskIO/ReadRequest.h" #include "DiskIO/WriteRequest.h" +#include "disk.h" #include "protos.h" #if HAVE_ERRNO_H === modified file 'src/DiskIO/Blocking/BlockingFile.cc' --- src/DiskIO/Blocking/BlockingFile.cc 2012-08-28 13:00:30 +0000 +++ src/DiskIO/Blocking/BlockingFile.cc 2012-08-28 19:12:13 +0000 @@ -38,6 +38,7 @@ #include "DiskIO/IORequestor.h" #include "DiskIO/ReadRequest.h" #include "DiskIO/WriteRequest.h" +#include "disk.h" #include "protos.h" #if HAVE_ERRNO_H === modified file 'src/DiskIO/DiskDaemon/DiskdIOStrategy.cc' --- src/DiskIO/DiskDaemon/DiskdIOStrategy.cc 2012-08-28 13:00:30 +0000 +++ src/DiskIO/DiskDaemon/DiskdIOStrategy.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,7 @@ #include "DiskIO/DiskFile.h" #include "DiskdFile.h" #include "diomsg.h" +#include "fd.h" #include "protos.h" #include "Store.h" #include "StatCounters.h" === modified file 'src/DiskIO/DiskThreads/CommIO.cc' --- src/DiskIO/DiskThreads/CommIO.cc 2012-08-14 11:53:07 +0000 +++ src/DiskIO/DiskThreads/CommIO.cc 2012-08-28 19:12:13 +0000 @@ -35,6 +35,7 @@ #include "squid.h" #include "comm/Loops.h" #include "DiskIO/DiskThreads/CommIO.h" +#include "fd.h" #include "globals.h" #include "protos.h" === modified file 'src/DiskIO/DiskThreads/DiskThreadsDiskFile.cc' --- src/DiskIO/DiskThreads/DiskThreadsDiskFile.cc 2012-08-28 13:00:30 +0000 +++ src/DiskIO/DiskThreads/DiskThreadsDiskFile.cc 2012-08-28 19:12:13 +0000 @@ -34,10 +34,12 @@ */ #include "squid.h" +#include "disk.h" #include "DiskThreadsDiskFile.h" #include "DiskIO/IORequestor.h" #include "DiskIO/ReadRequest.h" #include "DiskIO/WriteRequest.h" +#include "fd.h" #include "Generic.h" #include "globals.h" #include "StatCounters.h" === modified file 'src/DiskIO/IpcIo/IpcIoFile.cc' --- src/DiskIO/IpcIo/IpcIoFile.cc 2012-08-28 13:00:30 +0000 +++ src/DiskIO/IpcIo/IpcIoFile.cc 2012-08-28 19:12:13 +0000 @@ -11,6 +11,8 @@ #include "DiskIO/IpcIo/IpcIoFile.h" #include "DiskIO/ReadRequest.h" #include "DiskIO/WriteRequest.h" +#include "disk.h" +#include "fd.h" #include "globals.h" #include "ipc/mem/Pages.h" #include "ipc/Messages.h" === modified file 'src/DiskIO/Mmapped/MmappedFile.cc' --- src/DiskIO/Mmapped/MmappedFile.cc 2012-08-28 13:00:30 +0000 +++ src/DiskIO/Mmapped/MmappedFile.cc 2012-08-28 19:12:13 +0000 @@ -10,6 +10,7 @@ #include "DiskIO/Mmapped/MmappedFile.h" #include "DiskIO/ReadRequest.h" #include "DiskIO/WriteRequest.h" +#include "disk.h" #include "globals.h" #include "protos.h" === modified file 'src/ExternalACL.h' --- src/ExternalACL.h 2012-08-28 13:00:30 +0000 +++ src/ExternalACL.h 2012-08-28 19:12:13 +0000 @@ -93,4 +93,16 @@ MEMPROXY_CLASS_INLINE(ACLExternal); +class ACLChecklist; +class StoreEntry; + +extern void parse_externalAclHelper(external_acl **); +extern void dump_externalAclHelper(StoreEntry * sentry, const char *name, const external_acl *); +extern void free_externalAclHelper(external_acl **); +typedef void EAH(void *data, void *result); +extern void externalAclLookup(ACLChecklist * ch, void *acl_data, EAH * handler, void *data); +extern void externalAclInit(void); +extern void externalAclShutdown(void); + + #endif /* SQUID_EXTERNALACL_H */ === modified file 'src/HelperChildConfig.cc' --- src/HelperChildConfig.cc 2012-08-14 11:53:07 +0000 +++ src/HelperChildConfig.cc 2012-08-28 19:12:13 +0000 @@ -1,4 +1,5 @@ #include "squid.h" +#include "cache_cf.h" #include "Debug.h" #include "HelperChildConfig.h" #include "globals.h" === modified file 'src/HttpHdrCc.cc' --- src/HttpHdrCc.cc 2012-08-28 13:00:30 +0000 +++ src/HttpHdrCc.cc 2012-08-28 19:12:13 +0000 @@ -34,6 +34,7 @@ #include "base/StringArea.h" #include "HttpHeader.h" #include "HttpHeaderStat.h" +#include "HttpHeaderTools.h" #include "HttpHdrCc.h" #include "StatHist.h" #include "Store.h" === modified file 'src/HttpHdrCc.h' --- src/HttpHdrCc.h 2012-08-14 11:53:07 +0000 +++ src/HttpHdrCc.h 2012-08-28 19:12:13 +0000 @@ -178,6 +178,14 @@ MEMPROXY_CLASS_INLINE(HttpHdrCc); +class StatHist; +class StoreEntry; + +extern void httpHdrCcInitModule(void); +extern void httpHdrCcCleanModule(void); +extern void httpHdrCcUpdateStats(const HttpHdrCc * cc, StatHist * hist); +extern void httpHdrCcStatDumper(StoreEntry * sentry, int idx, double val, double size, int count); + #if _USE_INLINE_ #include "HttpHdrCc.cci" #endif === modified file 'src/HttpHdrContRange.cc' --- src/HttpHdrContRange.cc 2012-08-28 13:00:30 +0000 +++ src/HttpHdrContRange.cc 2012-08-28 19:12:13 +0000 @@ -38,6 +38,7 @@ #include "enums.h" #include "HttpHdrContRange.h" #include "HttpHeaderTools.h" +#include "Mem.h" #include "protos.h" /* === modified file 'src/HttpHdrSc.cc' --- src/HttpHdrSc.cc 2012-08-28 13:00:30 +0000 +++ src/HttpHdrSc.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,7 @@ #include "HttpHdrSc.h" #include "HttpHeader.h" #include "HttpHeaderStat.h" +#include "HttpHeaderTools.h" #include "Store.h" #include "protos.h" === modified file 'src/HttpHeader.cc' --- src/HttpHeader.cc 2012-08-28 13:00:30 +0000 +++ src/HttpHeader.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,7 @@ #include "HttpHdrSc.h" #include "HttpHeader.h" #include "HttpHeaderStat.h" +#include "HttpHeaderTools.h" #include "MemBuf.h" #include "mgr/Registration.h" #include "profiler/Profiler.h" === modified file 'src/HttpHeader.h' --- src/HttpHeader.h 2012-08-28 13:00:30 +0000 +++ src/HttpHeader.h 2012-08-28 19:12:13 +0000 @@ -291,9 +291,9 @@ }; extern int httpHeaderParseQuotedString(const char *start, const int len, String *val); -SQUIDCEXTERN int httpHeaderHasByNameListMember(const HttpHeader * hdr, const char *name, const char *member, const char separator); -SQUIDCEXTERN void httpHeaderUpdate(HttpHeader * old, const HttpHeader * fresh, const HttpHeaderMask * denied_mask); -SQUIDCEXTERN void httpHeaderCalcMask(HttpHeaderMask * mask, http_hdr_type http_hdr_type_enums[], size_t count); +extern int httpHeaderHasByNameListMember(const HttpHeader * hdr, const char *name, const char *member, const char separator); +extern void httpHeaderUpdate(HttpHeader * old, const HttpHeader * fresh, const HttpHeaderMask * denied_mask); +extern void httpHeaderCalcMask(HttpHeaderMask * mask, http_hdr_type http_hdr_type_enums[], size_t count); inline bool HttpHeader::chunked() const @@ -302,4 +302,7 @@ hasListMember(HDR_TRANSFER_ENCODING, "chunked", ','); } +extern void httpHeaderInitModule(void); +extern void httpHeaderCleanModule(void); + #endif /* SQUID_HTTPHEADER_H */ === modified file 'src/HttpHeaderTools.h' --- src/HttpHeaderTools.h 2012-08-14 11:53:07 +0000 +++ src/HttpHeaderTools.h 2012-08-28 19:12:13 +0000 @@ -3,6 +3,7 @@ #include "format/Format.h" #include "HttpHeader.h" +#include "typedefs.h" #if HAVE_LIST #include @@ -91,6 +92,19 @@ bool quoted; }; -SQUIDCEXTERN int httpHeaderParseOffset(const char *start, int64_t * off); +extern int httpHeaderParseOffset(const char *start, int64_t * off); + +class HttpHeaderFieldInfo; +class String; + +extern HttpHeaderFieldInfo *httpHeaderBuildFieldsInfo(const HttpHeaderFieldAttrs * attrs, int count); +extern void httpHeaderDestroyFieldsInfo(HttpHeaderFieldInfo * info, int count); +extern http_hdr_type httpHeaderIdByName(const char *name, size_t name_len, const HttpHeaderFieldInfo * attrs, int end); +extern http_hdr_type httpHeaderIdByNameDef(const char *name, int name_len); +extern const char *httpHeaderNameById(int id); +extern int httpHeaderHasConnDir(const HttpHeader * hdr, const char *directive); +extern int httpHeaderParseInt(const char *start, int *val); +extern void httpHeaderPutStrf(HttpHeader * hdr, http_hdr_type id, const char *fmt,...) PRINTF_FORMAT_ARG3; + #endif === modified file 'src/HttpMsg.cc' --- src/HttpMsg.cc 2012-08-14 11:53:07 +0000 +++ src/HttpMsg.cc 2012-08-28 19:12:13 +0000 @@ -35,6 +35,7 @@ #include "squid.h" #include "Debug.h" +#include "HttpHeaderTools.h" #include "HttpMsg.h" #include "MemBuf.h" #include "profiler/Profiler.h" === modified file 'src/HttpRequest.cc' --- src/HttpRequest.cc 2012-08-15 00:13:13 +0000 +++ src/HttpRequest.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,8 @@ #include "client_side.h" #include "DnsLookupDetails.h" #include "err_detail_type.h" +#include "gopher.h" +#include "http.h" #include "HttpHdrCc.h" #include "HttpHeaderRange.h" #include "HttpRequest.h" @@ -47,6 +49,7 @@ #include "MemBuf.h" #include "protos.h" #include "Store.h" +#include "URL.h" #if USE_AUTH #include "auth/UserRequest.h" === modified file 'src/Makefile.am' --- src/Makefile.am 2012-08-14 11:53:07 +0000 +++ src/Makefile.am 2012-08-28 19:12:13 +0000 @@ -263,16 +263,21 @@ AccessLogEntry.h \ AsyncEngine.cc \ AsyncEngine.h \ + cache_cf.h \ cache_cf.cc \ + CacheDigest.h \ CacheDigest.cc \ cache_manager.cc \ CacheManager.h \ + carp.h \ carp.cc \ cbdata.cc \ cbdata.h \ ChunkedCodingParser.cc \ ChunkedCodingParser.h \ + client_db.h \ client_db.cc \ + client_side.h \ client_side.cc \ client_side.h \ client_side_reply.cc \ @@ -302,6 +307,7 @@ Debug.h \ defines.h \ $(DELAY_POOL_SOURCE) \ + disk.h \ disk.cc \ $(DISKIO_SOURCE) \ dlink.h \ @@ -324,6 +330,7 @@ ExternalACLEntry.h \ FadingCounter.h \ FadingCounter.cc \ + fd.h \ fd.cc \ fde.cc \ fde.h \ @@ -331,10 +338,13 @@ filemap.cc \ forward.cc \ forward.h \ + fqdncache.h \ fqdncache.cc \ + ftp.h \ ftp.cc \ Generic.h \ globals.h \ + gopher.h \ gopher.cc \ helper.cc \ helper.h \ @@ -359,8 +369,8 @@ HttpHdrContRange.cc \ HttpHdrContRange.h \ HttpHeaderStat.h \ + HttpHeader.h \ HttpHeader.cc \ - HttpHeader.h \ HttpHeaderMask.h \ HttpHeaderRange.h \ HttpHeaderTools.h \ @@ -384,6 +394,7 @@ icp_v2.cc \ icp_v3.cc \ int.cc \ + internal.h \ internal.cc \ $(IPC_SOURCE) \ ipcache.cc \ @@ -392,6 +403,7 @@ list.cc \ lookup_t.h \ main.cc \ + Mem.h \ mem.cc \ mem_node.cc \ mem_node.h \ @@ -402,6 +414,7 @@ mime.cc \ mime_header.cc \ multicast.cc \ + neighbors.h \ neighbors.cc \ Packer.cc \ Packer.h \ @@ -414,12 +427,15 @@ peer_digest.cc \ peer_proxy_negotiate_auth.cc \ peer_select.cc \ + peer_sourcehash.h \ peer_sourcehash.cc \ + peer_userhash.h \ peer_userhash.cc \ PeerSelectState.h \ PingData.h \ protos.h \ redirect.cc \ + refresh.h \ refresh.cc \ RemovalPolicy.cc \ RemovalPolicy.h \ @@ -429,6 +445,7 @@ SquidMath.h \ SquidMath.cc \ SquidNew.cc \ + stat.h \ stat.cc \ StatCounters.h \ StatCounters.cc \ @@ -450,6 +467,7 @@ StoreClient.h \ store_digest.cc \ store_dir.cc \ + store_key_md5.h \ store_key_md5.cc \ store_log.cc \ store_rebuild.cc \ @@ -486,6 +504,7 @@ MemStore.h \ time.cc \ TimeOrTag.h \ + tools.h \ tools.cc \ tunnel.cc \ typedefs.h \ @@ -495,11 +514,14 @@ URLScheme.cc \ URLScheme.h \ urn.cc \ + wccp.h \ wccp.cc \ + wccp2.h \ wccp2.cc \ + whois.h \ whois.cc \ + wordlist.h \ wordlist.cc \ - wordlist.h \ $(WIN32_SOURCE) \ $(WINSVC_SOURCE) @@ -669,11 +691,13 @@ cbdata.cc \ debug.cc \ int.cc \ + Mem.h \ mem.cc \ MemBuf.cc \ MemBuf.cci \ MemBuf.h \ Parsing.h \ + store_key_md5.h \ store_key_md5.cc \ StoreMeta.cc \ StoreMetaMD5.cc \ @@ -693,6 +717,7 @@ HttpRequestMethod.cc \ RemovalPolicy.cc \ $(WIN32_SOURCE) \ + fd.h \ tests/stub_fd.cc ufsdump_LDADD = \ $(AUTH_ACL_LIBS) \ @@ -1070,9 +1095,10 @@ HttpHdrSc.h \ HttpHdrScTarget.cc \ HttpHdrScTarget.h \ + HttpHeader.h \ HttpHeader.cc \ - HttpHeader.h \ HttpHeaderMask.h \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpControlMsg.h \ HttpMsg.cc \ @@ -1082,6 +1108,7 @@ HttpStatusCode.h \ HttpStatusLine.cc \ HttpStatusLine.h \ + Mem.h \ mem.cc \ MemBuf.cc \ MemBuf.h \ @@ -1091,7 +1118,9 @@ SquidString.h \ SquidTime.h \ String.cc \ + log/access_log.h \ tests/stub_access_log.cc \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_cache_manager.cc \ tests/stub_debug.cc \ @@ -1104,6 +1133,7 @@ tests/stub_StatHist.cc \ tests/stub_store.cc \ tests/stub_store_stats.cc \ + tools.h \ tests/stub_tools.cc \ tests/stub_HttpRequest.cc \ tests/testHttpReply.cc \ @@ -1112,6 +1142,7 @@ time.cc \ url.cc \ URLScheme.cc \ + wordlist.h \ wordlist.cc nodist_tests_testHttpReply_SOURCES=\ $(TESTSOURCES) @@ -1150,7 +1181,9 @@ HelperChildConfig.h \ HelperChildConfig.cc \ HttpBody.cc \ + HttpHeader.h \ HttpHeader.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpHdrContRange.cc \ HttpHdrRange.cc \ @@ -1183,17 +1216,21 @@ StoreMetaURL.cc \ StoreMetaVary.cc \ StoreSwapLogData.cc \ + store_key_md5.h \ store_key_md5.cc \ swap_log_op.cc \ swap_log_op.h \ SwapDir.cc \ SwapDir.h \ + log/access_log.h \ tests/stub_access_log.cc \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_debug.cc \ tests/stub_DelayId.cc \ tests/stub_DiskIOModule.cc \ tests/stub_errorpage.cc \ + fd.h \ tests/stub_fd.cc \ tests/stub_HttpRequest.cc \ tests/stub_HttpReply.cc \ @@ -1210,6 +1247,7 @@ tests/stub_store_rebuild.cc \ tests/stub_store_stats.cc \ tests/stub_store_swapout.cc \ + tools.h \ tests/stub_tools.cc \ tests/stub_cache_manager.cc \ tests/stub_UdsOp.cc \ @@ -1221,8 +1259,10 @@ URL.h \ URLScheme.cc \ URLScheme.h \ + Mem.h \ mem.cc \ MemBuf.cc \ + wordlist.h \ wordlist.cc nodist_tests_testACLMaxUserIP_SOURCES= \ $(TESTSOURCES) @@ -1280,6 +1320,7 @@ HttpParser.h \ HttpRequest.cc \ HttpRequestMethod.cc \ + Mem.h \ mem.cc \ String.cc \ tests/testCacheManager.cc \ @@ -1291,12 +1332,17 @@ time.cc \ BodyPipe.cc \ cache_manager.cc \ + cache_cf.h \ cache_cf.cc \ + CacheDigest.h \ CacheDigest.cc \ + carp.h \ carp.cc \ cbdata.cc \ ChunkedCodingParser.cc \ + client_db.h \ client_db.cc \ + client_side.h \ client_side.cc \ client_side_reply.cc \ client_side_request.cc \ @@ -1310,6 +1356,7 @@ CpuAffinitySet.h \ $(DELAY_POOL_SOURCE) \ $(DISKIO_SOURCE) \ + disk.h \ disk.cc \ dlink.h \ dlink.cc \ @@ -1319,13 +1366,17 @@ event.cc \ external_acl.cc \ ExternalACLEntry.cc \ + fd.h \ fd.cc \ fde.cc \ FileMap.h \ filemap.cc \ forward.cc \ + fqdncache.h \ fqdncache.cc \ + ftp.h \ ftp.cc \ + gopher.h \ gopher.cc \ hier_code.h \ helper.cc \ @@ -1335,7 +1386,9 @@ http.cc \ HttpBody.h \ HttpBody.cc \ + HttpHeader.h \ HttpHeader.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpHdrCc.h \ HttpHdrCc.cc \ @@ -1352,6 +1405,7 @@ $(IPC_SOURCE) \ ipcache.cc \ int.cc \ + internal.h \ internal.cc \ list.cc \ multicast.cc \ @@ -1360,6 +1414,7 @@ MemObject.cc \ mime.cc \ mime_header.cc \ + neighbors.h \ neighbors.cc \ Packer.cc \ Parsing.cc \ @@ -1367,15 +1422,19 @@ peer_digest.cc \ peer_proxy_negotiate_auth.cc \ peer_select.cc \ + peer_sourcehash.h \ peer_sourcehash.cc \ + peer_userhash.h \ peer_userhash.cc \ redirect.cc \ + refresh.h \ refresh.cc \ RemovalPolicy.cc \ Server.cc \ $(SNMP_SOURCE) \ SquidMath.h \ SquidMath.cc \ + stat.h \ stat.cc \ StatCounters.h \ StatCounters.cc \ @@ -1387,6 +1446,7 @@ store_digest.cc \ store_dir.cc \ store_io.cc \ + store_key_md5.h \ store_key_md5.cc \ store_log.cc \ store_rebuild.cc \ @@ -1403,6 +1463,7 @@ StoreMetaURL.cc \ StoreMetaVary.cc \ StoreSwapLogData.cc \ + tools.h \ tools.cc \ tunnel.cc \ SwapDir.cc \ @@ -1411,10 +1472,13 @@ url.cc \ URLScheme.cc \ urn.cc \ + wccp2.h \ wccp2.cc \ + whois.h \ whois.cc \ FadingCounter.cc \ $(WIN32_SOURCE) \ + wordlist.h \ wordlist.cc nodist_tests_testCacheManager_SOURCES = \ $(BUILT_SOURCES) \ @@ -1462,17 +1526,21 @@ $(SQUID_CPPUNIT_LA) tests_testDiskIO_SOURCES = \ + CacheDigest.h \ CacheDigest.cc \ cbdata.cc \ + client_db.h \ ClientInfo.h \ ConfigOption.cc \ ConfigParser.cc \ $(DELAY_POOL_SOURCE) \ $(DISKIO_SOURCE) \ + disk.h \ disk.cc \ ETag.cc \ EventLoop.cc \ event.cc \ + fd.h \ fd.cc \ FileMap.h \ filemap.cc \ @@ -1485,7 +1553,9 @@ HttpHdrSc.cc \ HttpHdrScTarget.cc \ HttpHdrRange.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ + HttpHeader.h \ HttpHeader.cc \ HttpMsg.cc \ HttpReply.cc \ @@ -1496,9 +1566,11 @@ MemBuf.cc \ MemObject.cc \ mem_node.cc \ + Mem.h \ mem.cc \ Packer.cc \ Parsing.cc \ + refresh.h \ refresh.cc \ RemovalPolicy.cc \ StatCounters.h \ @@ -1518,14 +1590,17 @@ StoreSwapLogData.cc \ store_dir.cc \ store_io.cc \ + store_key_md5.h \ store_key_md5.cc \ store_swapout.cc \ store_swapmeta.cc \ store.cc \ String.cc \ SwapDir.cc \ + log/access_log.h \ tests/stub_access_log.cc \ tests/stub_acl.cc \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_cache_manager.cc \ tests/stub_client_db.cc \ @@ -1537,6 +1612,7 @@ tests/stub_HttpRequest.cc \ tests/stub_http.cc \ tests/stub_icp.cc \ + internal.h \ tests/stub_internal.cc \ tests/stub_ipc.cc \ tests/stub_ipcache.cc \ @@ -1549,6 +1625,7 @@ tests/stub_store_client.cc \ tests/stub_store_stats.cc \ tests/stub_store_rebuild.cc \ + tools.h \ tests/stub_tools.cc \ tests/stub_UdsOp.cc \ tests/testDiskIO.cc \ @@ -1561,6 +1638,7 @@ url.cc \ URLScheme.cc \ $(WIN32_SOURCE) \ + wordlist.h \ wordlist.cc nodist_tests_testDiskIO_SOURCES= \ $(TESTSOURCES) \ @@ -1612,13 +1690,18 @@ AccessLogEntry.cc \ $(ACL_REGISTRATION_SOURCES) \ BodyPipe.cc \ + CacheDigest.h \ CacheDigest.cc \ + cache_cf.h \ cache_cf.cc \ cache_manager.cc \ + carp.h \ carp.cc \ cbdata.cc \ ChunkedCodingParser.cc \ + client_db.h \ client_db.cc \ + client_side.h \ client_side.cc \ client_side_reply.cc \ client_side_request.cc \ @@ -1633,6 +1716,7 @@ debug.cc \ $(DELAY_POOL_SOURCE) \ $(DISKIO_SOURCE) \ + disk.h \ disk.cc \ dlink.h \ dlink.cc \ @@ -1645,13 +1729,17 @@ external_acl.cc \ ExternalACLEntry.cc \ FadingCounter.cc \ + fd.h \ fd.cc \ fde.cc \ FileMap.h \ filemap.cc \ forward.cc \ + fqdncache.h \ fqdncache.cc \ + ftp.h \ ftp.cc \ + gopher.h \ gopher.cc \ helper.cc \ HelperChildConfig.h \ @@ -1661,7 +1749,9 @@ http.cc \ HttpBody.h \ HttpBody.cc \ + HttpHeader.h \ HttpHeader.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpHdrCc.h \ HttpHdrCc.cc \ @@ -1682,8 +1772,10 @@ $(IPC_SOURCE) \ ipcache.cc \ int.cc \ + internal.h \ internal.cc \ list.cc \ + Mem.h \ mem.cc \ mem_node.cc \ MemBuf.cc \ @@ -1691,6 +1783,7 @@ mime.cc \ mime_header.cc \ multicast.cc \ + neighbors.h \ neighbors.cc \ Packer.cc \ Parsing.cc \ @@ -1698,15 +1791,19 @@ peer_digest.cc \ peer_proxy_negotiate_auth.cc \ peer_select.cc \ + peer_sourcehash.h \ peer_sourcehash.cc \ + peer_userhash.h \ peer_userhash.cc \ redirect.cc \ + refresh.h \ refresh.cc \ RemovalPolicy.cc \ Server.cc \ $(SNMP_SOURCE) \ SquidMath.cc \ SquidMath.h \ + stat.h \ stat.cc \ StatCounters.h \ StatCounters.cc \ @@ -1718,6 +1815,7 @@ store_digest.cc \ store_dir.cc \ store_io.cc \ + store_key_md5.h \ store_key_md5.cc \ store_log.cc \ store_rebuild.cc \ @@ -1744,6 +1842,7 @@ tests/stub_ipc_Forwarder.cc \ tests/stub_store_stats.cc \ time.cc \ + tools.h \ tools.cc \ tunnel.cc \ MemStore.cc \ @@ -1751,9 +1850,12 @@ url.cc \ URLScheme.cc \ urn.cc \ + wccp2.h \ wccp2.cc \ + whois.h \ whois.cc \ $(WIN32_SOURCE) \ + wordlist.h \ wordlist.cc nodist_tests_testEvent_SOURCES = \ $(BUILT_SOURCES) \ @@ -1804,13 +1906,18 @@ AccessLogEntry.cc \ $(ACL_REGISTRATION_SOURCES) \ BodyPipe.cc \ + CacheDigest.h \ CacheDigest.cc \ cache_manager.cc \ + cache_cf.h \ cache_cf.cc \ + carp.h \ carp.cc \ cbdata.cc \ ChunkedCodingParser.cc \ + client_db.h \ client_db.cc \ + client_side.h \ client_side.cc \ client_side_reply.cc \ client_side_request.cc \ @@ -1825,6 +1932,7 @@ debug.cc \ $(DELAY_POOL_SOURCE) \ $(DISKIO_SOURCE) \ + disk.h \ disk.cc \ dlink.h \ dlink.cc \ @@ -1837,13 +1945,17 @@ external_acl.cc \ ExternalACLEntry.cc \ FadingCounter.cc \ + fd.h \ fd.cc \ fde.cc \ FileMap.h \ filemap.cc \ forward.cc \ + fqdncache.h \ fqdncache.cc \ + ftp.h \ ftp.cc \ + gopher.h \ gopher.cc \ helper.cc \ HelperChildConfig.h \ @@ -1853,7 +1965,9 @@ http.cc \ HttpBody.h \ HttpBody.cc \ + HttpHeader.h \ HttpHeader.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpHdrCc.h \ HttpHdrCc.cc \ @@ -1874,15 +1988,18 @@ $(IPC_SOURCE) \ ipcache.cc \ int.cc \ + internal.h \ internal.cc \ list.cc \ MemBuf.cc \ MemObject.cc \ + Mem.h \ mem.cc \ mem_node.cc \ mime.cc \ mime_header.cc \ multicast.cc \ + neighbors.h \ neighbors.cc \ Packer.cc \ Parsing.cc \ @@ -1890,26 +2007,32 @@ peer_digest.cc \ peer_proxy_negotiate_auth.cc \ peer_select.cc \ + peer_sourcehash.h \ peer_sourcehash.cc \ + peer_userhash.h \ peer_userhash.cc \ RemovalPolicy.cc \ redirect.cc \ + refresh.h \ refresh.cc \ Server.cc \ $(SNMP_SOURCE) \ SquidMath.h \ SquidMath.cc \ + stat.h \ stat.cc \ StatCounters.h \ StatCounters.cc \ StatHist.h \ StatHist.cc \ + Mem.h \ stmem.cc \ store.cc \ store_client.cc \ store_digest.cc \ store_dir.cc \ store_io.cc \ + store_key_md5.h \ store_key_md5.cc \ store_log.cc \ store_rebuild.cc \ @@ -1935,6 +2058,7 @@ tests/stub_ipc_Forwarder.cc \ tests/stub_store_stats.cc \ time.cc \ + tools.h \ tools.cc \ tunnel.cc \ MemStore.cc \ @@ -1942,9 +2066,12 @@ url.cc \ URLScheme.cc \ urn.cc \ + wccp2.h \ wccp2.cc \ + whois.h \ whois.cc \ $(WIN32_SOURCE) \ + wordlist.h \ wordlist.cc nodist_tests_testEventLoop_SOURCES = \ $(BUILT_SOURCES) \ @@ -1994,13 +2121,18 @@ AccessLogEntry.cc \ $(ACL_REGISTRATION_SOURCES) \ BodyPipe.cc \ + cache_cf.h \ cache_cf.cc \ cache_manager.cc \ + CacheDigest.h \ CacheDigest.cc \ + carp.h \ carp.cc \ cbdata.cc \ ChunkedCodingParser.cc \ + client_db.h \ client_db.cc \ + client_side.h \ client_side.cc \ client_side_reply.cc \ client_side_request.cc \ @@ -2015,6 +2147,7 @@ debug.cc \ $(DELAY_POOL_SOURCE) \ $(DISKIO_SOURCE) \ + disk.h \ disk.cc \ dlink.h \ dlink.cc \ @@ -2025,13 +2158,17 @@ external_acl.cc \ ExternalACLEntry.cc \ FadingCounter.cc \ + fd.h \ fd.cc \ fde.cc \ FileMap.h \ filemap.cc \ forward.cc \ + fqdncache.h \ fqdncache.cc \ + ftp.h \ ftp.cc \ + gopher.h \ gopher.cc \ helper.cc \ HelperChildConfig.h \ @@ -2048,7 +2185,9 @@ HttpHdrRange.cc \ HttpHdrSc.cc \ HttpHdrScTarget.cc \ + HttpHeader.h \ HttpHeader.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpMsg.cc \ HttpParser.cc \ @@ -2060,33 +2199,40 @@ icp_v2.cc \ icp_v3.cc \ int.cc \ + internal.h \ internal.cc \ $(IPC_SOURCE) \ ipcache.cc \ list.cc \ MemBuf.cc \ MemObject.cc \ + Mem.h \ mem.cc \ mem_node.cc \ mime.cc \ mime_header.cc \ multicast.cc \ + neighbors.h \ neighbors.cc \ Packer.cc \ Parsing.cc \ peer_digest.cc \ peer_proxy_negotiate_auth.cc \ peer_select.cc \ + peer_sourcehash.h \ peer_sourcehash.cc \ + peer_userhash.h \ peer_userhash.cc \ pconn.cc \ redirect.cc \ + refresh.h \ refresh.cc \ RemovalPolicy.cc \ Server.cc \ $(SNMP_SOURCE) \ SquidMath.h \ SquidMath.cc \ + stat.h \ stat.cc \ StatCounters.h \ StatCounters.cc \ @@ -2097,6 +2243,7 @@ store_client.cc \ store_digest.cc \ store_dir.cc \ + store_key_md5.h \ store_key_md5.cc \ store_io.cc \ store_log.cc \ @@ -2122,15 +2269,19 @@ tests/stub_MemStore.cc \ tests/stub_store_stats.cc \ time.cc \ + tools.h \ tools.cc \ tunnel.cc \ $(UNLINKDSOURCE) \ url.cc \ URLScheme.cc \ urn.cc \ + wccp2.h \ wccp2.cc \ + whois.h \ whois.cc \ $(WIN32_SOURCE) \ + wordlist.h \ wordlist.cc nodist_tests_test_http_range_SOURCES = \ $(BUILT_SOURCES) \ @@ -2182,19 +2333,23 @@ HttpParser.h \ MemBuf.cc \ MemBuf.h \ + Mem.h \ mem.cc \ String.cc \ structs.h \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_cache_manager.cc \ tests/stub_debug.cc \ tests/stub_event.cc \ tests/stub_HelperChildConfig.cc \ + tools.h \ tests/stub_tools.cc \ tests/testHttpParser.cc \ tests/testHttpParser.h \ tests/testMain.cc \ time.cc \ + wordlist.h \ wordlist.cc nodist_tests_testHttpParser_SOURCES = \ $(TESTSOURCES) @@ -2218,6 +2373,7 @@ HttpParser.h \ HttpRequest.cc \ HttpRequestMethod.cc \ + Mem.h \ mem.cc \ String.cc \ tests/testHttpRequest.h \ @@ -2232,13 +2388,18 @@ time.cc \ BodyPipe.cc \ cache_manager.cc \ + cache_cf.h \ cache_cf.cc \ debug.cc \ + CacheDigest.h \ CacheDigest.cc \ + carp.h \ carp.cc \ cbdata.cc \ ChunkedCodingParser.cc \ + client_db.h \ client_db.cc \ + client_side.h \ client_side.cc \ client_side_reply.cc \ client_side_request.cc \ @@ -2251,6 +2412,7 @@ CpuAffinitySet.cc \ CpuAffinitySet.h \ $(DELAY_POOL_SOURCE) \ + disk.h \ disk.cc \ dlink.h \ dlink.cc \ @@ -2259,11 +2421,15 @@ ETag.cc \ external_acl.cc \ ExternalACLEntry.cc \ + fd.h \ fd.cc \ fde.cc \ forward.cc \ + fqdncache.h \ fqdncache.cc \ + ftp.h \ ftp.cc \ + gopher.h \ gopher.cc \ helper.cc \ HelperChildConfig.h \ @@ -2273,7 +2439,9 @@ http.cc \ HttpBody.h \ HttpBody.cc \ + HttpHeader.h \ HttpHeader.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpHdrCc.h \ HttpHdrCc.cc \ @@ -2290,6 +2458,7 @@ $(IPC_SOURCE) \ ipcache.cc \ int.cc \ + internal.h \ internal.cc \ list.cc \ multicast.cc \ @@ -2298,6 +2467,7 @@ MemObject.cc \ mime.cc \ mime_header.cc \ + neighbors.h \ neighbors.cc \ Packer.cc \ Parsing.cc \ @@ -2305,15 +2475,19 @@ peer_digest.cc \ peer_proxy_negotiate_auth.cc \ peer_select.cc \ + peer_sourcehash.h \ peer_sourcehash.cc \ + peer_userhash.h \ peer_userhash.cc \ redirect.cc \ + refresh.h \ refresh.cc \ RemovalPolicy.cc \ Server.cc \ $(SNMP_SOURCE) \ SquidMath.h \ SquidMath.cc \ + stat.h \ stat.cc \ StatCounters.h \ StatCounters.cc \ @@ -2325,6 +2499,7 @@ store_digest.cc \ store_dir.cc \ store_io.cc \ + store_key_md5.h \ store_key_md5.cc \ store_log.cc \ store_rebuild.cc \ @@ -2342,6 +2517,7 @@ StoreMetaVary.cc \ StoreSwapLogData.cc \ event.cc \ + tools.h \ tools.cc \ tunnel.cc \ SwapDir.cc \ @@ -2349,10 +2525,13 @@ url.cc \ URLScheme.cc \ urn.cc \ + wccp2.h \ wccp2.cc \ + whois.h \ whois.cc \ FadingCounter.cc \ $(WIN32_SOURCE) \ + wordlist.h \ wordlist.cc nodist_tests_testHttpRequest_SOURCES = \ $(BUILT_SOURCES) @@ -2399,12 +2578,14 @@ ## why so many sources? well httpHeaderTools requites ACLChecklist & friends. ## first line - what we are testing. tests_testStore_SOURCES= \ + CacheDigest.h \ CacheDigest.cc \ cbdata.cc \ ClientInfo.h \ ConfigOption.cc \ ConfigParser.cc \ $(DELAY_POOL_SOURCE) \ + disk.h \ disk.cc \ DiskIO/ReadRequest.cc \ DiskIO/WriteRequest.cc \ @@ -2420,12 +2601,15 @@ HttpHdrRange.cc \ HttpHdrSc.cc \ HttpHdrScTarget.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ + HttpHeader.h \ HttpHeader.cc \ HttpMsg.cc \ HttpRequestMethod.cc \ int.cc \ list.cc \ + Mem.h \ mem.cc \ mem_node.cc \ MemBuf.cc \ @@ -2433,6 +2617,7 @@ Packer.cc \ Parsing.cc \ RemovalPolicy.cc \ + refresh.h \ refresh.cc \ StatCounters.h \ StatCounters.cc \ @@ -2452,12 +2637,15 @@ StoreMetaURL.cc \ StoreMetaVary.cc \ StoreSwapLogData.cc \ + store_key_md5.h \ store_key_md5.cc \ String.cc \ SwapDir.cc \ tests/CapturingStoreEntry.h \ + log/access_log.h \ tests/stub_access_log.cc \ tests/stub_acl.cc \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_cache_manager.cc \ tests/stub_client_side_request.cc \ @@ -2465,6 +2653,7 @@ tests/stub_debug.cc \ tests/stub_DiskIOModule.cc \ tests/stub_errorpage.cc \ + fd.h \ tests/stub_fd.cc \ tests/stub_helper.cc \ tests/stub_HelperChildConfig.cc \ @@ -2482,6 +2671,7 @@ tests/stub_store_stats.cc \ tests/stub_store_rebuild.cc \ tests/stub_store_swapout.cc \ + tools.h \ tests/stub_tools.cc \ tests/stub_UdsOp.cc \ tests/testMain.cc \ @@ -2500,6 +2690,7 @@ time.cc \ url.cc \ URLScheme.cc \ + wordlist.h \ wordlist.cc nodist_tests_testStore_SOURCES= \ @@ -2543,18 +2734,22 @@ ## libsquid pulls in SquidConfig and children. stub them. tests_testString_SOURCES = \ ClientInfo.h \ + Mem.h \ mem.cc \ MemBuf.cc \ String.cc \ tests/testMain.cc \ tests/testString.cc \ tests/testString.h \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_cache_manager.cc \ tests/stub_debug.cc \ tests/stub_HelperChildConfig.cc \ + tools.h \ tests/stub_tools.cc \ time.cc \ + wordlist.h \ wordlist.cc nodist_tests_testString_SOURCES = \ $(TESTSOURCES) @@ -2604,11 +2799,15 @@ tests/stub_pconn.cc \ tests/stub_Port.cc \ tests/stub_UdsOp.cc \ + internal.h \ tests/stub_internal.cc \ tests/stub_libformat.cc \ tests/stub_store_rebuild.cc \ tests/stub_store_stats.cc \ + fd.h \ fd.cc \ + client_db.h \ + disk.h \ disk.cc \ FileMap.h \ filemap.cc \ @@ -2636,6 +2835,7 @@ $(WIN32_SOURCE) \ event.cc \ $(DELAY_POOL_SOURCE) \ + CacheDigest.h \ CacheDigest.cc \ ConfigParser.cc \ EventLoop.cc \ @@ -2644,11 +2844,13 @@ store_dir.cc \ store.cc \ HttpRequestMethod.cc \ + store_key_md5.h \ store_key_md5.cc \ Parsing.cc \ ConfigOption.cc \ SwapDir.cc \ tests/stub_acl.cc \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_helper.cc \ cbdata.cc \ @@ -2659,8 +2861,11 @@ mem_node.cc \ stmem.cc \ tests/stub_mime.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ + HttpHeader.h \ HttpHeader.cc \ + Mem.h \ mem.cc \ ClientInfo.h \ MemBuf.cc \ @@ -2680,14 +2885,18 @@ ETag.cc \ tests/stub_errorpage.cc \ tests/stub_HttpRequest.cc \ + log/access_log.h \ tests/stub_access_log.cc \ + refresh.h \ refresh.cc \ tests/stub_store_client.cc \ + tools.h \ tests/stub_tools.cc \ tests/testStoreSupport.cc \ tests/testStoreSupport.h \ time.cc \ URLScheme.cc \ + wordlist.h \ wordlist.cc \ $(DISKIO_SOURCE) @@ -2736,13 +2945,16 @@ tests_testRock_SOURCES = \ cbdata.cc \ + CacheDigest.h \ CacheDigest.cc \ ConfigOption.cc \ ConfigParser.cc \ + disk.h \ disk.cc \ ETag.cc \ EventLoop.cc \ event.cc \ + fd.h \ fd.cc \ FileMap.h \ filemap.cc \ @@ -2753,7 +2965,9 @@ HttpHdrRange.cc \ HttpHdrSc.cc \ HttpHdrScTarget.cc \ + HttpHeader.h \ HttpHeader.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpMsg.cc \ HttpReply.cc \ @@ -2761,6 +2975,7 @@ HttpStatusLine.cc \ int.cc \ list.cc \ + Mem.h \ mem.cc \ MemBuf.cc \ MemObject.cc \ @@ -2786,6 +3001,7 @@ StoreSwapLogData.cc \ store_dir.cc \ store_io.cc \ + store_key_md5.h \ store_key_md5.cc \ store_swapmeta.cc \ store_swapout.cc \ @@ -2796,9 +3012,12 @@ tests/testRock.h \ tests/testStoreSupport.cc \ tests/testStoreSupport.h \ + log/access_log.h \ tests/stub_access_log.cc \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_cache_manager.cc \ + client_db.h \ tests/stub_client_db.cc \ tests/stub_client_side_request.cc \ tests/stub_debug.cc \ @@ -2818,10 +3037,12 @@ tests/stub_store_client.cc \ tests/stub_store_rebuild.cc \ tests/stub_store_stats.cc \ + tools.h \ tests/stub_tools.cc \ time.cc \ url.cc \ URLScheme.cc \ + wordlist.h \ wordlist.cc \ $(DELAY_POOL_SOURCE) \ $(DISKIO_SOURCE) \ @@ -2868,15 +3089,19 @@ tests/testMain.cc \ tests/testCoss.h \ tests/stub_cache_manager.cc \ + client_db.h \ tests/stub_client_db.cc \ tests/stub_debug.cc \ tests/stub_HelperChildConfig.cc \ + internal.h \ tests/stub_internal.cc \ tests/stub_ipc.cc \ tests/stub_pconn.cc \ tests/stub_store_rebuild.cc \ tests/stub_store_stats.cc \ + fd.h \ fd.cc \ + disk.h \ disk.cc \ FileMap.h \ filemap.cc \ @@ -2904,6 +3129,7 @@ $(WIN32_SOURCE) \ event.cc \ $(DELAY_POOL_SOURCE) \ + CacheDigest.h \ CacheDigest.cc \ ConfigParser.cc \ EventLoop.cc \ @@ -2912,11 +3138,13 @@ store_dir.cc \ store.cc \ HttpRequestMethod.cc \ + store_key_md5.h \ store_key_md5.cc \ Parsing.cc \ ConfigOption.cc \ SwapDir.cc \ tests/stub_acl.cc \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_helper.cc \ cbdata.cc \ @@ -2926,8 +3154,11 @@ mem_node.cc \ stmem.cc \ tests/stub_mime.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ + HttpHeader.h \ HttpHeader.cc \ + Mem.h \ mem.cc \ ClientInfo.h \ MemBuf.cc \ @@ -2945,18 +3176,22 @@ tests/stub_StatHist.cc \ tests/stub_errorpage.cc \ tests/stub_HttpRequest.cc \ + log/access_log.h \ tests/stub_access_log.cc \ + refresh.h \ refresh.cc \ tests/stub_MemStore.cc \ tests/stub_Port.cc \ tests/stub_store_client.cc \ tests/stub_store_stats.cc \ + tools.h \ tests/stub_tools.cc \ tests/stub_UdsOp.cc \ tests/testStoreSupport.cc \ tests/testStoreSupport.h \ time.cc \ URLScheme.cc \ + wordlist.h \ wordlist.cc \ $(DISKIO_SOURCE) @@ -3006,10 +3241,13 @@ tests/testNull.cc \ tests/testMain.cc \ tests/testNull.h \ + internal.h \ tests/stub_internal.cc \ tests/stub_store_rebuild.cc \ tests/stub_store_stats.cc \ + fd.h \ fd.cc \ + disk.h \ disk.cc \ FileMap.h \ filemap.cc \ @@ -3037,6 +3275,7 @@ $(WIN32_SOURCE) \ event.cc \ $(DELAY_POOL_SOURCE) \ + CacheDigest.h \ CacheDigest.cc \ ConfigParser.cc \ EventLoop.cc \ @@ -3045,11 +3284,13 @@ store_dir.cc \ store.cc \ HttpRequestMethod.cc \ + store_key_md5.h \ store_key_md5.cc \ Parsing.cc \ ConfigOption.cc \ SwapDir.cc \ tests/stub_acl.cc \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_helper.cc \ cbdata.cc \ @@ -3061,8 +3302,11 @@ mem_node.cc \ stmem.cc \ tests/stub_mime.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ + HttpHeader.h \ HttpHeader.cc \ + Mem.h \ mem.cc \ ClientInfo.h \ MemBuf.cc \ @@ -3080,15 +3324,19 @@ tests/stub_StatHist.cc \ tests/stub_errorpage.cc \ tests/stub_HttpRequest.cc \ + log/access_log.h \ tests/stub_access_log.cc \ + refresh.h \ refresh.cc \ tests/stub_store_client.cc \ tests/stub_store_stats.cc \ + tools.h \ tests/stub_tools.cc \ tests/testStoreSupport.cc \ tests/testStoreSupport.h \ time.cc \ URLScheme.cc \ + wordlist.h \ wordlist.cc \ $(DISKIO_SOURCE) @@ -3131,13 +3379,18 @@ AccessLogEntry.cc \ $(ACL_REGISTRATION_SOURCES) \ BodyPipe.cc \ + cache_cf.h \ cache_cf.cc \ cache_manager.cc \ + CacheDigest.h \ CacheDigest.cc \ + carp.h \ carp.cc \ cbdata.cc \ ChunkedCodingParser.cc \ + client_db.h \ client_db.cc \ + client_side.h \ client_side.cc \ client_side_reply.cc \ client_side_request.cc \ @@ -3150,6 +3403,7 @@ CpuAffinitySet.cc \ CpuAffinitySet.h \ $(DELAY_POOL_SOURCE) \ + disk.h \ disk.cc \ DiskIO/ReadRequest.cc \ DiskIO/WriteRequest.cc \ @@ -3161,13 +3415,17 @@ event.cc \ external_acl.cc \ ExternalACLEntry.cc \ + fd.h \ fd.cc \ fde.cc \ FileMap.h \ filemap.cc \ forward.cc \ + fqdncache.h \ fqdncache.cc \ + ftp.h \ ftp.cc \ + gopher.h \ gopher.cc \ helper.cc \ HelperChildConfig.h \ @@ -3184,7 +3442,9 @@ HttpHdrRange.cc \ HttpHdrSc.cc \ HttpHdrScTarget.cc \ + HttpHeader.h \ HttpHeader.cc \ + HttpHeaderTools.h \ HttpHeaderTools.cc \ HttpMsg.cc \ HttpParser.cc \ @@ -3198,15 +3458,18 @@ $(IPC_SOURCE) \ ipcache.cc \ int.cc \ + internal.h \ internal.cc \ list.cc \ multicast.cc \ + Mem.h \ mem.cc \ mem_node.cc \ MemBuf.cc \ MemObject.cc \ mime.cc \ mime_header.cc \ + neighbors.h \ neighbors.cc \ Packer.cc \ Parsing.cc \ @@ -3214,15 +3477,19 @@ peer_digest.cc \ peer_proxy_negotiate_auth.cc \ peer_select.cc \ + peer_sourcehash.h \ peer_sourcehash.cc \ + peer_userhash.h \ peer_userhash.cc \ redirect.cc \ + refresh.h \ refresh.cc \ RemovalPolicy.cc \ Server.cc \ $(SNMP_SOURCE) \ SquidMath.h \ SquidMath.cc \ + stat.h \ stat.cc \ StatCounters.h \ StatCounters.cc \ @@ -3234,6 +3501,7 @@ store_digest.cc \ store_dir.cc \ store_io.cc \ + store_key_md5.h \ store_key_md5.cc \ store_log.cc \ store_rebuild.cc \ @@ -3264,15 +3532,19 @@ tests/testURLScheme.h \ tests/testMain.cc \ time.cc \ + tools.h \ tools.cc \ tunnel.cc \ url.cc \ URLScheme.cc \ urn.cc \ + wccp2.h \ wccp2.cc \ + whois.h \ whois.cc \ FadingCounter.cc \ $(WIN32_SOURCE) \ + wordlist.h \ wordlist.cc nodist_tests_testURL_SOURCES = \ $(BUILT_SOURCES) @@ -3319,6 +3591,7 @@ tests_testConfigParser_SOURCES = \ ClientInfo.h \ + Mem.h \ mem.cc \ MemBuf.cc \ String.cc \ @@ -3326,12 +3599,15 @@ tests/testMain.cc \ tests/testConfigParser.cc \ tests/testConfigParser.h \ + cache_cf.h \ tests/stub_cache_cf.cc \ tests/stub_cache_manager.cc \ tests/stub_debug.cc \ tests/stub_HelperChildConfig.cc \ + tools.h \ tests/stub_tools.cc \ time.cc \ + wordlist.h \ wordlist.cc nodist_tests_testConfigParser_SOURCES = \ $(TESTSOURCES) @@ -3360,6 +3636,7 @@ tests/stub_debug.cc \ tests/stub_DelayId.cc \ tests/stub_HelperChildConfig.cc \ + Mem.h \ tests/stub_mem.cc \ tests/stub_MemObject.cc \ tests/stub_mime.cc \ @@ -3367,6 +3644,7 @@ tests/stub_stmem.cc \ tests/stub_store.cc \ tests/stub_store_stats.cc \ + tools.h \ tests/stub_tools.cc \ tests/testMain.cc \ tests/testStatHist.cc \ === modified file 'src/Mem.h' --- src/Mem.h 2011-03-30 16:44:16 +0000 +++ src/Mem.h 2012-08-28 19:12:13 +0000 @@ -34,6 +34,11 @@ #ifndef SQUID_MEM #define SQUID_MEM +/* for mem_type */ +#include "enums.h" +/* for FREE */ +#include "typedefs.h" + #if HAVE_IOSFWD #include #endif @@ -59,4 +64,21 @@ extern const size_t squidSystemPageSize; +extern void memClean(void); +extern void memInitModule(void); +extern void memCleanModule(void); +extern void memConfigure(void); +extern void *memAllocate(mem_type); +extern void *memAllocString(size_t net_size, size_t * gross_size); +extern void *memAllocBuf(size_t net_size, size_t * gross_size); +extern void *memReallocBuf(void *buf, size_t net_size, size_t * gross_size); +extern void memFree(void *, int type); +extern void memFreeString(size_t size, void *); +extern void memFreeBuf(size_t size, void *); +extern FREE *memFreeBufFunc(size_t size); +extern int memInUse(mem_type); +extern void memDataInit(mem_type, const char *, size_t, int, bool zeroOnPush = true); +extern void memCheckInit(void); +extern void memConfigure(void); + #endif /* SQUID_MEM */ === modified file 'src/MemBuf.cc' --- src/MemBuf.cc 2012-08-28 13:00:30 +0000 +++ src/MemBuf.cc 2012-08-28 19:12:13 +0000 @@ -100,6 +100,7 @@ */ #include "squid.h" +#include "Mem.h" #include "MemBuf.h" #include "profiler/Profiler.h" #include "protos.h" === modified file 'src/Parsing.cc' --- src/Parsing.cc 2012-08-14 11:53:07 +0000 +++ src/Parsing.cc 2012-08-28 19:12:13 +0000 @@ -33,6 +33,7 @@ */ #include "squid.h" +#include "cache_cf.h" #include "compat/strtoll.h" #include "Parsing.h" #include "protos.h" === modified file 'src/PeerDigest.h' --- src/PeerDigest.h 2012-08-14 11:53:07 +0000 +++ src/PeerDigest.h 2012-08-28 19:12:13 +0000 @@ -131,6 +131,12 @@ extern const Version CacheDigestVer; +extern PeerDigest *peerDigestCreate(peer * p); +extern void peerDigestNeeded(PeerDigest * pd); +extern void peerDigestNotePeerGone(PeerDigest * pd); +extern void peerDigestStatsReport(const PeerDigest * pd, StoreEntry * e); + + #endif /* USE_CACHE_DIGESTS */ #endif /* SQUID_PEERDIGEST_H */ === modified file 'src/Server.cc' --- src/Server.cc 2012-08-28 13:00:30 +0000 +++ src/Server.cc 2012-08-28 19:12:13 +0000 @@ -38,6 +38,7 @@ #include "comm/Connection.h" #include "comm/forward.h" #include "comm/Write.h" +#include "fd.h" #include "err_detail_type.h" #include "errorpage.h" #include "HttpReply.h" @@ -47,6 +48,8 @@ #include "SquidTime.h" #include "StatCounters.h" #include "Store.h" +#include "tools.h" +#include "URL.h" #if USE_ADAPTATION #include "adaptation/AccessCheck.h" === modified file 'src/String.cc' --- src/String.cc 2012-08-28 13:00:30 +0000 +++ src/String.cc 2012-08-28 19:12:13 +0000 @@ -35,6 +35,7 @@ #include "squid.h" #include "base/TextException.h" +#include "Mem.h" #include "mgr/Registration.h" #include "profiler/Profiler.h" #include "protos.h" === modified file 'src/SwapDir.cc' --- src/SwapDir.cc 2012-08-28 13:00:30 +0000 +++ src/SwapDir.cc 2012-08-28 19:12:13 +0000 @@ -33,8 +33,10 @@ */ #include "squid.h" +#include "cache_cf.h" #include "compat/strtoll.h" #include "ConfigOption.h" +#include "Parsing.h" #include "protos.h" #include "StoreFileSystem.h" #include "SwapDir.h" === modified file 'src/URL.h' --- src/URL.h 2011-06-01 02:34:24 +0000 +++ src/URL.h 2012-08-28 19:12:13 +0000 @@ -33,6 +33,7 @@ #ifndef SQUID_SRC_URL_H #define SQUID_SRC_URL_H +#include "anyp/ProtocolType.h" #include "MemPool.h" #include "URLScheme.h" @@ -77,4 +78,24 @@ MEMPROXY_CLASS_INLINE(URL); +class HttpRequest; +class HttpRequestMethod; + + +extern AnyP::ProtocolType urlParseProtocol(const char *, const char *e = NULL); +extern void urlInitialize(void); +extern HttpRequest *urlParse(const HttpRequestMethod&, char *, HttpRequest *request = NULL); +extern const char *urlCanonical(HttpRequest *); +extern char *urlCanonicalClean(const HttpRequest *); +extern const char *urlCanonicalFakeHttps(const HttpRequest * request); +extern bool urlIsRelative(const char *); +extern char *urlMakeAbsolute(const HttpRequest *, const char *); +extern char *urlRInternal(const char *host, unsigned short port, const char *dir, const char *name); +extern char *urlInternal(const char *dir, const char *name); +extern int matchDomainName(const char *host, const char *domain); +extern int urlCheckRequest(const HttpRequest *); +extern int urlDefaultPort(AnyP::ProtocolType p); +extern char *urlHostname(const char *url); +extern void urlExtMethodConfigure(void); + #endif /* SQUID_SRC_URL_H_H */ === modified file 'src/acl/CertificateData.cc' --- src/acl/CertificateData.cc 2012-08-14 11:53:07 +0000 +++ src/acl/CertificateData.cc 2012-08-28 19:12:13 +0000 @@ -37,6 +37,7 @@ #include "squid.h" #include "acl/CertificateData.h" #include "acl/Checklist.h" +#include "cache_cf.h" #include "protos.h" #include "wordlist.h" === modified file 'src/acl/DestinationDomain.cc' --- src/acl/DestinationDomain.cc 2012-08-28 13:00:30 +0000 +++ src/acl/DestinationDomain.cc 2012-08-28 19:12:13 +0000 @@ -39,6 +39,7 @@ #include "acl/Checklist.h" #include "acl/RegexData.h" #include "acl/DomainData.h" +#include "fqdncache.h" #include "HttpRequest.h" #include "ipcache.h" #include "protos.h" === modified file 'src/acl/DomainData.cc' --- src/acl/DomainData.cc 2012-08-28 13:00:30 +0000 +++ src/acl/DomainData.cc 2012-08-28 19:12:13 +0000 @@ -37,9 +37,11 @@ #include "squid.h" #include "acl/DomainData.h" #include "acl/Checklist.h" +#include "cache_cf.h" #include "Debug.h" #include "protos.h" #include "wordlist.h" +#include "URL.h" template inline void === modified file 'src/acl/Gadgets.cc' --- src/acl/Gadgets.cc 2012-08-28 13:00:30 +0000 +++ src/acl/Gadgets.cc 2012-08-28 19:12:13 +0000 @@ -47,6 +47,7 @@ #include "errorpage.h" #include "globals.h" #include "HttpRequest.h" +#include "Mem.h" #include "protos.h" /* does name lookup, returns page_id */ === modified file 'src/acl/HttpHeaderData.cc' --- src/acl/HttpHeaderData.cc 2012-08-14 11:53:07 +0000 +++ src/acl/HttpHeaderData.cc 2012-08-28 19:12:13 +0000 @@ -43,6 +43,7 @@ #include "protos.h" #include "wordlist.h" #include "ConfigParser.h" +#include "HttpHeaderTools.h" /* Construct an ACLHTTPHeaderData that uses an ACLRegex rule with the value of the * selected header from a given request. === modified file 'src/acl/IntRange.cc' --- src/acl/IntRange.cc 2012-08-14 11:53:07 +0000 +++ src/acl/IntRange.cc 2012-08-28 19:12:13 +0000 @@ -36,6 +36,7 @@ #include "squid.h" #include "acl/IntRange.h" +#include "cache_cf.h" #include "Debug.h" #include "wordlist.h" #include "Parsing.h" === modified file 'src/acl/Ip.cc' --- src/acl/Ip.cc 2012-08-28 13:00:30 +0000 +++ src/acl/Ip.cc 2012-08-28 19:12:13 +0000 @@ -36,6 +36,7 @@ #include "squid.h" #include "acl/Ip.h" #include "acl/Checklist.h" +#include "cache_cf.h" #include "Debug.h" #include "ip/tools.h" #include "MemBuf.h" === modified file 'src/acl/MaxConnection.cc' --- src/acl/MaxConnection.cc 2012-08-14 11:53:07 +0000 +++ src/acl/MaxConnection.cc 2012-08-28 19:12:13 +0000 @@ -37,6 +37,7 @@ #include "squid.h" #include "acl/FilledChecklist.h" #include "acl/MaxConnection.h" +#include "client_db.h" #include "Debug.h" #include "protos.h" #include "wordlist.h" === modified file 'src/acl/Random.cc' --- src/acl/Random.cc 2012-08-14 11:53:07 +0000 +++ src/acl/Random.cc 2012-08-28 19:12:13 +0000 @@ -36,7 +36,9 @@ #include "acl/FilledChecklist.h" #include "acl/Random.h" +#include "cache_cf.h" #include "Debug.h" +#include "Parsing.h" #include "protos.h" #include "wordlist.h" === modified file 'src/acl/RegexData.cc' --- src/acl/RegexData.cc 2012-08-14 11:53:07 +0000 +++ src/acl/RegexData.cc 2012-08-28 19:12:13 +0000 @@ -42,6 +42,7 @@ #include "acl/Acl.h" #include "ConfigParser.h" #include "Debug.h" +#include "Mem.h" #include "protos.h" #include "wordlist.h" === modified file 'src/acl/SourceDomain.cc' --- src/acl/SourceDomain.cc 2012-08-28 13:00:30 +0000 +++ src/acl/SourceDomain.cc 2012-08-28 19:12:13 +0000 @@ -39,6 +39,7 @@ #include "acl/Checklist.h" #include "acl/RegexData.h" #include "acl/DomainData.h" +#include "fqdncache.h" #include "HttpRequest.h" #include "protos.h" === modified file 'src/acl/TimeData.cc' --- src/acl/TimeData.cc 2012-08-14 11:53:07 +0000 +++ src/acl/TimeData.cc 2012-08-28 19:12:13 +0000 @@ -37,6 +37,7 @@ #include "squid.h" #include "acl/TimeData.h" #include "acl/Checklist.h" +#include "cache_cf.h" #include "Debug.h" #include "protos.h" #include "wordlist.h" === modified file 'src/acl/Url.cc' --- src/acl/Url.cc 2012-08-14 11:53:07 +0000 +++ src/acl/Url.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,7 @@ #include "acl/RegexData.h" #include "protos.h" #include "rfc1738.h" +#include "URL.h" int ACLUrlStrategy::match (ACLData * &data, ACLFilledChecklist *checklist) === modified file 'src/adaptation/ecap/MessageRep.cc' --- src/adaptation/ecap/MessageRep.cc 2012-08-28 13:00:30 +0000 +++ src/adaptation/ecap/MessageRep.cc 2012-08-28 19:12:13 +0000 @@ -14,6 +14,7 @@ #include "adaptation/ecap/XactionRep.h" #include "adaptation/ecap/Host.h" /* for protocol constants */ #include "base/TextException.h" +#include "URL.h" /* HeaderRep */ === modified file 'src/adaptation/icap/ModXact.cc' --- src/adaptation/icap/ModXact.cc 2012-08-28 13:00:30 +0000 +++ src/adaptation/icap/ModXact.cc 2012-08-28 19:12:13 +0000 @@ -20,11 +20,13 @@ #include "comm.h" #include "comm/Connection.h" #include "err_detail_type.h" +#include "HttpHeaderTools.h" #include "HttpMsg.h" #include "HttpReply.h" #include "HttpRequest.h" #include "protos.h" #include "SquidTime.h" +#include "URL.h" // flow and terminology: // HTTP| --> receive --> encode --> write --> |network === modified file 'src/adaptation/icap/OptXact.cc' --- src/adaptation/icap/OptXact.cc 2012-08-28 13:00:30 +0000 +++ src/adaptation/icap/OptXact.cc 2012-08-28 19:12:13 +0000 @@ -9,6 +9,7 @@ #include "adaptation/icap/OptXact.h" #include "base/TextException.h" #include "comm.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "protos.h" === modified file 'src/adaptation/icap/Xaction.cc' --- src/adaptation/icap/Xaction.cc 2012-08-28 13:00:30 +0000 +++ src/adaptation/icap/Xaction.cc 2012-08-28 19:12:13 +0000 @@ -21,6 +21,7 @@ #include "HttpRequest.h" #include "icap_log.h" #include "ipcache.h" +#include "Mem.h" #include "pconn.h" #include "protos.h" #include "SquidTime.h" === modified file 'src/auth/AclMaxUserIp.cc' --- src/auth/AclMaxUserIp.cc 2012-08-14 11:53:07 +0000 +++ src/auth/AclMaxUserIp.cc 2012-08-28 19:12:13 +0000 @@ -12,6 +12,7 @@ #include "protos.h" #include "wordlist.h" #include "ConfigParser.h" +#include "Parsing.h" ACL * ACLMaxUserIP::clone() const === modified file 'src/auth/basic/auth_basic.cc' --- src/auth/basic/auth_basic.cc 2012-08-28 13:00:30 +0000 +++ src/auth/basic/auth_basic.cc 2012-08-28 19:12:13 +0000 @@ -43,9 +43,11 @@ #include "auth/basic/UserRequest.h" #include "auth/Gadgets.h" #include "auth/State.h" +#include "cache_cf.h" #include "charset.h" #include "mgr/Registration.h" #include "Store.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "protos.h" #include "rfc1738.h" === modified file 'src/auth/digest/UserRequest.cc' --- src/auth/digest/UserRequest.cc 2012-08-14 11:53:07 +0000 +++ src/auth/digest/UserRequest.cc 2012-08-28 19:12:13 +0000 @@ -4,6 +4,7 @@ #include "auth/digest/UserRequest.h" #include "auth/State.h" #include "charset.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "protos.h" === modified file 'src/auth/digest/auth_digest.cc' --- src/auth/digest/auth_digest.cc 2012-08-28 13:00:30 +0000 +++ src/auth/digest/auth_digest.cc 2012-08-28 19:12:13 +0000 @@ -37,6 +37,7 @@ * See acl.c for access control and client_side.c for auditing */ #include "squid.h" +#include "cache_cf.h" #include "rfc2617.h" #include "auth/digest/auth_digest.h" #include "auth/digest/Scheme.h" @@ -47,6 +48,7 @@ #include "base64.h" #include "base/StringArea.h" #include "event.h" +#include "HttpHeaderTools.h" #include "mgr/Registration.h" #include "Store.h" #include "HttpRequest.h" === modified file 'src/auth/negotiate/UserRequest.cc' --- src/auth/negotiate/UserRequest.cc 2012-08-23 01:33:16 +0000 +++ src/auth/negotiate/UserRequest.cc 2012-08-28 19:12:13 +0000 @@ -6,6 +6,7 @@ #include "client_side.h" #include "globals.h" #include "helper.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "protos.h" === modified file 'src/auth/negotiate/auth_negotiate.cc' --- src/auth/negotiate/auth_negotiate.cc 2012-08-28 13:00:30 +0000 +++ src/auth/negotiate/auth_negotiate.cc 2012-08-28 19:12:13 +0000 @@ -40,9 +40,11 @@ #include "auth/negotiate/auth_negotiate.h" #include "auth/Gadgets.h" #include "auth/State.h" +#include "cache_cf.h" #include "mgr/Registration.h" #include "Store.h" #include "client_side.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "protos.h" === modified file 'src/auth/ntlm/auth_ntlm.cc' --- src/auth/ntlm/auth_ntlm.cc 2012-08-28 13:00:30 +0000 +++ src/auth/ntlm/auth_ntlm.cc 2012-08-28 19:12:13 +0000 @@ -43,9 +43,11 @@ #include "auth/ntlm/User.h" #include "auth/ntlm/UserRequest.h" #include "auth/State.h" +#include "cache_cf.h" #include "mgr/Registration.h" #include "Store.h" #include "client_side.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "protos.h" === modified file 'src/cache_cf.cc' --- src/cache_cf.cc 2012-08-28 13:00:30 +0000 +++ src/cache_cf.cc 2012-08-28 19:12:13 +0000 @@ -38,12 +38,15 @@ #include "acl/MethodData.h" #include "anyp/PortCfg.h" #include "base/RunnersRegistry.h" +#include "cache_cf.h" #include "ConfigParser.h" #include "CpuAffinityMap.h" #include "DiskIO/DiskIOModule.h" #include "eui/Config.h" +#include "ExternalACL.h" #include "format/Format.h" #include "globals.h" +#include "HttpHeaderTools.h" #include "HttpRequestMethod.h" #include "ident/Config.h" #include "ip/Intercept.h" @@ -51,9 +54,11 @@ #include "ip/tools.h" #include "ipc/Kids.h" #include "log/Config.h" +#include "Mem.h" #include "MemBuf.h" #include "mgr/Registration.h" #include "Parsing.h" +#include "PeerDigest.h" #include "protos.h" #include "rfc1738.h" #include "Store.h" @@ -61,6 +66,10 @@ #include "structs.h" #include "SwapDir.h" #include "wordlist.h" +#include "neighbors.h" +#include "tools.h" +/* wccp2 has its own conditional definitions */ +#include "wccp2.h" #if USE_ADAPTATION #include "adaptation/Config.h" #endif @@ -88,11 +97,9 @@ #if HAVE_GLOB_H #include #endif - #if HAVE_LIMITS_H #include #endif - #if HAVE_LIST #include #endif === added file 'src/cache_cf.h' --- src/cache_cf.h 1970-01-01 00:00:00 +0000 +++ src/cache_cf.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,51 @@ +/* + * DEBUG: section 03 Configuration File Parsing + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_CACHE_CF_H_ +#define SQUID_CACHE_CF_H_ + +class wordlist; + +extern void configFreeMemory(void); +extern void self_destruct(void); +extern void add_http_port(char *portspec); + +/* extra functions from cache_cf.c useful for lib modules */ +extern void parse_int(int *var); +extern void parse_onoff(int *var); +extern void parse_eol(char *volatile *var); +extern void parse_wordlist(wordlist ** list); +extern void requirePathnameExists(const char *name, const char *path); +extern void parse_time_t(time_t * var); + +#endif /* SQUID_CACHE_CF_H_ */ === modified file 'src/carp.cc' --- src/carp.cc 2012-08-14 11:53:07 +0000 +++ src/carp.cc 2012-08-28 19:12:13 +0000 @@ -37,8 +37,10 @@ #include "squid.h" #include "HttpRequest.h" #include "mgr/Registration.h" +#include "neighbors.h" #include "protos.h" #include "Store.h" +#include "URL.h" #include "URLScheme.h" #if HAVE_MATH_H === added file 'src/carp.h' --- src/carp.h 1970-01-01 00:00:00 +0000 +++ src/carp.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,43 @@ +/* + * DEBUG: section 39 Cache Array Routing Protocol + * AUTHOR: Henrik Nordstrom + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_CARP_H_ +#define SQUID_CARP_H_ + +class peer; +class HttpRequest; + +extern void carpInit(void); +extern peer *carpSelectParent(HttpRequest *); + +#endif /* SQUID_CARP_H_ */ === modified file 'src/client_db.cc' --- src/client_db.cc 2012-08-28 13:00:30 +0000 +++ src/client_db.cc 2012-08-28 19:12:13 +0000 @@ -33,16 +33,21 @@ */ #include "squid.h" +#include "client_db.h" #include "event.h" #include "format/Token.h" #include "ClientInfo.h" +#include "fqdncache.h" #include "ip/Address.h" +#include "log/access_log.h" +#include "Mem.h" #include "mgr/Registration.h" #include "protos.h" #include "SquidMath.h" #include "SquidTime.h" #include "StatCounters.h" #include "Store.h" +#include "tools.h" static hash_table *client_table = NULL; === added file 'src/client_db.h' --- src/client_db.h 1970-01-01 00:00:00 +0000 +++ src/client_db.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,57 @@ +/* + * DEBUG: section 00 Client Database + * AUTHOR: Duane Wessels + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_CLIENT_DB_H_ +#define SQUID_CLIENT_DB_H_ + +#include "anyp/ProtocolType.h" +#include "enums.h" +#include "ip/Address.h" + +class StoreEntry; +class ClientInfo; + +extern void clientdbInit(void); +extern void clientdbUpdate(const Ip::Address &, log_type, AnyP::ProtocolType, size_t); +extern int clientdbCutoffDenied(const Ip::Address &); +extern void clientdbDump(StoreEntry *); +extern void clientdbFreeMemory(void); +extern int clientdbEstablished(const Ip::Address &, int); + +#if USE_DELAY_POOLS +extern void clientdbSetWriteLimiter(ClientInfo * info, const int writeSpeedLimit,const double initialBurst,const double highWatermark); +extern ClientInfo * clientdbGetInfo(const Ip::Address &addr); +#endif + + +#endif /* SQUID_CLIENT_DB_H_ */ === modified file 'src/client_side.cc' --- src/client_side.cc 2012-08-28 13:00:30 +0000 +++ src/client_side.cc 2012-08-28 19:12:13 +0000 @@ -82,12 +82,12 @@ */ #include "squid.h" - #include "acl/FilledChecklist.h" #include "anyp/PortCfg.h" #include "base/Subscription.h" #include "base/TextException.h" #include "ChunkedCodingParser.h" +#include "client_db.h" #include "client_side_reply.h" #include "client_side_request.h" #include "client_side.h" @@ -101,15 +101,22 @@ #include "CommCalls.h" #include "errorpage.h" #include "eui/Config.h" +#include "fd.h" #include "fde.h" #include "forward.h" +#include "fqdncache.h" +#include "http.h" #include "HttpHdrContRange.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "ident/Config.h" #include "ident/Ident.h" +#include "internal.h" #include "ipc/FdNotes.h" #include "ipc/StartListening.h" +#include "log/access_log.h" +#include "Mem.h" #include "MemBuf.h" #include "MemObject.h" #include "profiler/Profiler.h" @@ -120,6 +127,8 @@ #include "StatHist.h" #include "Store.h" #include "TimeOrTag.h" +#include "tools.h" +#include "URL.h" #if USE_AUTH #include "auth/UserRequest.h" === modified file 'src/client_side.h' --- src/client_side.h 2012-08-28 13:00:30 +0000 +++ src/client_side.h 2012-08-28 19:12:13 +0000 @@ -1,6 +1,6 @@ /* - * $Id$ - * + * DEBUG: section 33 Client-side Routines + * AUTHOR: Duane Wessels * * SQUID Web Proxy Cache http://www.squid-cache.org/ * ---------------------------------------------------------- @@ -412,4 +412,12 @@ const char *findTrailingHTTPVersion(const char *uriAndHTTPVersion, const char *end = NULL); +/* Vary support functions */ +extern int varyEvaluateMatch(StoreEntry * entry, HttpRequest * req); + +/* client_side.c - FD related client side routines */ +extern void clientOpenListenSockets(void); +extern void clientHttpConnectionsClose(void); +extern void httpRequestFree(void *); + #endif /* SQUID_CLIENTSIDE_H */ === modified file 'src/client_side_reply.cc' --- src/client_side_reply.cc 2012-08-28 13:00:30 +0000 +++ src/client_side_reply.cc 2012-08-28 19:12:13 +0000 @@ -40,20 +40,27 @@ #include "clientStream.h" #include "dlink.h" #include "errorpage.h" +#include "fd.h" #include "fde.h" #include "format/Token.h" #include "forward.h" #include "globals.h" #include "globals.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "ip/QosConfig.h" #include "ipcache.h" +#include "log/access_log.h" #include "MemObject.h" +#include "neighbors.h" #include "protos.h" +#include "refresh.h" #include "SquidTime.h" #include "Store.h" #include "StoreClient.h" +#include "tools.h" +#include "URL.h" #if USE_AUTH #include "auth/UserRequest.h" #endif === modified file 'src/client_side_request.cc' --- src/client_side_request.cc 2012-08-28 13:00:30 +0000 +++ src/client_side_request.cc 2012-08-28 19:12:13 +0000 @@ -55,18 +55,25 @@ #include "compat/inet_pton.h" #include "err_detail_type.h" #include "errorpage.h" +#include "fd.h" #include "fde.h" #include "format/Token.h" +#include "gopher.h" +#include "http.h" #include "HttpHdrCc.h" #include "HttpReply.h" #include "HttpRequest.h" #include "ipcache.h" #include "ip/QosConfig.h" +#include "log/access_log.h" #include "MemObject.h" +#include "Parsing.h" #include "profiler/Profiler.h" #include "protos.h" #include "SquidTime.h" #include "Store.h" +#include "tools.h" +#include "URL.h" #include "wordlist.h" #if USE_AUTH #include "auth/UserRequest.h" === modified file 'src/client_side_request.h' --- src/client_side_request.h 2012-08-28 13:00:30 +0000 +++ src/client_side_request.h 2012-08-28 19:12:13 +0000 @@ -199,17 +199,16 @@ }; /* client http based routines */ -SQUIDCEXTERN char *clientConstructTraceEcho(ClientHttpRequest *); +extern char *clientConstructTraceEcho(ClientHttpRequest *); class ACLFilledChecklist; -SQUIDCEXTERN ACLFilledChecklist *clientAclChecklistCreate(const acl_access * acl,ClientHttpRequest * http); -SQUIDCEXTERN int clientHttpRequestStatus(int fd, ClientHttpRequest const *http); -SQUIDCEXTERN void clientAccessCheck(ClientHttpRequest *); +extern ACLFilledChecklist *clientAclChecklistCreate(const acl_access * acl,ClientHttpRequest * http); +extern int clientHttpRequestStatus(int fd, ClientHttpRequest const *http); +extern void clientAccessCheck(ClientHttpRequest *); /* ones that should be elsewhere */ -SQUIDCEXTERN void redirectStart(ClientHttpRequest *, RH *, void *); - -SQUIDCEXTERN void tunnelStart(ClientHttpRequest *, int64_t *, int *); +extern void redirectStart(ClientHttpRequest *, RH *, void *); +extern void tunnelStart(ClientHttpRequest *, int64_t *, int *); #if _USE_INLINE_ #include "Store.h" === modified file 'src/comm.cc' --- src/comm.cc 2012-08-28 13:00:30 +0000 +++ src/comm.cc 2012-08-28 19:12:13 +0000 @@ -48,6 +48,7 @@ #include "compat/cmsg.h" #include "DescriptorSet.h" #include "event.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "icmp/net_db.h" === modified file 'src/comm/ConnOpener.cc' --- src/comm/ConnOpener.cc 2012-08-15 15:17:32 +0000 +++ src/comm/ConnOpener.cc 2012-08-28 19:12:13 +0000 @@ -7,6 +7,7 @@ #include "comm/Connection.h" #include "comm/Loops.h" #include "comm.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "icmp/net_db.h" === modified file 'src/comm/ModPoll.cc' --- src/comm/ModPoll.cc 2012-08-28 13:00:30 +0000 +++ src/comm/ModPoll.cc 2012-08-28 19:12:13 +0000 @@ -36,6 +36,7 @@ #include "anyp/PortCfg.h" #include "comm/Connection.h" #include "comm/Loops.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "ICP.h" === modified file 'src/comm/TcpAcceptor.cc' --- src/comm/TcpAcceptor.cc 2012-08-15 15:17:32 +0000 +++ src/comm/TcpAcceptor.cc 2012-08-28 19:12:13 +0000 @@ -34,12 +34,14 @@ #include "squid.h" #include "base/TextException.h" +#include "client_db.h" #include "comm/AcceptLimiter.h" #include "CommCalls.h" #include "comm/comm_internal.h" #include "comm/Connection.h" #include "comm/Loops.h" #include "comm/TcpAcceptor.h" +#include "fd.h" #include "fde.h" #include "ip/Intercept.h" #include "profiler/Profiler.h" === modified file 'src/comm/Write.cc' --- src/comm/Write.cc 2012-08-15 15:17:32 +0000 +++ src/comm/Write.cc 2012-08-28 19:12:13 +0000 @@ -2,6 +2,7 @@ #include "comm/Connection.h" #include "comm/IoCallback.h" #include "comm/Write.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "MemBuf.h" === modified file 'src/disk.cc' --- src/disk.cc 2012-08-28 13:00:30 +0000 +++ src/disk.cc 2012-08-28 19:12:13 +0000 @@ -34,7 +34,9 @@ #include "squid.h" #include "comm/Loops.h" +#include "fd.h" #include "fde.h" +#include "Mem.h" #include "MemBuf.h" #include "profiler/Profiler.h" #include "protos.h" === added file 'src/disk.h' --- src/disk.h 1970-01-01 00:00:00 +0000 +++ src/disk.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,58 @@ +/* + * DEBUG: section 06 Disk I/O Routines + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_DISK_H_ +#define SQUID_DISK_H_ + +#include "typedefs.h" + +class MemBuf; + +extern int file_open(const char *path, int mode); +extern void file_close(int fd); + +/* Adapter file_write for object callbacks */ +template +void +FreeObject(void *address) +{ + O *anObject = static_cast (address); + delete anObject; +} + +extern void file_write(int, off_t, void const *, int len, DWCB *, void *, FREE *); +extern void file_write_mbuf(int fd, off_t, MemBuf mb, DWCB * handler, void *handler_data); +extern void file_read(int, char *, int, off_t, DRCB *, void *); +extern void disk_init(void); + +#endif /* SQUID_DISK_H_ */ === modified file 'src/dns_internal.cc' --- src/dns_internal.cc 2012-08-28 13:00:30 +0000 +++ src/dns_internal.cc 2012-08-28 19:12:13 +0000 @@ -40,8 +40,10 @@ #include "comm/Loops.h" #include "comm/Write.h" #include "event.h" +#include "fd.h" #include "fde.h" #include "ip/tools.h" +#include "Mem.h" #include "MemBuf.h" #include "mgr/Registration.h" #include "protos.h" === modified file 'src/errorpage.cc' --- src/errorpage.cc 2012-08-28 13:00:30 +0000 +++ src/errorpage.cc 2012-08-28 19:12:13 +0000 @@ -32,19 +32,16 @@ * */ #include "squid.h" +#include "cache_cf.h" #include "comm/Connection.h" #include "comm/Write.h" +#include "disk.h" #include "err_detail_type.h" #include "errorpage.h" -#if USE_AUTH -#include "auth/UserRequest.h" -#endif -#include "SquidTime.h" -#if USE_SSL -#include "ssl/ErrorDetailManager.h" -#endif +#include "ftp.h" #include "Store.h" #include "html_quote.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "MemObject.h" @@ -52,8 +49,18 @@ #include "MemBuf.h" #include "protos.h" #include "rfc1738.h" +#include "URL.h" #include "URLScheme.h" +#include "URL.h" +#include "tools.h" #include "wordlist.h" +#if USE_AUTH +#include "auth/UserRequest.h" +#endif +#include "SquidTime.h" +#if USE_SSL +#include "ssl/ErrorDetailManager.h" +#endif /** \defgroup ErrorPageInternal Error Page Internals === modified file 'src/esi/Esi.cc' --- src/esi/Esi.cc 2012-08-28 13:00:30 +0000 +++ src/esi/Esi.cc 2012-08-28 19:12:13 +0000 @@ -57,6 +57,7 @@ #include "HttpReply.h" #include "HttpRequest.h" #include "ip/Address.h" +#include "Mem.h" #include "MemBuf.h" #include "profiler/Profiler.h" #include "protos.h" === modified file 'src/esi/Include.cc' --- src/esi/Include.cc 2012-08-28 13:00:30 +0000 +++ src/esi/Include.cc 2012-08-28 19:12:13 +0000 @@ -42,9 +42,11 @@ #if (USE_SQUID_ESI == 1) #include "client_side_request.h" +#include "client_side.h" #include "esi/Include.h" #include "esi/VarState.h" #include "HttpReply.h" +#include "log/access_log.h" #include "protos.h" CBDATA_CLASS_INIT (ESIStreamContext); === modified file 'src/esi/VarState.cc' --- src/esi/VarState.cc 2012-08-28 13:00:30 +0000 +++ src/esi/VarState.cc 2012-08-28 19:12:13 +0000 @@ -37,6 +37,7 @@ #include "squid.h" #include "esi/VarState.h" #include "HttpReply.h" +#include "Mem.h" #include "protos.h" CBDATA_TYPE (ESIVarState); === modified file 'src/external_acl.cc' --- src/external_acl.cc 2012-08-28 13:00:30 +0000 +++ src/external_acl.cc 2012-08-28 19:12:13 +0000 @@ -43,12 +43,14 @@ #include "squid.h" #include "acl/Acl.h" #include "acl/FilledChecklist.h" +#include "cache_cf.h" #include "client_side.h" #include "comm/Connection.h" #include "ExternalACLEntry.h" #include "ExternalACL.h" #include "fde.h" #include "helper.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" #include "ip/tools.h" @@ -59,6 +61,8 @@ #include "SquidTime.h" #include "Store.h" #include "URLScheme.h" +#include "tools.h" +#include "URL.h" #include "wordlist.h" #if USE_SSL #include "ssl/support.h" === modified file 'src/fd.cc' --- src/fd.cc 2012-08-28 13:00:30 +0000 +++ src/fd.cc 2012-08-28 19:12:13 +0000 @@ -36,6 +36,7 @@ #include "squid.h" #include "comm/Loops.h" #include "Debug.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "profiler/Profiler.h" === added file 'src/fd.h' --- src/fd.h 1970-01-01 00:00:00 +0000 +++ src/fd.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,45 @@ +/* + * DEBUG: section 51 Filedescriptor Functions + * AUTHOR: Duane Wessels + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_FD_H_ +#define SQUID_FD_H_ + +extern void fd_close(int fd); +extern void fd_open(int fd, unsigned int type, const char *); +extern void fd_note(int fd, const char *); +extern void fd_bytes(int fd, int len, unsigned int type); +extern void fdDumpOpen(void); +extern int fdUsageHigh(void); +extern void fdAdjustReserved(void); + +#endif /* SQUID_FD_H_ */ === modified file 'src/format/Config.cc' --- src/format/Config.cc 2012-08-06 17:41:08 +0000 +++ src/format/Config.cc 2012-08-28 19:12:13 +0000 @@ -1,4 +1,5 @@ #include "squid.h" +#include "cache_cf.h" #include "format/Config.h" #include "protos.h" #include === modified file 'src/format/Format.cc' --- src/format/Format.cc 2012-08-28 13:00:30 +0000 +++ src/format/Format.cc 2012-08-28 19:12:13 +0000 @@ -8,12 +8,14 @@ #include "format/Format.h" #include "format/Quoting.h" #include "format/Token.h" +#include "fqdncache.h" #include "HttpRequest.h" #include "MemBuf.h" #include "protos.h" #include "rfc1738.h" #include "SquidTime.h" #include "Store.h" +#include "URL.h" #if USE_SSL #include "ssl/ErrorDetail.h" #endif === modified file 'src/forward.cc' --- src/forward.cc 2012-08-28 13:00:30 +0000 +++ src/forward.cc 2012-08-28 19:12:13 +0000 @@ -43,23 +43,30 @@ #include "CommCalls.h" #include "errorpage.h" #include "event.h" +#include "fd.h" #include "fde.h" #include "forward.h" +#include "ftp.h" #include "globals.h" +#include "gopher.h" #include "hier_code.h" +#include "http.h" #include "HttpReply.h" #include "HttpRequest.h" #include "icmp/net_db.h" +#include "internal.h" #include "ip/Intercept.h" #include "ip/QosConfig.h" #include "ip/tools.h" #include "MemObject.h" #include "mgr/Registration.h" +#include "neighbors.h" #include "pconn.h" #include "PeerSelectState.h" #include "protos.h" #include "SquidTime.h" #include "Store.h" +#include "whois.h" #if USE_SSL #include "ssl/support.h" #include "ssl/ErrorDetail.h" === modified file 'src/fqdncache.cc' --- src/fqdncache.cc 2012-08-28 13:00:30 +0000 +++ src/fqdncache.cc 2012-08-28 19:12:13 +0000 @@ -36,6 +36,7 @@ #include "cbdata.h" #include "DnsLookupDetails.h" #include "event.h" +#include "Mem.h" #include "mgr/Registration.h" #include "protos.h" #include "SquidDns.h" @@ -586,50 +587,6 @@ #endif } -/// \ingroup FQDNCacheInternal -static void -fqdncacheRegisterWithCacheManager(void) -{ - Mgr::RegisterAction("fqdncache", "FQDN Cache Stats and Contents", - fqdnStats, 0, 1); - -} - -/** - \ingroup FQDNCacheAPI - * - * Initialize the fqdncache. - * Called after IP cache initialization. - */ -void -fqdncache_init(void) -{ - int n; - - fqdncacheRegisterWithCacheManager(); - - if (fqdn_table) - return; - - debugs(35, 3, "Initializing FQDN Cache..."); - - memset(&FqdncacheStats, '\0', sizeof(FqdncacheStats)); - - memset(&lru_list, '\0', sizeof(lru_list)); - - fqdncache_high = (long) (((float) Config.fqdncache.size * - (float) FQDN_HIGH_WATER) / (float) 100); - - fqdncache_low = (long) (((float) Config.fqdncache.size * - (float) FQDN_LOW_WATER) / (float) 100); - - n = hashPrime(fqdncache_high / 4); - - fqdn_table = hash_create((HASHCMP *) strcmp, n, hash4); - - memDataInit(MEM_FQDNCACHE_ENTRY, "fqdncache_entry", - sizeof(fqdncache_entry), 0); -} /** \ingroup FQDNCacheAPI @@ -743,6 +700,7 @@ } /// \ingroup FQDNCacheAPI +#if 0 const char * fqdnFromAddr(const Ip::Address &addr) { @@ -758,6 +716,7 @@ return buf; } +#endif /// \ingroup FQDNCacheInternal static void @@ -870,6 +829,51 @@ fqdncacheLockEntry(fce); } +/// \ingroup FQDNCacheInternal +static void +fqdncacheRegisterWithCacheManager(void) +{ + Mgr::RegisterAction("fqdncache", "FQDN Cache Stats and Contents", + fqdnStats, 0, 1); + +} + +/** + \ingroup FQDNCacheAPI + * + * Initialize the fqdncache. + * Called after IP cache initialization. + */ +void +fqdncache_init(void) +{ + int n; + + fqdncacheRegisterWithCacheManager(); + + if (fqdn_table) + return; + + debugs(35, 3, "Initializing FQDN Cache..."); + + memset(&FqdncacheStats, '\0', sizeof(FqdncacheStats)); + + memset(&lru_list, '\0', sizeof(lru_list)); + + fqdncache_high = (long) (((float) Config.fqdncache.size * + (float) FQDN_HIGH_WATER) / (float) 100); + + fqdncache_low = (long) (((float) Config.fqdncache.size * + (float) FQDN_LOW_WATER) / (float) 100); + + n = hashPrime(fqdncache_high / 4); + + fqdn_table = hash_create((HASHCMP *) strcmp, n, hash4); + + memDataInit(MEM_FQDNCACHE_ENTRY, "fqdncache_entry", + sizeof(fqdncache_entry), 0); +} + #if SQUID_SNMP /** * \ingroup FQDNCacheAPI === added file 'src/fqdncache.h' --- src/fqdncache.h 1970-01-01 00:00:00 +0000 +++ src/fqdncache.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,59 @@ +/* + * DEBUG: section 35 FQDN Cache + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_FQDNCACHE_H_ +#define SQUID_FQDNCACHE_H_ + +#include "ip/Address.h" +#include "typedefs.h" + +class StoreEntry; +class wordlist; + +extern void fqdncache_init(void); +void fqdnStats(StoreEntry *); +//extern void fqdncacheReleaseInvalid(const char *); +//extern int fqdncacheQueueDrain(void); +extern void fqdncacheFreeMemory(void); +extern void fqdncache_restart(void); +extern void fqdncache_purgelru(void *); +extern void fqdncacheAddEntryFromHosts(char *addr, wordlist * hostnames); + +extern const char *fqdncache_gethostbyaddr(const Ip::Address &, int flags); +//extern const char *fqdnFromAddr(const Ip::Address &); +extern void fqdncache_nbgethostbyaddr(const Ip::Address &, FQDNH *, void *); + + + + +#endif /* SQUID_FQDNCACHE_H_ */ === modified file 'src/fs/coss/store_dir_coss.cc' --- src/fs/coss/store_dir_coss.cc 2012-08-28 13:00:30 +0000 +++ src/fs/coss/store_dir_coss.cc 2012-08-28 19:12:13 +0000 @@ -35,8 +35,10 @@ #include "squid.h" #include "CossSwapDir.h" +#include "cache_cf.h" #include "Store.h" #include "store_coss.h" +#include "disk.h" #include "event.h" #include "fde.h" #include "SwapDir.h" @@ -47,6 +49,7 @@ #include "ConfigOption.h" #include "StoreFScoss.h" #include "Parsing.h" +#include "store_key_md5.h" #include "swap_log_op.h" #include "SquidMath.h" === modified file 'src/fs/rock/RockRebuild.cc' --- src/fs/rock/RockRebuild.cc 2012-08-15 15:17:32 +0000 +++ src/fs/rock/RockRebuild.cc 2012-08-28 19:12:13 +0000 @@ -5,6 +5,7 @@ */ #include "squid.h" +#include "disk.h" #include "fs/rock/RockRebuild.h" #include "fs/rock/RockSwapDir.h" #include "fs/rock/RockDbCell.h" === modified file 'src/fs/rock/RockSwapDir.cc' --- src/fs/rock/RockSwapDir.cc 2012-08-28 13:00:30 +0000 +++ src/fs/rock/RockSwapDir.cc 2012-08-28 19:12:13 +0000 @@ -5,6 +5,7 @@ */ #include "squid.h" +#include "cache_cf.h" #include "ConfigOption.h" #include "DiskIO/DiskIOModule.h" #include "DiskIO/DiskIOStrategy.h" === modified file 'src/fs/ufs/RebuildState.cc' --- src/fs/ufs/RebuildState.cc 2012-08-15 15:17:32 +0000 +++ src/fs/ufs/RebuildState.cc 2012-08-28 19:12:13 +0000 @@ -32,9 +32,11 @@ */ #include "squid.h" +#include "disk.h" #include "protos.h" #include "RebuildState.h" #include "SquidTime.h" +#include "store_key_md5.h" #include "StoreSwapLogData.h" #include "UFSSwapLogParser.h" === modified file 'src/fs/ufs/UFSSwapDir.cc' --- src/fs/ufs/UFSSwapDir.cc 2012-08-28 13:00:30 +0000 +++ src/fs/ufs/UFSSwapDir.cc 2012-08-28 19:12:13 +0000 @@ -29,10 +29,11 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. */ +#define CLEAN_BUF_SZ 16384 + #include "squid.h" - -#define CLEAN_BUF_SZ 16384 - +#include "cache_cf.h" +#include "disk.h" #include "ConfigOption.h" #include "DiskIO/DiskIOModule.h" #include "FileMap.h" @@ -42,6 +43,7 @@ #include "RebuildState.h" #include "SquidMath.h" #include "DiskIO/DiskIOStrategy.h" +#include "store_key_md5.h" #include "StoreSearchUFS.h" #include "StoreSwapLogData.h" #include "SquidTime.h" === modified file 'src/ftp.cc' --- src/ftp.cc 2012-08-28 13:00:30 +0000 +++ src/ftp.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,7 @@ #include "CommCalls.h" #include "compat/strtoll.h" #include "errorpage.h" +#include "fd.h" #include "fde.h" #include "forward.h" #include "html_quote.h" @@ -49,6 +50,7 @@ #include "HttpReply.h" #include "HttpRequest.h" #include "ip/tools.h" +#include "Mem.h" #include "MemBuf.h" #include "protos.h" #include "rfc1738.h" @@ -57,6 +59,8 @@ #include "SquidTime.h" #include "StatCounters.h" #include "Store.h" +#include "tools.h" +#include "URL.h" #include "URLScheme.h" #include "wordlist.h" === added file 'src/ftp.h' --- src/ftp.h 1970-01-01 00:00:00 +0000 +++ src/ftp.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,49 @@ +/* + * DEBUG: section 09 File Transfer Protocol (FTP) + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + +#ifndef SQUID_FTP_H_ +#define SQUID_FTP_H_ + +class FwdState; + +/** + * \defgroup ServerProtocolFTPAPI Server-Side FTP API + * \ingroup ServerProtocol + */ + +/// \ingroup ServerProtocolFTPAPI +extern void ftpStart(FwdState *); +/// \ingroup ServerProtocolFTPAPI +extern const char *ftpUrlWith2f(HttpRequest *); + + +#endif /* SQUID_FTP_H_ */ === modified file 'src/gopher.cc' --- src/gopher.cc 2012-08-28 13:00:30 +0000 +++ src/gopher.cc 2012-08-28 19:12:13 +0000 @@ -37,16 +37,19 @@ #include "comm.h" #include "comm/Write.h" #include "errorpage.h" +#include "fd.h" #include "forward.h" #include "html_quote.h" #include "HttpReply.h" #include "HttpRequest.h" +#include "Mem.h" #include "MemBuf.h" #include "protos.h" #include "rfc1738.h" #include "SquidTime.h" #include "StatCounters.h" #include "Store.h" +#include "tools.h" #if USE_DELAY_POOLS #include "DelayPools.h" === added file 'src/gopher.h' --- src/gopher.h 1970-01-01 00:00:00 +0000 +++ src/gopher.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,52 @@ +/* + * DEBUG: section 10 Gopher + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_GOPHER_H_ +#define SQUID_GOPHER_H_ + +class FwdState; +class HttpRequest; + +/** + \defgroup ServerProtocolGopherAPI Server-Side Gopher API + \ingroup ServerProtocol + */ + +/// \ingroup ServerProtocolGopherAPI +extern void gopherStart(FwdState *); + +/// \ingroup ServerProtocolGopherAPI +extern int gopherCachable(const HttpRequest *); + + +#endif /* SQUID_GOPHER_H_ */ === modified file 'src/helper.cc' --- src/helper.cc 2012-08-28 13:00:30 +0000 +++ src/helper.cc 2012-08-28 19:12:13 +0000 @@ -37,8 +37,10 @@ #include "comm.h" #include "comm/Connection.h" #include "comm/Write.h" +#include "fd.h" #include "format/Quoting.h" #include "helper.h" +#include "Mem.h" #include "MemBuf.h" #include "protos.h" #include "SquidMath.h" === modified file 'src/htcp.cc' --- src/htcp.cc 2012-08-28 13:00:30 +0000 +++ src/htcp.cc 2012-08-28 19:12:13 +0000 @@ -51,10 +51,13 @@ #include "md5.h" #include "MemBuf.h" #include "protos.h" +#include "refresh.h" #include "SquidTime.h" #include "StatCounters.h" +#include "store_key_md5.h" #include "Store.h" #include "StoreClient.h" +#include "URL.h" typedef struct _Countstr Countstr; === modified file 'src/http.cc' --- src/http.cc 2012-08-28 13:00:30 +0000 +++ src/http.cc 2012-08-28 19:12:13 +0000 @@ -48,6 +48,7 @@ #include "comm/Write.h" #include "err_detail_type.h" #include "errorpage.h" +#include "fd.h" #include "fde.h" #include "HttpControlMsg.h" #include "http.h" @@ -55,16 +56,22 @@ #include "HttpHdrContRange.h" #include "HttpHdrSc.h" #include "HttpHdrScTarget.h" +#include "HttpHeaderTools.h" #include "HttpReply.h" #include "HttpRequest.h" +#include "log/access_log.h" #include "MemBuf.h" #include "MemObject.h" +#include "neighbors.h" #include "profiler/Profiler.h" #include "protos.h" +#include "refresh.h" #include "rfc1738.h" #include "SquidTime.h" #include "StatCounters.h" #include "Store.h" +#include "tools.h" +#include "URL.h" #if USE_AUTH #include "auth/UserRequest.h" === modified file 'src/http.h' --- src/http.h 2012-07-22 03:15:02 +0000 +++ src/http.h 2012-08-28 19:12:13 +0000 @@ -135,4 +135,9 @@ CBDATA_CLASS2(HttpStateData); }; +extern int httpCachable(const HttpRequestMethod&); +extern void httpStart(FwdState *); +extern const char *httpMakeVaryMark(HttpRequest * request, HttpReply const * reply); + + #endif /* SQUID_HTTP_H */ === modified file 'src/icmp/IcmpSquid.cc' --- src/icmp/IcmpSquid.cc 2012-08-28 13:00:30 +0000 +++ src/icmp/IcmpSquid.cc 2012-08-28 19:12:13 +0000 @@ -35,6 +35,7 @@ #include "squid.h" #include "comm.h" #include "comm/Loops.h" +#include "fd.h" #include "icmp/IcmpSquid.h" #include "icmp/net_db.h" #include "ip/tools.h" === modified file 'src/icmp/net_db.cc' --- src/icmp/net_db.cc 2012-08-28 13:00:30 +0000 +++ src/icmp/net_db.cc 2012-08-28 19:12:13 +0000 @@ -51,10 +51,16 @@ #include "MemObject.h" #include "fde.h" #include "forward.h" +#include "internal.h" #include "protos.h" #include "SquidTime.h" #include "wordlist.h" #include "ip/Address.h" +#include "neighbors.h" +#include "URL.h" +#include "Mem.h" +#include "disk.h" + #if HAVE_SYS_STAT_H #include === modified file 'src/icp_v2.cc' --- src/icp_v2.cc 2012-08-28 13:00:30 +0000 +++ src/icp_v2.cc 2012-08-28 19:12:13 +0000 @@ -39,10 +39,12 @@ #include "AccessLogEntry.h" #include "acl/Acl.h" #include "acl/FilledChecklist.h" +#include "client_db.h" #include "comm.h" #include "comm/Connection.h" #include "comm/Loops.h" #include "comm/UdpOpenDialer.h" +#include "fd.h" #include "HttpRequest.h" #include "icmp/net_db.h" #include "ICP.h" @@ -50,12 +52,16 @@ #include "ip/tools.h" #include "ipcache.h" #include "md5.h" +#include "neighbors.h" #include "protos.h" +#include "refresh.h" #include "rfc1738.h" #include "SquidTime.h" #include "StatCounters.h" #include "Store.h" +#include "store_key_md5.h" #include "SwapDir.h" +#include "tools.h" #include "wordlist.h" #if HAVE_ERRNO_H === modified file 'src/internal.cc' --- src/internal.cc 2012-08-14 11:53:07 +0000 +++ src/internal.cc 2012-08-28 19:12:13 +0000 @@ -44,6 +44,8 @@ #include "MemBuf.h" #include "protos.h" #include "SquidTime.h" +#include "tools.h" +#include "URL.h" #include "wordlist.h" /* called when we "miss" on an internal object; === added file 'src/internal.h' --- src/internal.h 1970-01-01 00:00:00 +0000 +++ src/internal.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,51 @@ +/* + * DEBUG: section 76 Internal Squid Object handling + * AUTHOR: Duane, Alex, Henrik + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_INTERNAL_H_ +#define SQUID_INTERNAL_H_ + +#include "comm/forward.h" +class HttpRequest; +class StoreEntry; + +extern void internalStart(const Comm::ConnectionPointer &clientConn, HttpRequest *, StoreEntry *); +extern int internalCheck(const char *urlpath); +extern int internalStaticCheck(const char *urlpath); +extern char *internalLocalUri(const char *dir, const char *name); +extern char *internalRemoteUri(const char *, unsigned short, const char *, const char *); +extern const char *internalHostname(void); +extern int internalHostnameIs(const char *); + + + +#endif /* SQUID_INTERNAL_H_ */ === modified file 'src/ip/QosConfig.cc' --- src/ip/QosConfig.cc 2012-08-15 15:17:32 +0000 +++ src/ip/QosConfig.cc 2012-08-28 19:12:13 +0000 @@ -1,6 +1,7 @@ #include "squid.h" #include "acl/Gadgets.h" +#include "cache_cf.h" #include "comm/Connection.h" #include "ConfigParser.h" #include "fde.h" === modified file 'src/ipc.cc' --- src/ipc.cc 2012-08-14 11:53:07 +0000 +++ src/ipc.cc 2012-08-28 19:12:13 +0000 @@ -32,6 +32,7 @@ #include "squid.h" #include "comm/Connection.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "ip/Address.h" === modified file 'src/ipc/StoreMap.cc' --- src/ipc/StoreMap.cc 2012-08-28 13:00:30 +0000 +++ src/ipc/StoreMap.cc 2012-08-28 19:12:13 +0000 @@ -7,6 +7,7 @@ #include "squid.h" #include "protos.h" #include "Store.h" +#include "store_key_md5.h" #include "ipc/StoreMap.h" Ipc::StoreMap::Owner * === modified file 'src/ipc_win32.cc' --- src/ipc_win32.cc 2012-08-15 15:17:32 +0000 +++ src/ipc_win32.cc 2012-08-28 19:12:13 +0000 @@ -34,7 +34,9 @@ */ #include "squid.h" +#include "cache_cf.h" #include "comm.h" +#include "fd.h" #include "fde.h" #include "ip/Address.h" #include "rfc1738.h" === modified file 'src/ipcache.cc' --- src/ipcache.cc 2012-08-28 13:00:30 +0000 +++ src/ipcache.cc 2012-08-28 19:12:13 +0000 @@ -38,6 +38,7 @@ #include "ip/Address.h" #include "ip/tools.h" #include "ipcache.h" +#include "Mem.h" #include "mgr/Registration.h" #include "protos.h" #include "rfc3596.h" === modified file 'src/list.cc' --- src/list.cc 2012-08-14 11:53:07 +0000 +++ src/list.cc 2012-08-28 19:12:13 +0000 @@ -34,6 +34,7 @@ */ #include "squid.h" +#include "Mem.h" #include "protos.h" #include "typedefs.h" === modified file 'src/log/Config.cc' --- src/log/Config.cc 2012-01-20 18:55:04 +0000 +++ src/log/Config.cc 2012-08-28 19:12:13 +0000 @@ -1,4 +1,5 @@ #include "squid.h" +#include "cache_cf.h" #include "log/Config.h" #include "protos.h" === modified file 'src/log/FormatSquidIcap.cc' --- src/log/FormatSquidIcap.cc 2012-08-14 11:53:07 +0000 +++ src/log/FormatSquidIcap.cc 2012-08-28 19:12:13 +0000 @@ -38,6 +38,7 @@ #include "AccessLogEntry.h" #include "format/Quoting.h" +#include "fqdncache.h" #include "HttpRequest.h" #include "log/File.h" #include "log/Formats.h" === modified file 'src/log/Makefile.am' --- src/log/Makefile.am 2011-08-04 03:21:06 +0000 +++ src/log/Makefile.am 2012-08-28 19:12:13 +0000 @@ -4,6 +4,7 @@ noinst_LTLIBRARIES = liblog.la liblog_la_SOURCES = \ + access_log.h \ access_log.cc \ Config.cc \ Config.h \ === modified file 'src/log/ModStdio.cc' --- src/log/ModStdio.cc 2012-08-15 15:17:32 +0000 +++ src/log/ModStdio.cc 2012-08-28 19:12:13 +0000 @@ -31,6 +31,8 @@ */ #include "squid.h" +#include "disk.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "log/File.h" === modified file 'src/log/ModTcp.cc' --- src/log/ModTcp.cc 2012-08-28 13:00:30 +0000 +++ src/log/ModTcp.cc 2012-08-28 19:12:13 +0000 @@ -34,6 +34,8 @@ #include "squid.h" #include "comm.h" #include "comm/Connection.h" +#include "disk.h" +#include "fd.h" #include "log/File.h" #include "log/ModTcp.h" #include "Parsing.h" === modified file 'src/log/ModUdp.cc' --- src/log/ModUdp.cc 2012-08-28 13:00:30 +0000 +++ src/log/ModUdp.cc 2012-08-28 19:12:13 +0000 @@ -33,6 +33,8 @@ #include "squid.h" #include "comm.h" #include "comm/Connection.h" +#include "disk.h" +#include "fd.h" #include "log/File.h" #include "log/ModUdp.h" #include "Parsing.h" === modified file 'src/log/access_log.cc' --- src/log/access_log.cc 2012-08-28 13:00:30 +0000 +++ src/log/access_log.cc 2012-08-28 19:12:13 +0000 @@ -44,6 +44,7 @@ #include "hier_code.h" #include "HttpReply.h" #include "HttpRequest.h" +#include "log/access_log.h" #include "log/Config.h" #include "log/File.h" #include "log/Formats.h" === added file 'src/log/access_log.h' --- src/log/access_log.h 1970-01-01 00:00:00 +0000 +++ src/log/access_log.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,47 @@ +/* + * DEBUG: section 46 Access Log + * AUTHOR: Duane Wessels + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + +#ifndef SQUID_LOG_ACCESS_LOG_H_ +#define SQUID_LOG_ACCESS_LOG_H_ + + +extern int logTypeIsATcpHit(log_type); +extern void fvdbCountVia(const char *key); +extern void fvdbCountForw(const char *key); + +#if HEADERS_LOG +class HttpRequestMethod; +extern void headersLog(int cs, int pq, const HttpRequestMethod& m, void *data); +#endif + + +#endif /* SQUID_LOG_ACCESS_LOG_H_ */ === modified file 'src/main.cc' --- src/main.cc 2012-08-15 15:17:32 +0000 +++ src/main.cc 2012-08-28 19:12:13 +0000 @@ -39,19 +39,26 @@ #include "base/RunnersRegistry.h" #include "base/Subscription.h" #include "base/TextException.h" +#include "cache_cf.h" +#include "carp.h" +#include "client_db.h" +#include "client_side.h" #include "comm.h" #include "ConfigParser.h" #include "CpuAffinity.h" +#include "disk.h" #include "DiskIO/DiskIOModule.h" #include "errorpage.h" #include "event.h" #include "EventLoop.h" #include "ExternalACL.h" +#include "fd.h" #include "format/Token.h" #include "forward.h" #include "fs/Module.h" -#include "fs/Module.h" +#include "fqdncache.h" #include "htcp.h" +#include "HttpHeader.h" #include "HttpReply.h" #include "icmp/IcmpSquid.h" #include "icmp/net_db.h" @@ -63,16 +70,25 @@ #include "ip/tools.h" #include "Mem.h" #include "MemPool.h" +#include "neighbors.h" #include "pconn.h" #include "PeerSelectState.h" +#include "peer_sourcehash.h" +#include "peer_userhash.h" #include "profiler/Profiler.h" #include "protos.h" +#include "refresh.h" +#include "tools.h" #include "SquidDns.h" #include "SquidTime.h" +#include "stat.h" #include "StatCounters.h" #include "StoreFileSystem.h" #include "Store.h" #include "SwapDir.h" +#include "URL.h" +#include "wccp.h" +#include "wccp2.h" #if USE_ADAPTATION #include "adaptation/Config.h" === modified file 'src/mem.cc' --- src/mem.cc 2012-08-28 13:00:30 +0000 +++ src/mem.cc 2012-08-28 19:12:13 +0000 @@ -52,6 +52,14 @@ #include #endif +/* forward declarations */ +static void memFree2K(void *); +static void memFree4K(void *); +static void memFree8K(void *); +static void memFree16K(void *); +static void memFree32K(void *); +static void memFree64K(void *); + /* module globals */ const size_t squidSystemPageSize=getpagesize(); === modified file 'src/mime.cc' --- src/mime.cc 2012-08-28 13:00:30 +0000 +++ src/mime.cc 2012-08-28 19:12:13 +0000 @@ -34,11 +34,14 @@ */ #include "squid.h" +#include "disk.h" #include "fde.h" #include "globals.h" #include "HttpHdrCc.h" #include "HttpReply.h" #include "HttpRequest.h" +#include "internal.h" +#include "Mem.h" #include "MemBuf.h" #include "MemObject.h" #include "protos.h" === modified file 'src/neighbors.cc' --- src/neighbors.cc 2012-08-28 13:00:30 +0000 +++ src/neighbors.cc 2012-08-28 19:12:13 +0000 @@ -33,6 +33,7 @@ #include "squid.h" #include "acl/FilledChecklist.h" #include "anyp/PortCfg.h" +#include "CacheDigest.h" #include "comm/Connection.h" #include "comm/ConnOpener.h" #include "event.h" @@ -46,12 +47,16 @@ #include "ipcache.h" #include "MemObject.h" #include "mgr/Registration.h" +#include "neighbors.h" #include "PeerDigest.h" #include "PeerSelectState.h" #include "protos.h" #include "SquidMath.h" #include "SquidTime.h" +#include "stat.h" #include "Store.h" +#include "store_key_md5.h" +#include "URL.h" /* count mcast group peers every 15 minutes */ #define MCAST_COUNT_RATE 900 === added file 'src/neighbors.h' --- src/neighbors.h 1970-01-01 00:00:00 +0000 +++ src/neighbors.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,88 @@ +/* + * DEBUG: section 15 Neighbor Routines + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_NEIGHBORS_H_ +#define SQUID_NEIGHBORS_H_ + +#include "enums.h" +#include "HttpRequestMethod.h" +#include "lookup_t.h" +#include "ip/Address.h" +#include "typedefs.h" + +class HttpRequest; +class peer; +class StoreEntry; + +SQUIDCEXTERN peer *getFirstPeer(void); +SQUIDCEXTERN peer *getFirstUpParent(HttpRequest *); +SQUIDCEXTERN peer *getNextPeer(peer *); +SQUIDCEXTERN peer *getSingleParent(HttpRequest *); +SQUIDCEXTERN int neighborsCount(HttpRequest *); +SQUIDCEXTERN int neighborsUdpPing(HttpRequest *, + StoreEntry *, + IRCB * callback, + void *data, + int *exprep, + int *timeout); +SQUIDCEXTERN void neighborAddAcl(const char *, const char *); + +SQUIDCEXTERN void neighborsUdpAck(const cache_key *, icp_common_t *, const Ip::Address &); +SQUIDCEXTERN void neighborAdd(const char *, const char *, int, int, int, int, int); +SQUIDCEXTERN void neighbors_init(void); +#if USE_HTCP +SQUIDCEXTERN void neighborsHtcpClear(StoreEntry *, const char *, HttpRequest *, const HttpRequestMethod &, htcp_clr_reason); +#endif +SQUIDCEXTERN peer *peerFindByName(const char *); +SQUIDCEXTERN peer *peerFindByNameAndPort(const char *, unsigned short); +SQUIDCEXTERN peer *getDefaultParent(HttpRequest * request); +SQUIDCEXTERN peer *getRoundRobinParent(HttpRequest * request); +SQUIDCEXTERN peer *getWeightedRoundRobinParent(HttpRequest * request); +SQUIDCEXTERN void peerClearRRStart(void); +SQUIDCEXTERN void peerClearRR(void); +SQUIDCEXTERN lookup_t peerDigestLookup(peer * p, HttpRequest * request); +SQUIDCEXTERN peer *neighborsDigestSelect(HttpRequest * request); +SQUIDCEXTERN void peerNoteDigestLookup(HttpRequest * request, peer * p, lookup_t lookup); +SQUIDCEXTERN void peerNoteDigestGone(peer * p); +SQUIDCEXTERN int neighborUp(const peer * e); +SQUIDCEXTERN CBDUNL peerDestroy; +SQUIDCEXTERN const char *neighborTypeStr(const peer * e); +SQUIDCEXTERN peer_t neighborType(const peer *, const HttpRequest *); +SQUIDCEXTERN void peerConnectFailed(peer *); +SQUIDCEXTERN void peerConnectSucceded(peer *); +SQUIDCEXTERN void dump_peer_options(StoreEntry *, peer *); +SQUIDCEXTERN int peerHTTPOkay(const peer *, HttpRequest *); + +SQUIDCEXTERN peer *whichPeer(const Ip::Address &from); + +#endif /* SQUID_NEIGHBORS_H_ */ === modified file 'src/pconn.cc' --- src/pconn.cc 2012-08-14 11:53:07 +0000 +++ src/pconn.cc 2012-08-28 19:12:13 +0000 @@ -35,6 +35,7 @@ #include "squid.h" #include "comm.h" #include "comm/Connection.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "mgr/Registration.h" === modified file 'src/peer_digest.cc' --- src/peer_digest.cc 2012-08-28 13:00:30 +0000 +++ src/peer_digest.cc 2012-08-28 19:12:13 +0000 @@ -35,16 +35,21 @@ #include "squid.h" #if USE_CACHE_DIGESTS +#include "CacheDigest.h" #include "event.h" #include "forward.h" #include "HttpReply.h" #include "HttpRequest.h" +#include "internal.h" #include "MemObject.h" +#include "neighbors.h" #include "PeerDigest.h" #include "protos.h" #include "SquidTime.h" #include "Store.h" +#include "store_key_md5.h" #include "StoreClient.h" +#include "tools.h" /* local types */ === modified file 'src/peer_select.cc' --- src/peer_select.cc 2012-08-28 13:00:30 +0000 +++ src/peer_select.cc 2012-08-28 19:12:13 +0000 @@ -34,6 +34,7 @@ #include "squid.h" #include "acl/FilledChecklist.h" +#include "carp.h" #include "client_side.h" #include "DnsLookupDetails.h" #include "errorpage.h" @@ -45,6 +46,10 @@ #include "icmp/net_db.h" #include "ICP.h" #include "ipcache.h" +#include "Mem.h" +#include "neighbors.h" +#include "peer_sourcehash.h" +#include "peer_userhash.h" #include "PeerSelectState.h" #include "protos.h" #include "SquidTime.h" === modified file 'src/peer_sourcehash.cc' --- src/peer_sourcehash.cc 2012-08-14 11:53:07 +0000 +++ src/peer_sourcehash.cc 2012-08-28 19:12:13 +0000 @@ -37,6 +37,7 @@ #include "squid.h" #include "HttpRequest.h" #include "mgr/Registration.h" +#include "neighbors.h" #include "protos.h" #include "Store.h" === added file 'src/peer_sourcehash.h' --- src/peer_sourcehash.h 1970-01-01 00:00:00 +0000 +++ src/peer_sourcehash.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,46 @@ +/* + * DEBUG: section 39 Peer source hash based selection + * AUTHOR: Henrik Nordstrom + * BASED ON: carp.cc + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_PEER_SOURCEHASH_H_ +#define SQUID_PEER_SOURCEHASH_H_ + +class peer; +class HttpRequest; + +extern void peerSourceHashInit(void); +extern peer * peerSourceHashSelectParent(HttpRequest * request); + + + +#endif /* SQUID_PEER_SOURCEHASH_H_ */ === modified file 'src/peer_userhash.cc' --- src/peer_userhash.cc 2012-08-28 13:00:30 +0000 +++ src/peer_userhash.cc 2012-08-28 19:12:13 +0000 @@ -42,6 +42,7 @@ #include "globals.h" #include "HttpRequest.h" #include "mgr/Registration.h" +#include "neighbors.h" #include "protos.h" #include "Store.h" === added file 'src/peer_userhash.h' --- src/peer_userhash.h 1970-01-01 00:00:00 +0000 +++ src/peer_userhash.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,44 @@ +/* + * DEBUG: section 39 Peer user hash based selection + * AUTHOR: Henrik Nordstrom + * BASED ON: carp.cc + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_PEER_USERHASH_H_ +#define SQUID_PEER_USERHASH_H_ + +class peer; +class HttpRequest; + +extern void peerUserHashInit(void); +extern peer * peerUserHashSelectParent(HttpRequest * request); + +#endif /* SQUID_PEER_USERHASH_H_ */ === modified file 'src/protos.h' --- src/protos.h 2012-08-28 13:00:30 +0000 +++ src/protos.h 2012-08-28 19:12:13 +0000 @@ -39,186 +39,34 @@ #include "enums.h" /* some parameters stil need this */ #include "wordlist.h" - -/* for parameters that still need these */ +#include "anyp/ProtocolType.h" +#include "Debug.h" +#include "HttpHeader.h" +#include "HttpStatusCode.h" #include "lookup_t.h" + class HttpRequestMethod; #if USE_DELAY_POOLS class ClientInfo; #endif -#if USE_FORW_VIA_DB -extern void fvdbCountVia(const char *key); -extern void fvdbCountForw(const char *key); -#endif -#if HEADERS_LOG -SQUIDCEXTERN void headersLog(int cs, int pq, const HttpRequestMethod& m, void *data); -#endif -extern int logTypeIsATcpHit(log_type); - -/* - * cache_cf.c - */ -SQUIDCEXTERN void configFreeMemory(void); -class MemBuf; -extern void wordlistCat(const wordlist *, MemBuf * mb); -extern void self_destruct(void); -SQUIDCEXTERN void add_http_port(char *portspec); -extern int xatoi(const char *token); -extern long xatol(const char *token); - -/* extra functions from cache_cf.c useful for lib modules */ -SQUIDCEXTERN void parse_int(int *var); -SQUIDCEXTERN void parse_onoff(int *var); -SQUIDCEXTERN void parse_eol(char *volatile *var); -SQUIDCEXTERN void parse_wordlist(wordlist ** list); -SQUIDCEXTERN void requirePathnameExists(const char *name, const char *path); -SQUIDCEXTERN void parse_time_t(time_t * var); - -/* client_side.c - FD related client side routines */ - -SQUIDCEXTERN void clientdbInit(void); - -#include "anyp/ProtocolType.h" -SQUIDCEXTERN void clientdbUpdate(const Ip::Address &, log_type, AnyP::ProtocolType, size_t); - -SQUIDCEXTERN int clientdbCutoffDenied(const Ip::Address &); -void clientdbDump(StoreEntry *); -SQUIDCEXTERN void clientdbFreeMemory(void); - -SQUIDCEXTERN int clientdbEstablished(const Ip::Address &, int); -#if USE_DELAY_POOLS -SQUIDCEXTERN void clientdbSetWriteLimiter(ClientInfo * info, const int writeSpeedLimit,const double initialBurst,const double highWatermark); -SQUIDCEXTERN ClientInfo * clientdbGetInfo(const Ip::Address &addr); -#endif -SQUIDCEXTERN void clientOpenListenSockets(void); -SQUIDCEXTERN void clientHttpConnectionsClose(void); -SQUIDCEXTERN void httpRequestFree(void *); - -extern void clientAccessCheck(void *); - -#include "Debug.h" - -/* packs, then prints an object using debugs() */ -SQUIDCEXTERN void debugObj(int section, int level, const char *label, void *obj, ObjPackMethod pm); - -/* disk.c */ -SQUIDCEXTERN int file_open(const char *path, int mode); -SQUIDCEXTERN void file_close(int fd); -/* Adapter file_write for object callbacks */ - -template -void -FreeObject(void *address) -{ - O *anObject = static_cast (address); - delete anObject; -} - -SQUIDCEXTERN void file_write(int, off_t, void const *, int len, DWCB *, void *, FREE *); -SQUIDCEXTERN void file_write_mbuf(int fd, off_t, MemBuf mb, DWCB * handler, void *handler_data); -SQUIDCEXTERN void file_read(int, char *, int, off_t, DRCB *, void *); -SQUIDCEXTERN void disk_init(void); - -extern void fd_close(int fd); -extern void fd_open(int fd, unsigned int type, const char *); -extern void fd_note(int fd, const char *); -extern void fd_bytes(int fd, int len, unsigned int type); -extern void fdDumpOpen(void); -extern int fdUsageHigh(void); -extern void fdAdjustReserved(void); - -SQUIDCEXTERN void fqdncache_nbgethostbyaddr(const Ip::Address &, FQDNH *, void *); - -SQUIDCEXTERN const char *fqdncache_gethostbyaddr(const Ip::Address &, int flags); -SQUIDCEXTERN void fqdncache_init(void); -void fqdnStats(StoreEntry *); -SQUIDCEXTERN void fqdncacheReleaseInvalid(const char *); - -SQUIDCEXTERN const char *fqdnFromAddr(const Ip::Address &); -SQUIDCEXTERN int fqdncacheQueueDrain(void); -SQUIDCEXTERN void fqdncacheFreeMemory(void); -SQUIDCEXTERN void fqdncache_restart(void); -extern void fqdncache_purgelru(void *); -SQUIDCEXTERN void fqdncacheAddEntryFromHosts(char *addr, wordlist * hostnames); class FwdState; -/** - \defgroup ServerProtocolFTPAPI Server-Side FTP API - \ingroup ServerProtocol - */ - -/// \ingroup ServerProtocolFTPAPI -SQUIDCEXTERN void ftpStart(FwdState *); class HttpRequest; class HttpReply; -/// \ingroup ServerProtocolFTPAPI -SQUIDCEXTERN const char *ftpUrlWith2f(HttpRequest *); - -/** - \defgroup ServerProtocolGopherAPI Server-Side Gopher API - \ingroup ServerProtocol - */ - -/// \ingroup ServerProtocolGopherAPI -SQUIDCEXTERN void gopherStart(FwdState *); - -/// \ingroup ServerProtocolGopherAPI -SQUIDCEXTERN int gopherCachable(const HttpRequest *); - -/** - \defgroup ServerProtocolWhoisAPI Server-Side WHOIS API - \ingroup ServerProtocol - */ - -/// \ingroup ServerProtocolWhoisAPI -SQUIDCEXTERN void whoisStart(FwdState *); - -/* http.c */ -/* for http_hdr_type field */ -#include "HttpHeader.h" -SQUIDCEXTERN int httpCachable(const HttpRequestMethod&); -SQUIDCEXTERN void httpStart(FwdState *); -SQUIDCEXTERN mb_size_t httpBuildRequestPrefix(HttpRequest * request, - HttpRequest * orig_request, - StoreEntry * entry, - MemBuf * mb, - http_state_flags); -extern const char *httpMakeVaryMark(HttpRequest * request, HttpReply const * reply); - -#include "HttpStatusCode.h" - -class StatHist; - -/* Http Cache Control Header Field */ -SQUIDCEXTERN void httpHdrCcInitModule(void); -SQUIDCEXTERN void httpHdrCcCleanModule(void); -SQUIDCEXTERN void httpHdrCcUpdateStats(const HttpHdrCc * cc, StatHist * hist); -extern void httpHdrCcStatDumper(StoreEntry * sentry, int idx, double val, double size, int count); - -/* Http Header Tools */ -class HttpHeaderFieldInfo; -SQUIDCEXTERN HttpHeaderFieldInfo *httpHeaderBuildFieldsInfo(const HttpHeaderFieldAttrs * attrs, int count); -SQUIDCEXTERN void httpHeaderDestroyFieldsInfo(HttpHeaderFieldInfo * info, int count); -SQUIDCEXTERN http_hdr_type httpHeaderIdByName(const char *name, size_t name_len, const HttpHeaderFieldInfo * attrs, int end); -SQUIDCEXTERN http_hdr_type httpHeaderIdByNameDef(const char *name, int name_len); -SQUIDCEXTERN const char *httpHeaderNameById(int id); -SQUIDCEXTERN int httpHeaderHasConnDir(const HttpHeader * hdr, const char *directive); +/* TODO: move to StrList.h */ SQUIDCEXTERN void strListAdd(String * str, const char *item, char del); SQUIDCEXTERN int strListIsMember(const String * str, const char *item, char del); SQUIDCEXTERN int strListIsSubstr(const String * list, const char *s, char del); SQUIDCEXTERN int strListGetItem(const String * str, char del, const char **item, int *ilen, const char **pos); -SQUIDCEXTERN const char *getStringPrefix(const char *str, const char *end); -SQUIDCEXTERN int httpHeaderParseInt(const char *start, int *val); -SQUIDCEXTERN void httpHeaderPutStrf(HttpHeader * hdr, http_hdr_type id, const char *fmt,...) PRINTF_FORMAT_ARG3; - -/* Http Header */ -SQUIDCEXTERN void httpHeaderInitModule(void); -SQUIDCEXTERN void httpHeaderCleanModule(void); + +extern const char *getStringPrefix(const char *str, const char *end); + + /* store report about current header usage and other stats */ void httpHeaderStoreReport(StoreEntry * e); @@ -248,18 +96,6 @@ extern variable_list *snmp_meshCtblFn(variable_list *, snint *); #endif /* SQUID_SNMP */ -#if USE_WCCP -extern void wccpInit(void); -extern void wccpConnectionOpen(void); -extern void wccpConnectionClose(void); -#endif /* USE_WCCP */ - -#if USE_WCCPv2 -extern void wccp2Init(void); -extern void wccp2ConnectionOpen(void); -extern void wccp2ConnectionClose(void); -#endif /* USE_WCCPv2 */ - extern char *mime_get_header(const char *mime, const char *header); extern char *mime_get_header_field(const char *mime, const char *name, const char *prefix); extern size_t headersEnd(const char *, size_t); @@ -278,54 +114,6 @@ extern int mcastSetTtl(int, int); extern IPH mcastJoinGroups; -SQUIDCEXTERN peer *getFirstPeer(void); -SQUIDCEXTERN peer *getFirstUpParent(HttpRequest *); -SQUIDCEXTERN peer *getNextPeer(peer *); -SQUIDCEXTERN peer *getSingleParent(HttpRequest *); -SQUIDCEXTERN int neighborsCount(HttpRequest *); -SQUIDCEXTERN int neighborsUdpPing(HttpRequest *, - StoreEntry *, - IRCB * callback, - void *data, - int *exprep, - int *timeout); -SQUIDCEXTERN void neighborAddAcl(const char *, const char *); - -SQUIDCEXTERN void neighborsUdpAck(const cache_key *, icp_common_t *, const Ip::Address &); -SQUIDCEXTERN void neighborAdd(const char *, const char *, int, int, int, int, int); -SQUIDCEXTERN void neighbors_init(void); -#if USE_HTCP -SQUIDCEXTERN void neighborsHtcpClear(StoreEntry *, const char *, HttpRequest *, const HttpRequestMethod &, htcp_clr_reason); -#endif -SQUIDCEXTERN peer *peerFindByName(const char *); -SQUIDCEXTERN peer *peerFindByNameAndPort(const char *, unsigned short); -SQUIDCEXTERN peer *getDefaultParent(HttpRequest * request); -SQUIDCEXTERN peer *getRoundRobinParent(HttpRequest * request); -SQUIDCEXTERN peer *getWeightedRoundRobinParent(HttpRequest * request); -SQUIDCEXTERN void peerClearRRStart(void); -SQUIDCEXTERN void peerClearRR(void); -SQUIDCEXTERN lookup_t peerDigestLookup(peer * p, HttpRequest * request); -SQUIDCEXTERN peer *neighborsDigestSelect(HttpRequest * request); -SQUIDCEXTERN void peerNoteDigestLookup(HttpRequest * request, peer * p, lookup_t lookup); -SQUIDCEXTERN void peerNoteDigestGone(peer * p); -SQUIDCEXTERN int neighborUp(const peer * e); -SQUIDCEXTERN CBDUNL peerDestroy; -SQUIDCEXTERN const char *neighborTypeStr(const peer * e); -SQUIDCEXTERN peer_t neighborType(const peer *, const HttpRequest *); -SQUIDCEXTERN void peerConnectFailed(peer *); -SQUIDCEXTERN void peerConnectSucceded(peer *); -SQUIDCEXTERN void dump_peer_options(StoreEntry *, peer *); -SQUIDCEXTERN int peerHTTPOkay(const peer *, HttpRequest *); - -SQUIDCEXTERN peer *whichPeer(const Ip::Address &from); - -/* peer_digest.c */ -class PeerDigest; -SQUIDCEXTERN PeerDigest *peerDigestCreate(peer * p); -SQUIDCEXTERN void peerDigestNeeded(PeerDigest * pd); -SQUIDCEXTERN void peerDigestNotePeerGone(PeerDigest * pd); -SQUIDCEXTERN void peerDigestStatsReport(const PeerDigest * pd, StoreEntry * e); - #include "comm/forward.h" extern void getOutgoingAddress(HttpRequest * request, Comm::ConnectionPointer conn); extern Ip::Address getOutgoingAddr(HttpRequest * request, struct peer *dst_peer); @@ -335,60 +123,15 @@ SQUIDCEXTERN void redirectInit(void); SQUIDCEXTERN void redirectShutdown(void); -extern void refreshAddToList(const char *, int, time_t, int, time_t); -extern int refreshIsCachable(const StoreEntry *); -extern int refreshCheckHTTP(const StoreEntry *, HttpRequest *); -extern int refreshCheckICP(const StoreEntry *, HttpRequest *); -extern int refreshCheckHTCP(const StoreEntry *, HttpRequest *); -extern int refreshCheckDigest(const StoreEntry *, time_t delta); -extern time_t getMaxAge(const char *url); -extern void refreshInit(void); -extern const refresh_t *refreshLimits(const char *url); extern void shut_down(int); extern void rotate_logs(int); extern void reconfigure(int); + extern void start_announce(void *unused); extern void waisStart(FwdState *); -SQUIDCEXTERN void statInit(void); -SQUIDCEXTERN void statFreeMemory(void); -SQUIDCEXTERN double median_svc_get(int, int); -SQUIDCEXTERN void pconnHistCount(int, int); -SQUIDCEXTERN int stat5minClientRequests(void); -SQUIDCEXTERN double stat5minCPUUsage(void); -SQUIDCEXTERN double statRequestHitRatio(int minutes); -SQUIDCEXTERN double statRequestHitMemoryRatio(int minutes); -SQUIDCEXTERN double statRequestHitDiskRatio(int minutes); -SQUIDCEXTERN double statByteHitRatio(int minutes); - -/* mem */ -SQUIDCEXTERN void memClean(void); -SQUIDCEXTERN void memInitModule(void); -SQUIDCEXTERN void memCleanModule(void); -SQUIDCEXTERN void memConfigure(void); -SQUIDCEXTERN void *memAllocate(mem_type); -SQUIDCEXTERN void *memAllocString(size_t net_size, size_t * gross_size); -SQUIDCEXTERN void *memAllocBuf(size_t net_size, size_t * gross_size); -SQUIDCEXTERN void *memReallocBuf(void *buf, size_t net_size, size_t * gross_size); -SQUIDCEXTERN void memFree(void *, int type); -void memFree2K(void *); -void memFree4K(void *); -void memFree8K(void *); -void memFree16K(void *); -void memFree32K(void *); -void memFree64K(void *); -SQUIDCEXTERN void memFreeString(size_t size, void *); -SQUIDCEXTERN void memFreeBuf(size_t size, void *); -SQUIDCEXTERN FREE *memFreeBufFunc(size_t size); -SQUIDCEXTERN int memInUse(mem_type); -SQUIDCEXTERN void memDataInit(mem_type, const char *, size_t, int, bool zeroOnPush = true); -SQUIDCEXTERN void memCheckInit(void); - -/* Mem */ -SQUIDCEXTERN void memConfigure(void); - /* ----------------------------------------------------------------- */ /* repl_modules.c */ @@ -402,23 +145,6 @@ extern void storeLogClose(void); extern void storeLogOpen(void); -/* - * store_key_*.c - */ -SQUIDCEXTERN cache_key *storeKeyDup(const cache_key *); -SQUIDCEXTERN cache_key *storeKeyCopy(cache_key *, const cache_key *); -SQUIDCEXTERN void storeKeyFree(const cache_key *); -SQUIDCEXTERN const cache_key *storeKeyScan(const char *); -SQUIDCEXTERN const char *storeKeyText(const cache_key *); -SQUIDCEXTERN const cache_key *storeKeyPublic(const char *, const HttpRequestMethod&); -SQUIDCEXTERN const cache_key *storeKeyPublicByRequest(HttpRequest *); -SQUIDCEXTERN const cache_key *storeKeyPublicByRequestMethod(HttpRequest *, const HttpRequestMethod&); -SQUIDCEXTERN const cache_key *storeKeyPrivate(const char *, const HttpRequestMethod&, int); -SQUIDCEXTERN int storeKeyHashBuckets(int); -SQUIDCEXTERN int storeKeyNull(const cache_key *); -SQUIDCEXTERN void storeKeyInit(void); -SQUIDCEXTERN HASHHASH storeKeyHashHash; -SQUIDCEXTERN HASHCMP storeKeyHashCmp; /* * store_digest.c @@ -444,6 +170,7 @@ /// checks whether the loaded entry should be kept; updates counters extern bool storeRebuildKeepEntry(const StoreEntry &e, const cache_key *key, struct _store_rebuild_data &counts); + /* * store_swapin.c */ @@ -460,6 +187,7 @@ SQUIDCEXTERN int storePendingNClients(const StoreEntry * e); SQUIDCEXTERN int storeClientIsThisAClient(store_client * sc, void *someClient); + SQUIDCEXTERN const char *getMyHostname(void); SQUIDCEXTERN const char *uniqueHostname(void); SQUIDCEXTERN void safeunlink(const char *path, int quiet); @@ -528,46 +256,18 @@ SQUIDCEXTERN void unlinkdUnlink(const char *); #endif -SQUIDCEXTERN AnyP::ProtocolType urlParseProtocol(const char *, const char *e = NULL); -SQUIDCEXTERN void urlInitialize(void); -SQUIDCEXTERN HttpRequest *urlParse(const HttpRequestMethod&, char *, HttpRequest *request = NULL); -SQUIDCEXTERN const char *urlCanonical(HttpRequest *); -SQUIDCEXTERN char *urlCanonicalClean(const HttpRequest *); -SQUIDCEXTERN const char *urlCanonicalFakeHttps(const HttpRequest * request); -SQUIDCEXTERN bool urlIsRelative(const char *); -SQUIDCEXTERN char *urlMakeAbsolute(const HttpRequest *, const char *); -SQUIDCEXTERN char *urlRInternal(const char *host, unsigned short port, const char *dir, const char *name); -SQUIDCEXTERN char *urlInternal(const char *dir, const char *name); -SQUIDCEXTERN int matchDomainName(const char *host, const char *domain); -SQUIDCEXTERN int urlCheckRequest(const HttpRequest *); -SQUIDCEXTERN int urlDefaultPort(AnyP::ProtocolType p); -SQUIDCEXTERN char *urlHostname(const char *url); -SQUIDCEXTERN void urlExtMethodConfigure(void); SQUIDCEXTERN peer_t parseNeighborType(const char *s); -/* tools.c */ -//UNUSED #include "dlink.h" -//UNUSED SQUIDCEXTERN void dlinkAdd(void *data, dlink_node *, dlink_list *); -//UNUSED SQUIDCEXTERN void dlinkAddAfter(void *, dlink_node *, dlink_node *, dlink_list *); -//UNUSED SQUIDCEXTERN void dlinkAddTail(void *data, dlink_node *, dlink_list *); -//UNUSED SQUIDCEXTERN void dlinkDelete(dlink_node * m, dlink_list * list); -//UNUSED SQUIDCEXTERN void dlinkNodeDelete(dlink_node * m); -//UNUSED SQUIDCEXTERN dlink_node *dlinkNodeNew(void); - -SQUIDCEXTERN void kb_incr(kb_t *, size_t); -SQUIDCEXTERN int stringHasWhitespace(const char *); -SQUIDCEXTERN int stringHasCntl(const char *); -SQUIDCEXTERN void linklistPush(link_list **, void *); -SQUIDCEXTERN void *linklistShift(link_list **); -SQUIDCEXTERN int xrename(const char *from, const char *to); -extern int isPowTen(int); -SQUIDCEXTERN void parseEtcHosts(void); -SQUIDCEXTERN int getMyPort(void); -SQUIDCEXTERN void setUmask(mode_t mask); - -SQUIDCEXTERN char *strwordtok(char *buf, char **t); -SQUIDCEXTERN void strwordquote(MemBuf * mb, const char *str); +SQUIDCEXTERN int stringHasWhitespace(const char *); //String.cc +SQUIDCEXTERN int stringHasCntl(const char *); //String.cc +SQUIDCEXTERN void linklistPush(link_list **, void *); //list.cc +SQUIDCEXTERN void *linklistShift(link_list **); //list.cc +SQUIDCEXTERN int xrename(const char *from, const char *to); //disk.cc +extern int isPowTen(int); //int.cc + +SQUIDCEXTERN char *strwordtok(char *buf, char **t); //String.cc + /* * ipc.c @@ -581,45 +281,6 @@ int *wfd, void **hIpc); -class CacheDigestGuessStats; -/* CacheDigest */ -SQUIDCEXTERN CacheDigest *cacheDigestCreate(int capacity, int bpe); -SQUIDCEXTERN void cacheDigestDestroy(CacheDigest * cd); -SQUIDCEXTERN CacheDigest *cacheDigestClone(const CacheDigest * cd); -SQUIDCEXTERN void cacheDigestClear(CacheDigest * cd); -SQUIDCEXTERN void cacheDigestChangeCap(CacheDigest * cd, int new_cap); -SQUIDCEXTERN int cacheDigestTest(const CacheDigest * cd, const cache_key * key); -SQUIDCEXTERN void cacheDigestAdd(CacheDigest * cd, const cache_key * key); -SQUIDCEXTERN void cacheDigestDel(CacheDigest * cd, const cache_key * key); -SQUIDCEXTERN size_t cacheDigestCalcMaskSize(int cap, int bpe); -SQUIDCEXTERN int cacheDigestBitUtil(const CacheDigest * cd); -SQUIDCEXTERN void cacheDigestGuessStatsUpdate(CacheDigestGuessStats * stats, int real_hit, int guess_hit); -SQUIDCEXTERN void cacheDigestGuessStatsReport(const CacheDigestGuessStats * stats, StoreEntry * sentry, const char *label); -SQUIDCEXTERN void cacheDigestReport(CacheDigest * cd, const char *label, StoreEntry * e); - -SQUIDCEXTERN void internalStart(const Comm::ConnectionPointer &clientConn, HttpRequest *, StoreEntry *); -SQUIDCEXTERN int internalCheck(const char *urlpath); -SQUIDCEXTERN int internalStaticCheck(const char *urlpath); -SQUIDCEXTERN char *internalLocalUri(const char *dir, const char *name); -SQUIDCEXTERN char *internalRemoteUri(const char *, unsigned short, const char *, const char *); -SQUIDCEXTERN const char *internalHostname(void); -SQUIDCEXTERN int internalHostnameIs(const char *); - -SQUIDCEXTERN void carpInit(void); -SQUIDCEXTERN peer *carpSelectParent(HttpRequest *); - -SQUIDCEXTERN void peerUserHashInit(void); -SQUIDCEXTERN peer * peerUserHashSelectParent(HttpRequest * request); - -SQUIDCEXTERN void peerSourceHashInit(void); -SQUIDCEXTERN peer * peerSourceHashSelectParent(HttpRequest * request); - -#if USE_LEAKFINDER -SQUIDCEXTERN void leakInit(void); -SQUIDCEXTERN void *leakAddFL(void *, const char *, int); -SQUIDCEXTERN void *leakTouchFL(void *, const char *, int); -SQUIDCEXTERN void *leakFreeFL(void *, const char *, int); -#endif /* * prototypes for system functions missing from system includes @@ -641,8 +302,6 @@ class StatCounters; SQUIDCEXTERN StatCounters *snmpStatGet(int); - /* Vary support functions */ - SQUIDCEXTERN int varyEvaluateMatch(StoreEntry * entry, HttpRequest * req); /* CygWin & Windows NT Port */ /* win32.c */ @@ -668,46 +327,7 @@ #endif - /* external_acl.c */ - class external_acl; - SQUIDCEXTERN void parse_externalAclHelper(external_acl **); - - SQUIDCEXTERN void dump_externalAclHelper(StoreEntry * sentry, const char *name, const external_acl *); - - SQUIDCEXTERN void free_externalAclHelper(external_acl **); - - typedef void EAH(void *data, void *result); - class ACLChecklist; - SQUIDCEXTERN void externalAclLookup(ACLChecklist * ch, void *acl_data, EAH * handler, void *data); - - SQUIDCEXTERN void externalAclInit(void); - - SQUIDCEXTERN void externalAclShutdown(void); - - SQUIDCEXTERN char *strtokFile(void); - -#if USE_WCCPv2 - - SQUIDCEXTERN void parse_wccp2_method(int *v); - SQUIDCEXTERN void free_wccp2_method(int *v); - SQUIDCEXTERN void dump_wccp2_method(StoreEntry * e, const char *label, int v); - SQUIDCEXTERN void parse_wccp2_amethod(int *v); - SQUIDCEXTERN void free_wccp2_amethod(int *v); - SQUIDCEXTERN void dump_wccp2_amethod(StoreEntry * e, const char *label, int v); - - SQUIDCEXTERN void parse_wccp2_service(void *v); - SQUIDCEXTERN void free_wccp2_service(void *v); - SQUIDCEXTERN void dump_wccp2_service(StoreEntry * e, const char *label, void *v); - - SQUIDCEXTERN int check_null_wccp2_service(void *v); - - SQUIDCEXTERN void parse_wccp2_service_info(void *v); - - SQUIDCEXTERN void free_wccp2_service_info(void *v); - - SQUIDCEXTERN void dump_wccp2_service_info(StoreEntry * e, const char *label, void *v); - -#endif +extern char *strtokFile(void); #if USE_AUTH === modified file 'src/redirect.cc' --- src/redirect.cc 2012-08-14 11:53:07 +0000 +++ src/redirect.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,7 @@ #include "client_side_request.h" #include "comm/Connection.h" #include "fde.h" +#include "fqdncache.h" #include "globals.h" #include "HttpRequest.h" #include "helper.h" === modified file 'src/refresh.cc' --- src/refresh.cc 2012-08-14 11:53:07 +0000 +++ src/refresh.cc 2012-08-28 19:12:13 +0000 @@ -46,6 +46,7 @@ #include "protos.h" #include "SquidTime.h" #include "Store.h" +#include "URL.h" typedef enum { rcHTTP, === added file 'src/refresh.h' --- src/refresh.h 1970-01-01 00:00:00 +0000 +++ src/refresh.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,49 @@ +/* + * DEBUG: section 22 Refresh Calculation + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_REFRESH_H_ +#define SQUID_REFRESH_H_ + +extern void refreshAddToList(const char *, int, time_t, int, time_t); +extern int refreshIsCachable(const StoreEntry *); +extern int refreshCheckHTTP(const StoreEntry *, HttpRequest *); +extern int refreshCheckICP(const StoreEntry *, HttpRequest *); +extern int refreshCheckHTCP(const StoreEntry *, HttpRequest *); +extern int refreshCheckDigest(const StoreEntry *, time_t delta); +extern time_t getMaxAge(const char *url); +extern void refreshInit(void); +extern const refresh_t *refreshLimits(const char *url); + + + +#endif /* SQUID_REFRESH_H_ */ === modified file 'src/send-announce.cc' --- src/send-announce.cc 2012-08-14 11:53:07 +0000 +++ src/send-announce.cc 2012-08-28 19:12:13 +0000 @@ -35,13 +35,16 @@ #include "squid.h" #include "comm/Connection.h" +#include "disk.h" #include "event.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "ICP.h" #include "ipcache.h" #include "protos.h" #include "SquidTime.h" +#include "tools.h" static IPH send_announce; === modified file 'src/snmp_agent.cc' --- src/snmp_agent.cc 2012-08-28 13:00:30 +0000 +++ src/snmp_agent.cc 2012-08-28 19:12:13 +0000 @@ -36,11 +36,13 @@ #include "cache_snmp.h" #include "globals.h" #include "mem_node.h" +#include "neighbors.h" #include "protos.h" #include "StatCounters.h" #include "StatHist.h" #include "SquidMath.h" #include "SquidTime.h" +#include "stat.h" #include "Store.h" /************************************************************************ === modified file 'src/ssl/ServerBump.cc' --- src/ssl/ServerBump.cc 2012-08-28 13:00:30 +0000 +++ src/ssl/ServerBump.cc 2012-08-28 19:12:13 +0000 @@ -12,6 +12,7 @@ #include "protos.h" #include "ssl/ServerBump.h" #include "Store.h" +#include "URL.h" CBDATA_NAMESPACED_CLASS_INIT(Ssl, ServerBump); === modified file 'src/ssl/helper.cc' --- src/ssl/helper.cc 2012-08-19 18:21:24 +0000 +++ src/ssl/helper.cc 2012-08-28 19:12:13 +0000 @@ -9,6 +9,8 @@ #include "ssl/helper.h" #include "SquidTime.h" #include "SwapDir.h" +#include "wordlist.h" +#include "protos.h" Ssl::Helper * Ssl::Helper::GetInstance() { === modified file 'src/ssl/support.cc' --- src/ssl/support.cc 2012-08-28 13:00:30 +0000 +++ src/ssl/support.cc 2012-08-28 19:12:13 +0000 @@ -47,6 +47,7 @@ #include "ssl/ErrorDetail.h" #include "ssl/support.h" #include "ssl/gadgets.h" +#include "URL.h" #if HAVE_ERRNO_H #include === modified file 'src/stat.cc' --- src/stat.cc 2012-08-28 13:00:30 +0000 +++ src/stat.cc 2012-08-28 19:12:13 +0000 @@ -33,6 +33,7 @@ */ #include "squid.h" +#include "CacheDigest.h" #include "client_side_request.h" #include "client_side.h" #include "comm/Connection.h" @@ -52,10 +53,13 @@ #include "mgr/IoAction.h" #include "mgr/Registration.h" #include "mgr/ServiceTimesAction.h" +#include "neighbors.h" +#include "PeerDigest.h" #include "protos.h" #include "SquidMath.h" #include "SquidTime.h" #include "StatCounters.h" +#include "stat.h" #include "StoreClient.h" #include "Store.h" #if USE_AUTH === added file 'src/stat.h' --- src/stat.h 1970-01-01 00:00:00 +0000 +++ src/stat.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,47 @@ +/* + * DEBUG: section 18 Cache Manager Statistics + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + +#ifndef SQUID_STAT_H_ +#define SQUID_STAT_H_ + +extern void statInit(void); +extern void statFreeMemory(void); +extern double median_svc_get(int, int); +extern void pconnHistCount(int, int); +extern int stat5minClientRequests(void); +extern double stat5minCPUUsage(void); +extern double statRequestHitRatio(int minutes); +extern double statRequestHitMemoryRatio(int minutes); +extern double statRequestHitDiskRatio(int minutes); +extern double statByteHitRatio(int minutes); + +#endif /* SQUID_STAT_H_ */ === modified file 'src/store.cc' --- src/store.cc 2012-08-28 13:00:30 +0000 +++ src/store.cc 2012-08-28 19:12:13 +0000 @@ -34,6 +34,7 @@ */ #include "squid.h" +#include "CacheDigest.h" #include "CacheManager.h" #include "comm/Connection.h" #include "ETag.h" @@ -54,8 +55,10 @@ #include "stmem.h" #include "StoreClient.h" #include "Store.h" +#include "store_key_md5.h" #include "StoreIOState.h" #include "StoreMeta.h" +#include "store_key_md5.h" #include "SwapDir.h" #include "swap_log_op.h" #if USE_DELAY_POOLS === modified file 'src/store_digest.cc' --- src/store_digest.cc 2012-08-28 13:00:30 +0000 +++ src/store_digest.cc 2012-08-28 19:12:13 +0000 @@ -45,12 +45,15 @@ #include "globals.h" #include "mgr/Registration.h" #include "protos.h" + #if USE_CACHE_DIGESTS - +#include "CacheDigest.h" #include "HttpReply.h" #include "HttpRequest.h" +#include "internal.h" #include "MemObject.h" #include "PeerDigest.h" +#include "refresh.h" #include "SquidTime.h" #include "Store.h" #include "StoreSearch.h" === modified file 'src/store_dir.cc' --- src/store_dir.cc 2012-08-28 13:00:30 +0000 +++ src/store_dir.cc 2012-08-28 19:12:13 +0000 @@ -43,6 +43,7 @@ #include "SquidMath.h" #include "SquidTime.h" #include "Store.h" +#include "store_key_md5.h" #include "StoreHashIndex.h" #include "SwapDir.h" #include "swap_log_op.h" === modified file 'src/store_key_md5.cc' --- src/store_key_md5.cc 2012-08-14 11:53:07 +0000 +++ src/store_key_md5.cc 2012-08-28 19:12:13 +0000 @@ -36,7 +36,9 @@ #include "squid.h" #include "HttpRequest.h" #include "md5.h" -#include "protos.h" +#include "Mem.h" +#include "store_key_md5.h" +#include "URL.h" static cache_key null_key[SQUID_MD5_DIGEST_LENGTH]; === added file 'src/store_key_md5.h' --- src/store_key_md5.h 1970-01-01 00:00:00 +0000 +++ src/store_key_md5.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,58 @@ +/* + * DEBUG: section 20 Storage Manager MD5 Cache Keys + * AUTHOR: Duane Wessels + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + +#ifndef SQUID_STORE_KEY_MD5_H_ +#define SQUID_STORE_KEY_MD5_H_ + +#include "hash.h" +#include "typedefs.h" + +class HttpRequestMethod; +class HttpRequest; + +extern cache_key *storeKeyDup(const cache_key *); +extern cache_key *storeKeyCopy(cache_key *, const cache_key *); +extern void storeKeyFree(const cache_key *); +extern const cache_key *storeKeyScan(const char *); +extern const char *storeKeyText(const cache_key *); +extern const cache_key *storeKeyPublic(const char *, const HttpRequestMethod&); +extern const cache_key *storeKeyPublicByRequest(HttpRequest *); +extern const cache_key *storeKeyPublicByRequestMethod(HttpRequest *, const HttpRequestMethod&); +extern const cache_key *storeKeyPrivate(const char *, const HttpRequestMethod&, int); +extern int storeKeyHashBuckets(int); +extern int storeKeyNull(const cache_key *); +extern void storeKeyInit(void); + +extern HASHHASH storeKeyHashHash; +extern HASHCMP storeKeyHashCmp; + +#endif /* SQUID_STORE_KEY_MD5_H_ */ === modified file 'src/store_rebuild.cc' --- src/store_rebuild.cc 2012-08-15 15:17:32 +0000 +++ src/store_rebuild.cc 2012-08-28 19:12:13 +0000 @@ -40,6 +40,7 @@ #include "protos.h" #include "StatCounters.h" #include "Store.h" +#include "store_key_md5.h" #include "SwapDir.h" #include "StoreSearch.h" #include "SquidTime.h" === modified file 'src/test_cache_digest.cc' --- src/test_cache_digest.cc 2012-08-28 13:00:30 +0000 +++ src/test_cache_digest.cc 2012-08-28 19:12:13 +0000 @@ -37,6 +37,8 @@ */ #include "squid.h" +#include "CacheDigest.h" +#include "store_key_md5.h" #if HAVE_ERRNO_H #include === modified file 'src/tests/stub_mem.cc' --- src/tests/stub_mem.cc 2012-08-08 09:24:40 +0000 +++ src/tests/stub_mem.cc 2012-08-28 19:12:13 +0000 @@ -6,29 +6,28 @@ #define STUB_API "stub_mem.cc" #include "STUB.h" -/* mem* definitions are still in protos.h */ -#include "protos.h" +#include "Mem.h" -extern "C" void +void memFreeString(size_t size, void *buf) { xfree(buf); } -extern "C" void * +void * memAllocString(size_t net_size, size_t * gross_size) { *gross_size=net_size; return xmalloc(net_size); } -extern "C" void +void memFreeBuf(size_t size, void *buf) { xfree(buf); } -extern "C" void * +void * memAllocBuf(size_t net_size, size_t * gross_size) { *gross_size=net_size; @@ -38,7 +37,7 @@ /* net_size is the new size, *gross size is the old gross size, to be changed to * the new gross size as a side-effect. */ -extern "C" void * +void * memReallocBuf(void *oldbuf, size_t net_size, size_t * gross_size) { void *rv=xrealloc(oldbuf,net_size); === modified file 'src/tests/testEvent.cc' --- src/tests/testEvent.cc 2012-08-28 13:00:30 +0000 +++ src/tests/testEvent.cc 2012-08-28 19:12:13 +0000 @@ -8,6 +8,7 @@ #include "event.h" #include "Mem.h" #include "protos.h" +#include "stat.h" #include "testEvent.h" CPPUNIT_TEST_SUITE_REGISTRATION( testEvent ); === modified file 'src/tests/testEventLoop.cc' --- src/tests/testEventLoop.cc 2012-08-14 11:53:07 +0000 +++ src/tests/testEventLoop.cc 2012-08-28 19:12:13 +0000 @@ -7,6 +7,7 @@ #include "EventLoop.h" #include "Mem.h" #include "protos.h" +#include "stat.h" CPPUNIT_TEST_SUITE_REGISTRATION( testEventLoop ); === modified file 'src/tests/testHttpReply.cc' --- src/tests/testHttpReply.cc 2012-08-14 11:53:07 +0000 +++ src/tests/testHttpReply.cc 2012-08-28 19:12:13 +0000 @@ -3,6 +3,7 @@ #include #include "testHttpReply.h" +#include "HttpHeader.h" #include "HttpReply.h" #include "Mem.h" #include "protos.h" === modified file 'src/tests/testHttpRequest.cc' --- src/tests/testHttpRequest.cc 2012-08-28 13:00:30 +0000 +++ src/tests/testHttpRequest.cc 2012-08-28 19:12:13 +0000 @@ -4,6 +4,7 @@ #include #include "testHttpRequest.h" +#include "HttpHeader.h" #include "HttpRequest.h" #include "Mem.h" #include "protos.h" === modified file 'src/tools.cc' --- src/tools.cc 2012-08-28 13:00:30 +0000 +++ src/tools.cc 2012-08-28 19:12:13 +0000 @@ -34,7 +34,10 @@ #include "squid.h" #include "base/Subscription.h" +#include "client_side.h" +#include "disk.h" #include "fde.h" +#include "fqdncache.h" #include "htcp.h" #include "ICP.h" #include "ip/Intercept.h" === added file 'src/tools.h' --- src/tools.h 1970-01-01 00:00:00 +0000 +++ src/tools.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,52 @@ +/* + * DEBUG: section 21 Misc Functions + * AUTHOR: Harvest Derived + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_TOOLS_H_ +#define SQUID_TOOLS_H_ + +/* for kb_t */ +#include "typedefs.h" + +class MemBuf; + +extern void kb_incr(kb_t *, size_t); +extern void parseEtcHosts(void); +extern int getMyPort(void); +extern void setUmask(mode_t mask); +extern void strwordquote(MemBuf * mb, const char *str); + +/* packs, then prints an object using debugs() */ +extern void debugObj(int section, int level, const char *label, void *obj, ObjPackMethod pm); + + +#endif /* SQUID_TOOLS_H_ */ === modified file 'src/tunnel.cc' --- src/tunnel.cc 2012-08-28 13:00:30 +0000 +++ src/tunnel.cc 2012-08-28 19:12:13 +0000 @@ -50,6 +50,7 @@ #include "PeerSelectState.h" #include "protos.h" #include "StatCounters.h" +#include "tools.h" #if USE_DELAY_POOLS #include "DelayId.h" === modified file 'src/ufsdump.cc' --- src/ufsdump.cc 2012-08-28 13:00:30 +0000 +++ src/ufsdump.cc 2012-08-28 19:12:13 +0000 @@ -36,6 +36,7 @@ #include "StoreMeta.h" #include "StoreMetaUnpacker.h" #include "Store.h" +#include "store_key_md5.h" #include "Generic.h" #include "mgr/Registration.h" === modified file 'src/unlinkd.cc' --- src/unlinkd.cc 2012-08-14 11:53:07 +0000 +++ src/unlinkd.cc 2012-08-28 19:12:13 +0000 @@ -34,6 +34,8 @@ */ #include "squid.h" +#include "disk.h" +#include "fd.h" #include "fde.h" #include "globals.h" #include "xusleep.h" === modified file 'src/urn.cc' --- src/urn.cc 2012-08-28 13:00:30 +0000 +++ src/urn.cc 2012-08-28 19:12:13 +0000 @@ -45,6 +45,7 @@ #include "SquidTime.h" #include "icmp/net_db.h" #include "protos.h" +#include "URL.h" #define URN_REQBUF_SZ 4096 === added file 'src/wccp.h' --- src/wccp.h 1970-01-01 00:00:00 +0000 +++ src/wccp.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,45 @@ +/* + * DEBUG: section 80 WCCP Support + * AUTHOR: Glenn Chisholm + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_WCCP_H_ +#define SQUID_WCCP_H_ + +#if USE_WCCP +extern void wccpInit(void); +extern void wccpConnectionOpen(void); +extern void wccpConnectionClose(void); +#endif /* USE_WCCP */ + + + +#endif /* SQUID_WCCP_H_ */ === modified file 'src/wccp2.cc' --- src/wccp2.cc 2012-08-28 13:00:30 +0000 +++ src/wccp2.cc 2012-08-28 19:12:13 +0000 @@ -34,6 +34,7 @@ #if USE_WCCPv2 +#include "cache_cf.h" #include "comm.h" #include "comm/Connection.h" #include "comm/Loops.h" === added file 'src/wccp2.h' --- src/wccp2.h 1970-01-01 00:00:00 +0000 +++ src/wccp2.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,64 @@ +/* + * DEBUG: section 80 WCCP Support + * AUTHOR: Steven Wilton + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_WCCP2_H_ +#define SQUID_WCCP2_H_ + +#if USE_WCCPv2 + +class StoreEntry; + +extern void wccp2Init(void); +extern void wccp2ConnectionOpen(void); +extern void wccp2ConnectionClose(void); +extern void parse_wccp2_method(int *v); +extern void free_wccp2_method(int *v); +extern void dump_wccp2_method(StoreEntry * e, const char *label, int v); +extern void parse_wccp2_amethod(int *v); +extern void free_wccp2_amethod(int *v); +extern void dump_wccp2_amethod(StoreEntry * e, const char *label, int v); + +extern void parse_wccp2_service(void *v); +extern void free_wccp2_service(void *v); +extern void dump_wccp2_service(StoreEntry * e, const char *label, void *v); + +extern int check_null_wccp2_service(void *v); + +extern void parse_wccp2_service_info(void *v); + +extern void free_wccp2_service_info(void *v); + +extern void dump_wccp2_service_info(StoreEntry * e, const char *label, void *v); +#endif /* USE_WCCPv2 */ + +#endif /* WCCP2_H_ */ === modified file 'src/whois.cc' --- src/whois.cc 2012-08-15 15:17:32 +0000 +++ src/whois.cc 2012-08-28 19:12:13 +0000 @@ -44,6 +44,7 @@ #include "protos.h" #include "StatCounters.h" #include "Store.h" +#include "tools.h" #if HAVE_ERRNO_H #include === added file 'src/whois.h' --- src/whois.h 1970-01-01 00:00:00 +0000 +++ src/whois.h 2012-08-28 19:12:13 +0000 @@ -0,0 +1,46 @@ +/* + * DEBUG: section 75 WHOIS protocol + * AUTHOR: Duane Wessels, Kostas Anagnostakis + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#ifndef SQUID_WHOIS_H_ +#define SQUID_WHOIS_H_ + +/** + * \defgroup ServerProtocolWhoisAPI Server-Side WHOIS API + * \ingroup ServerProtocol + */ + +/// \ingroup ServerProtocolWhoisAPI +extern void whoisStart(FwdState *); + + +#endif /* SQUID_WHOIS_H_ */ === modified file 'src/wordlist.h' --- src/wordlist.h 2012-08-14 11:53:07 +0000 +++ src/wordlist.h 2012-08-28 19:12:13 +0000 @@ -47,10 +47,11 @@ MEMPROXY_CLASS_INLINE(wordlist); -SQUIDCEXTERN const char *wordlistAdd(wordlist **, const char *); -SQUIDCEXTERN void wordlistAddWl(wordlist **, wordlist *); -SQUIDCEXTERN void wordlistJoin(wordlist **, wordlist **); -SQUIDCEXTERN wordlist *wordlistDup(const wordlist *); -SQUIDCEXTERN void wordlistDestroy(wordlist **); +extern const char *wordlistAdd(wordlist **, const char *); +extern void wordlistCat(const wordlist *, MemBuf * mb); +extern void wordlistAddWl(wordlist **, wordlist *); +extern void wordlistJoin(wordlist **, wordlist **); +extern wordlist *wordlistDup(const wordlist *); +extern void wordlistDestroy(wordlist **); #endif /* SQUID_WORDLIST_H */