diff options
Diffstat (limited to 'www/squid27')
-rw-r--r-- | www/squid27/Makefile | 446 | ||||
-rw-r--r-- | www/squid27/distinfo | 50 | ||||
-rw-r--r-- | www/squid27/files/follow_xff-2.5.patch | 412 | ||||
-rw-r--r-- | www/squid27/files/follow_xff-configure.patch | 65 | ||||
-rw-r--r-- | www/squid27/files/patch-aa | 11 | ||||
-rw-r--r-- | www/squid27/files/patch-configure | 11 | ||||
-rw-r--r-- | www/squid27/files/patch-helpers-basic_auth-SMB-smb_auth.sh | 13 | ||||
-rw-r--r-- | www/squid27/files/patch-src-cf.data.pre | 17 | ||||
-rw-r--r-- | www/squid27/files/pf_from_ports.patch.in | 20 | ||||
-rw-r--r-- | www/squid27/files/squid.sh | 82 | ||||
-rw-r--r-- | www/squid27/pkg-deinstall | 36 | ||||
-rw-r--r-- | www/squid27/pkg-descr | 15 | ||||
-rw-r--r-- | www/squid27/pkg-install | 164 |
13 files changed, 0 insertions, 1342 deletions
diff --git a/www/squid27/Makefile b/www/squid27/Makefile deleted file mode 100644 index 6276ac71c0c6..000000000000 --- a/www/squid27/Makefile +++ /dev/null @@ -1,446 +0,0 @@ -# New ports collection makefile for: squid24 -# Date created: Tue Mar 27 14:56:08 CEST 2001 -# Whom: Adrian Chadd <adrian@FreeBSD.org> -# -# $FreeBSD$ -# -# Tunables not (yet) configurable via 'make config': -# SQUID_{U,G}ID -# Which user/group squid should run as (default: squid/squid). -# The user and group will be created if they do not already exist using -# a uid:gid of 100:100. -# NOTE: before version 2.5.4_6, these settings defaulted to -# nobody/nogroup. -# If you wish to keep these settings, please define SQUID_UID=nobody and -# SQUID_GID=nogroup in your make environment before you start the update. -# NOTE2: -# Before version 2.5.4_11 the numerical id chosen for SQUID_UID (and -# SQUID_GID respectively) was the first free id greater than or equal 3128. -# If you wish to move your squid user to id 100:100, run "make changeuser", -# please see the changeuser target's definition for further information. -# SQUID_LANGUAGES -# A list of languages for which error page files should be installed -# (default: all) -# -# E.g. use `make SQUID_LANGUAGES="English French"' if you want to -# install the files for these languages only. -# Use `make -VSQUID_LANGUAGES' or scroll down to this variable's -# definition to see which values are valid. -# -# SQUID_DEFAULT_LANG -# If you define SQUID_LANGUAGES, select which language should be the default -# one (this variable defaults to English). This setting can be overwritten -# with squid.conf's error_directory directive. -# -# SQUID_CONFIGURE_ARGS -# Additional configuration options. -# -# To enable them, use e.g -# `make SQUID_CONFIGURE_ARGS="--enable-dlmalloc --enable-truncate" install' -# -# The list below may be incomplete, please see the configure script -# in the squid source distribution for the complete list of additional -# options. -# Note that you probably do not need to worry about these options in most -# cases, they are included in case you want to experiment with them. -# -# --enable-dlmalloc -# Compile and use the malloc package from Doug Lea -# --enable-gnuregex -# Compile and use the supplied GNUregex routines instead of BSD regex. -# --enable-xmalloc-statistics -# Show malloc statistics in status page -# --enable-time-hack -# Optimize time updates to one per second rather than calling gettimeofday() -# --enable-cachemgr-hostname=some.hostname -# Set an explicit hostname in cachemgr.cgi -# --enable-truncate -# Use truncate() rather than unlink() -# --disable-unlinkd -# Do not use "unlinkd" -# --with-aufs-threads=N_THREADS -# Tune the number of worker threads for the aufs object -# --with-coss-membuf-size -# COSS membuf size (default: 1048576 bytes) -# -# This option does not work on FreeBSD at the moment: -# -# --enable-ipf-transparent -# Enable Transparent Proxy support for IP-Filter systems (incl 3.0) -# (IPFilter headers are not currently installed to the base system, -# PRs ports/60700 and misc/44148 describe the problem; see -# http://www.squid-cache.org/Doc/FAQ/FAQ-17.html for information -# about how to do transparent proxying with ipfw) - -PORTNAME= squid -PORTVERSION= 2.5.6 -PORTREVISION= 12 -CATEGORIES= www -MASTER_SITES= \ - ftp://ftp.squid-cache.org/pub/%SUBDIR%/ \ - ftp://ftp.unimelb.edu.au/pub/cwis/servers/unix/squid/%SUBDIR%/ \ - ftp://sunsite.auc.dk/pub/infosystems/squid/%SUBDIR%/ \ - ftp://ftp.leo.org/pub/comp/general/infosys/www/servers/squid/%SUBDIR%/ \ - ${MASTER_SITE_RINGSERVER:S,%SUBDIR%,net/www/squid/&,} -MASTER_SITE_SUBDIR= squid-2/STABLE -DISTNAME= squid-2.5.STABLE6 -DIST_SUBDIR= squid2.5 - -PATCH_SITES= http://www.squid-cache.org/Versions/v2/2.5/bugs/ -PATCHFILES= squid-2.5.STABLE6-ufs_no_valid_dir.patch \ - squid-2.5.STABLE6-ldap_helpers.patch \ - squid-2.5.STABLE6-concurrent_dns_lookups.patch \ - squid-2.5.STABLE6-request_header_max_size.patch \ - squid-2.5.STABLE6-partial_hit_is_miss.patch \ - squid-2.5.STABLE6-HEAD.patch \ - squid-2.5.STABLE6-ufs_create_error.patch \ - squid-2.5.STABLE6-basic_auth_caseinsensitive.patch \ - squid-2.5.STABLE6-active_requests_delaypool.patch \ - squid-2.5.STABLE6-client_db_gc.patch \ - squid-2.5.STABLE6-ntlmtruncated.patch \ - squid-2.5.STABLE6-grammar.patch \ - squid-2.5.STABLE6-errorpage_quote.patch \ - squid-2.5.STABLE6-heap_segfault.patch \ - squid-2.5.STABLE6-initgroups.patch \ - squid-2.5.STABLE6-external_acl_newlines.patch \ - squid-2.5.STABLE6-ntlm_fetch_string.patch \ - squid-2.5.STABLE6-ntlm_noreuse_leak.patch \ - squid-2.5.STABLE6-ntlm_challengereuse_leak.patch \ - squid-2.5.STABLE6-rotate_error.patch \ - squid-2.5.STABLE6-digest_crash.patch \ - squid-2.5.STABLE6-acl_times.patch \ - squid-2.5.STABLE6-http_header_range.patch \ - squid-2.5.STABLE6-Content-Disposition.patch -PATCH_DIST_STRIP= -p1 - -MAINTAINER= tmseck@netcologne.de -COMMENT= The successful WWW proxy cache and accelerator - -CONFLICTS= squid-2.[^5]* -GNU_CONFIGURE= yes -USE_BZIP2= yes -USE_PERL5= yes -USE_REINPLACE= yes - -SQUID_UID?= squid -SQUID_GID?= squid - -MAN8= squid.8 -docs= QUICKSTART README RELEASENOTES.html doc/debug-sections.txt -.if !defined(NOPORTDOCS) -PORTDOCS= ${docs:T} -.endif - -OPTIONS= SQUID_LDAP_AUTH "Install LDAP authentication helpers" off \ - SQUID_DELAY_POOLS "Enable delay pools" off \ - SQUID_SNMP "Enable SNMP support" off \ - SQUID_CARP "Enable CARP support" off \ - SQUID_SSL "Enable SSL support for reverse proxies" off \ - SQUID_PINGER "Install the icmp helper" off \ - SQUID_DNS_HELPER "Use the old 'dnsserver' helper" off \ - SQUID_HTCP "Enable HTCP support" off \ - SQUID_VIA_DB "Enable forward/via database" off \ - SQUID_CACHE_DIGESTS "Enable cache digests" off \ - SQUID_WCCP "Enable Web Cache Coordination Protocol" on \ - SQUID_UNDERSCORES "Allow underscores in hostnames" on \ - SQUID_CHECK_HOSTNAME "Do hostname checking" on \ - SQUID_STRICT_HTTP "Be strictly HTTP compliant" off \ - SQUID_IDENT "Enable ident (RFC 931) lookups" on \ - SQUID_USERAGENT_LOG "Enable User-Agent-header logging" off \ - SQUID_ARP_ACL "Enable ACLs based on ethernet address" off \ - SQUID_PF "Enable transp. proxy support using PF" off \ - SQUID_FOLLOW_XFF "Follow X-Forwarded-For headers" off \ - SQUID_AUFS "Enable the aufs storage scheme" off \ - SQUID_COSS "Enable the COSS storage scheme" off \ - SQUID_STACKTRACES "Create backtraces on fatal errors" off \ - SQUID_RCNG "Install an rcNG startup script" on - -PLIST_FILES= etc/rc.d/squid.sh etc/squid/mib.txt etc/squid/mime.conf.default \ - etc/squid/msntauth.conf.default etc/squid/squid.conf.default \ - sbin/RunAccel sbin/RunCache sbin/squidclient sbin/squid - -icon_files= anthony-binhex.gif anthony-bomb.gif anthony-box.gif \ - anthony-box2.gif anthony-c.gif anthony-compressed.gif \ - anthony-dir.gif anthony-dirup.gif anthony-dvi.gif \ - anthony-f.gif anthony-image.gif anthony-image2.gif \ - anthony-layout.gif anthony-link.gif anthony-movie.gif \ - anthony-pdf.gif anthony-portal.gif anthony-ps.gif \ - anthony-quill.gif anthony-script.gif anthony-sound.gif \ - anthony-tar.gif anthony-tex.gif anthony-text.gif \ - anthony-unknown.gif anthony-xbm.gif anthony-xpm.gif - -error_files= ERR_ACCESS_DENIED ERR_CACHE_ACCESS_DENIED \ - ERR_CACHE_MGR_ACCESS_DENIED ERR_CANNOT_FORWARD \ - ERR_CONNECT_FAIL ERR_DNS_FAIL ERR_FORWARDING_DENIED \ - ERR_FTP_DISABLED ERR_FTP_FAILURE ERR_FTP_FORBIDDEN \ - ERR_FTP_NOT_FOUND ERR_FTP_PUT_CREATED \ - ERR_FTP_PUT_ERROR ERR_FTP_PUT_MODIFIED \ - ERR_FTP_UNAVAILABLE ERR_INVALID_REQ ERR_INVALID_URL \ - ERR_LIFETIME_EXP ERR_NO_RELAY ERR_ONLY_IF_CACHED_MISS \ - ERR_READ_ERROR ERR_READ_TIMEOUT ERR_SHUTTING_DOWN \ - ERR_SOCKET_FAILURE ERR_TOO_BIG ERR_UNSUP_REQ \ - ERR_URN_RESOLVE ERR_WRITE_ERROR ERR_ZERO_SIZE_OBJECT - -libexec= cachemgr.cgi digest_pw_auth diskd dnsserver ip_user_check \ - squid_ldap_auth squid_ldap_group msnt_auth ncsa_auth ntlm_auth \ - pam_auth pinger smb_auth smb_auth.sh squid_unix_group \ - unlinkd wb_auth wb_group wb_ntlmauth wbinfo_group.pl yp_auth - -CONFIGURE_ARGS= --bindir=${PREFIX}/sbin --sysconfdir=${PREFIX}/etc/squid \ - --datadir=${PREFIX}/etc/squid \ - --libexecdir=${PREFIX}/libexec/squid \ - --localstatedir=${PREFIX}/squid \ - --enable-removal-policies="lru heap" - -.include <bsd.port.pre.mk> - -# Authentication methods and modules: - -basic_auth= NCSA PAM YP MSNT SMB winbind -external_acl= ip_user unix_group wbinfo_group winbind_group -MAN8+= pam_auth.8 squid_unix_group.8 -.if defined(WITH_SQUID_LDAP_AUTH) -USE_OPENLDAP= yes -CFLAGS+= -I${LOCALBASE}/include -LDFLAGS+= -L${LOCALBASE}/lib -MAN8+= squid_ldap_auth.8 squid_ldap_group.8 -basic_auth+= LDAP -external_acl+= ldap_group -.endif -CONFIGURE_ARGS+= --enable-auth="basic ntlm digest" \ - --enable-basic-auth-helpers="${basic_auth}" \ - --enable-digest-auth-helpers="password" \ - --enable-external-acl-helpers="${external_acl}" \ - --enable-ntlm-auth-helpers="SMB winbind" - -# Selection of storage schemes: - -storage_schemes= ufs diskd null -.if defined(WITH_SQUID_AUFS) -storage_schemes+= aufs -# Nil aufs threads is default, set any other value via SQUID_CONFIGURE_ARGS -CONFIGURE_ARGS+= --enable-async-io \ - --with-pthreads -CFLAGS+= ${PTHREAD_CFLAGS} -.endif -.if defined(WITH_SQUID_COSS) -storage_schemes+= coss -CONFIGURE_ARGS+= --with-aio -.endif -CONFIGURE_ARGS+= --enable-storeio="${storage_schemes}" - -# Other options set via 'make config': - -.if defined(WITH_SQUID_DELAY_POOLS) -CONFIGURE_ARGS+= --enable-delay-pools -.endif -.if defined(WITH_SQUID_SNMP) -CONFIGURE_ARGS+= --enable-snmp -.endif -.if defined(WITH_SQUID_CARP) -CONFIGURE_ARGS+= --enable-carp -.endif -.if defined(WITH_SQUID_SSL) -# we need to .include bsd.openssl.mk manually here because USE_OPENSSL only -# works when it is defined before bsd.port{.pre}.mk is .included and this is -# not possible when using OPTIONS -.include "${PORTSDIR}/Mk/bsd.openssl.mk" -CONFIGURE_ARGS+= --enable-ssl \ - --with-openssl="${OPENSSLBASE}" -CFLAGS+= -I${OPENSSLINC} -LDFLAGS+= -I${LOCALBASE}/lib -.endif -.if defined(WITH_SQUID_PINGER) -CONFIGURE_ARGS+= --enable-icmp -.endif -.if defined(WITH_SQUID_DNS_HELPER) -CONFIGURE_ARGS+= --disable-internal-dns -.endif -.if defined(WITH_SQUID_HTCP) -CONFIGURE_ARGS+= --enable-htcp -.endif -.if defined(WITH_SQUID_VIA_DB) -CONFIGURE_ARGS+= --enable-forw-via-db -.endif -.if defined(WITH_SQUID_CACHE_DIGESTS) -CONFIGURE_ARGS+= --enable-cache-digests -.endif -.if defined(WITHOUT_SQUID_WCCP) -CONFIGURE_ARGS+= --disable-wccp -.endif -.if !defined(WITHOUT_SQUID_UNDERSCORES) -CONFIGURE_ARGS+= --enable-underscores -.endif -.if defined(WITHOUT_SQUID_CHECK_HOSTNAME) -CONFIGURE_ARGS+= --disable-hostname-checks -.endif -.if defined(WITH_SQUID_STRICT_HTTP) -CONFIGURE_ARGS+= --disable-http-violations -.endif -.if defined(WITHOUT_SQUID_IDENT) -CONFIGURE_ARGS+= --disable-ident-lookups -.endif -.if defined(WITH_SQUID_USERAGENT_LOG) -CONFIGURE_ARGS+= --enable-useragent-log -.endif -.if defined(WITH_SQUID_ARP_ACL) -CONFIGURE_ARGS+= --enable-arp-acl -.endif -.if defined(WITH_SQUID_PF) -CONFIGURE_ARGS+= --enable-pf-transparent -.if ${OSVERSION} < 502106 -pf_includedir= ${LOCALBASE}/include/pf -BUILD_DEPENDS+= ${pf_includedir}/net/pfvar.h:${PORTSDIR}/security/pf -CFLAGS+= -I${pf_includedir} -EXTRA_PATCHES+= ${WRKDIR}/pf_from_ports.patch -.endif -.endif -.if defined(WITH_SQUID_FOLLOW_XFF) -EXTRA_PATCHES+= ${PATCHDIR}/follow_xff-2.5.patch \ - ${PATCHDIR}/follow_xff-configure.patch -CONFIGURE_ARGS+= --enable-follow-x-forwarded-for -.endif -.if defined(WITH_SQUID_STACKTRACES) -CONFIGURE_ARGS+= --enable-stacktraces -.endif -.if !defined(WITHOUT_SQUID_RCNG) -USE_RC_SUBR= yes -rc_del= rcold -rc_state= rcng -.else -rc_del= rcng -rc_state= rcold -.endif - -# Languages: -# -# If you do not define SQUID_LANGUAGES yourself, all available language files -# will be installed; the default language will be English. - -SQUID_LANGUAGES?= \ - Bulgarian Catalan Czech Danish Dutch English Estonian Finnish \ - French German Hebrew Hungarian Italian Japanese Korean Lithuanian \ - Polish Portuguese Romanian Russian-1251 Russian-koi8-r Serbian \ - Simplify_Chinese Slovak Spanish Swedish Traditional_Chinese Turkish -SQUID_DEFAULT_LANG?= English -CONFIGURE_ARGS+= --enable-err-languages="${SQUID_LANGUAGES}" \ - --enable-default-err-language=${SQUID_DEFAULT_LANG} - -# Finally, add additional user specified configuration options: -CONFIGURE_ARGS+= ${SQUID_CONFIGURE_ARGS} - -CONFIGURE_ENV+= CFLAGS="${CFLAGS}" \ - LDFLAGS="${LDFLAGS}" - -pre-patch: -# Check whether we need to create the extra patch that makes pf(4) -# visible to squid's configure script: -.if defined(pf_includedir) - @${SED} -e 's|%%PF_INCLUDEDIR%%|${pf_includedir}|g' \ - -e 's|%%PF_AC_INCLUDEPATH%%|${pf_includedir:S,/,_,g}|g' \ - ${PATCHDIR}/pf_from_ports.patch.in >${WRKDIR}/pf_from_ports.patch -.endif - -post-patch: - @${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/configure - @${REINPLACE_CMD} -e 's|/etc|${PREFIX}/etc|g' ${WRKSRC}/doc/squid.8 - @${REINPLACE_CMD} -e 's|%%SQUID_UID%%|${SQUID_UID}|g' \ - -e 's|%%SQUID_GID%%|${SQUID_GID}|g' ${WRKSRC}/src/cf.data.pre - -pre-install: -# Prevent installation of .orig files by deleting them. - @${FIND} ${WRKSRC} -name '*.bak' -delete - @${FIND} ${WRKSRC} -name '*.orig' -delete -# create an rcOld/rcNG squid.sh: - @${SED} -e 's|%%PREFIX%%|${PREFIX}|g' \ - -e 's|%%SQUID_UID%%|${SQUID_UID}|g' \ - -e 's|%%RC_SUBR%%|${RC_SUBR}|g' \ - -e '/--begin ${rc_del}/,/--end ${rc_del}/d' \ - -e '/--.*${rc_state}/d' ${FILESDIR}/squid.sh \ - >${WRKDIR}/squid.sh - -pre-su-install: - @${SETENV} squid_user=${SQUID_UID} squid_group=${SQUID_GID} \ - PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL - -post-install: -.if defined(WITH_SQUID_PINGER) - ${CHMOD} 4510 ${PREFIX}/libexec/squid/pinger; \ - ${CHGRP} ${SQUID_GID} ${PREFIX}/libexec/squid/pinger -.endif - ${INSTALL_SCRIPT} ${WRKDIR}/squid.sh ${PREFIX}/etc/rc.d -.if !defined(NOPORTDOCS) - @${MKDIR} ${DOCSDIR} - cd ${WRKSRC} && ${INSTALL_DATA} ${docs} ${DOCSDIR} -.endif - @${SETENV} PKG_PREFIX=${PREFIX} \ - ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL -# Create package list: - @for f in ${libexec}; do \ - ${TEST} -f ${PREFIX}/libexec/squid/$${f} && \ - ${ECHO_CMD} "libexec/squid/$${f}" >>${TMPPLIST} || ${TRUE} ; \ - done - @${ECHO_CMD} "@unexec rmdir %D/libexec/squid 2>/dev/null || true" \ - >>${TMPPLIST} - @for f in ${icon_files}; do \ - ${ECHO_CMD} "etc/squid/icons/$${f}" >>${TMPPLIST}; \ - done - @${ECHO_CMD} "@unexec rmdir %D/etc/squid/icons 2>/dev/null || true" \ - >>${TMPPLIST} - @for d in ${SQUID_LANGUAGES}; do \ - for f in ${error_files}; do \ - ${ECHO_CMD} "etc/squid/errors/$${d}/$${f}" >>${TMPPLIST} ; \ - done; \ - ${ECHO_CMD} "@unexec rmdir %D/etc/squid/errors/$${d} 2>/dev/null || true" \ - >>${TMPPLIST}; \ - done - @${ECHO_CMD} "@unexec rmdir %D/etc/squid/errors 2>/dev/null || true" \ - >>${TMPPLIST} - -changeuser: -# Recover from the problem that earlier versions of this port created the -# squid pseudo-user with an id greater than 999 which is not allowed in -# FreeBSD's ports system. The port now uses id 100:100. -# NOTE: -# This target assumes that SQUID_GID is the primary group of SQUID_UID. If you -# have a different setup, do not run this target! -.if ${SQUID_UID:L} == nobody - @${ECHO_CMD} "'nobody' is a system user, you do not need to execute"; \ - ${ECHO_CMD} "this target!" - ${FALSE} -.endif - @if [ `${ID} -u` -ne 0 ]; \ - then ${ECHO_CMD} "Sorry, you must be root to use this target."; ${FALSE}; fi; \ - current_uid=`id -u ${SQUID_UID}`; \ - current_gid=`pw groupshow ${SQUID_GID}|cut -f 3 -d :`; \ - ${ECHO_CMD} "I will remove this user:"; \ - ${ID} -P $${current_uid}; \ - ${ECHO_CMD} "and this group:"; \ - pw groupshow ${SQUID_GID}; \ - ${ECHO_CMD} "I will then re-create them with a user and group id of 100."; \ - ${ECHO_CMD} "Then all files and directories under ${PREFIX} and /var that"; \ - ${ECHO_CMD} "are owned by uid $${current_uid} will be chown(1)'ed."; \ - ${ECHO_CMD} "After that, all files and directories that were accessible"; \ - ${ECHO_CMD} "by group $${current_gid} will chgrp(1)'ed respectively."; \ - ${ECHO_CMD} "Note that this assumes group '${SQUID_GID}' to be the primary"; \ - ${ECHO_CMD} "group of user '${SQUID_UID}'. If you have a different setup"; \ - ${ECHO_CMD} "please abort this target now."; \ - read -p "Press RETURN to continue or CTRL-C to abort:" dummy ; \ - ${ECHO_CMD} "OK, here we go:"; \ - ${ECHO_CMD} "deleting user $${current_uid} and his primary group..."; \ - pw userdel -u $${current_uid}; \ - ${ECHO_CMD} "adding user ${SQUID_UID} with id 100..."; \ - pw groupadd -n ${SQUID_GID} -g 100; \ - pw useradd -n ${SQUID_UID} -u 100 -c "squid caching-proxy pseudo user" \ - -d ${PREFIX}/squid -s /sbin/nologin -h - ; \ - ${ECHO_CMD} "chown(1)'ing everything under ${PREFIX} from $${current_uid} to 100..."; \ - ${FIND} -H ${PREFIX} -user $${current_uid} -exec ${CHOWN} 100 {} \; ; \ - ${ECHO_CMD} "chgrp(1)'ing everything under ${PREFIX} from $${current_gid} to 100..."; \ - ${FIND} -H ${PREFIX} -group $${current_gid} -exec ${CHOWN} :100 {} \; ; \ - ${ECHO_CMD} "chown(1)'ing everything under /var from $${current_uid} to 100..."; \ - ${FIND} -H /var -user $${current_uid} -exec ${CHOWN} 100 {} \; ; \ - ${ECHO_CMD} "chgrp(1)'ing everything under /var from $${current_gid} to 100..."; \ - ${FIND} -H /var -group $${current_gid} -exec ${CHOWN} :100 {} \; ; \ - ${ECHO_CMD} "Finished." - -.include <bsd.port.post.mk> diff --git a/www/squid27/distinfo b/www/squid27/distinfo deleted file mode 100644 index 4cbc03446c7a..000000000000 --- a/www/squid27/distinfo +++ /dev/null @@ -1,50 +0,0 @@ -MD5 (squid2.5/squid-2.5.STABLE6.tar.bz2) = 7fd964ac27b43b613d6b981cc702a29e -SIZE (squid2.5/squid-2.5.STABLE6.tar.bz2) = 1047199 -MD5 (squid2.5/squid-2.5.STABLE6-ufs_no_valid_dir.patch) = 26a4ab522a2469f805f746bcdbe0109c -SIZE (squid2.5/squid-2.5.STABLE6-ufs_no_valid_dir.patch) = 566 -MD5 (squid2.5/squid-2.5.STABLE6-ldap_helpers.patch) = fb7684fa6c797404f46c8ef86122848a -SIZE (squid2.5/squid-2.5.STABLE6-ldap_helpers.patch) = 25444 -MD5 (squid2.5/squid-2.5.STABLE6-concurrent_dns_lookups.patch) = b485488ef0031f26902bb94f55a3a2ed -SIZE (squid2.5/squid-2.5.STABLE6-concurrent_dns_lookups.patch) = 6461 -MD5 (squid2.5/squid-2.5.STABLE6-request_header_max_size.patch) = 1900043f6b73aa8a3cbd5004633a6c5c -SIZE (squid2.5/squid-2.5.STABLE6-request_header_max_size.patch) = 765 -MD5 (squid2.5/squid-2.5.STABLE6-partial_hit_is_miss.patch) = 9ce8322cf6c48dc02a7a51d039489143 -SIZE (squid2.5/squid-2.5.STABLE6-partial_hit_is_miss.patch) = 747 -MD5 (squid2.5/squid-2.5.STABLE6-HEAD.patch) = 929fe3d48046a7d17c0aa314befd8f7c -SIZE (squid2.5/squid-2.5.STABLE6-HEAD.patch) = 895 -MD5 (squid2.5/squid-2.5.STABLE6-ufs_create_error.patch) = 63b5693268cbba233a442b345e5769bb -SIZE (squid2.5/squid-2.5.STABLE6-ufs_create_error.patch) = 847 -MD5 (squid2.5/squid-2.5.STABLE6-basic_auth_caseinsensitive.patch) = eb6f28d6d572c8cf996619aea925a1b6 -SIZE (squid2.5/squid-2.5.STABLE6-basic_auth_caseinsensitive.patch) = 2337 -MD5 (squid2.5/squid-2.5.STABLE6-active_requests_delaypool.patch) = f465bdbbadd83dee417aafeb974a9248 -SIZE (squid2.5/squid-2.5.STABLE6-active_requests_delaypool.patch) = 500 -MD5 (squid2.5/squid-2.5.STABLE6-client_db_gc.patch) = 772a2ed149b89a1addf70cd1dd5def3c -SIZE (squid2.5/squid-2.5.STABLE6-client_db_gc.patch) = 3828 -MD5 (squid2.5/squid-2.5.STABLE6-ntlmtruncated.patch) = c77b3c10fc5d5c9d34ccf41f7623a0fe -SIZE (squid2.5/squid-2.5.STABLE6-ntlmtruncated.patch) = 4383 -MD5 (squid2.5/squid-2.5.STABLE6-grammar.patch) = 963208de03349b6fa143bc099524699c -SIZE (squid2.5/squid-2.5.STABLE6-grammar.patch) = 50267 -MD5 (squid2.5/squid-2.5.STABLE6-errorpage_quote.patch) = b9f329cdf98c7c5a048cdadc32d6874d -SIZE (squid2.5/squid-2.5.STABLE6-errorpage_quote.patch) = 377 -MD5 (squid2.5/squid-2.5.STABLE6-heap_segfault.patch) = c82d9f3972419833b757c0c116c216f8 -SIZE (squid2.5/squid-2.5.STABLE6-heap_segfault.patch) = 867 -MD5 (squid2.5/squid-2.5.STABLE6-initgroups.patch) = 5cd7eb8451754166f543d84c7a9ba6dc -SIZE (squid2.5/squid-2.5.STABLE6-initgroups.patch) = 11060 -MD5 (squid2.5/squid-2.5.STABLE6-external_acl_newlines.patch) = 0e01c58db5545e1b7273d2d244171642 -SIZE (squid2.5/squid-2.5.STABLE6-external_acl_newlines.patch) = 4965 -MD5 (squid2.5/squid-2.5.STABLE6-ntlm_fetch_string.patch) = dbf1826522c14dc64c0c37430bb27b2e -SIZE (squid2.5/squid-2.5.STABLE6-ntlm_fetch_string.patch) = 1606 -MD5 (squid2.5/squid-2.5.STABLE6-ntlm_noreuse_leak.patch) = 6053338662140e9514afd4c3d158590d -SIZE (squid2.5/squid-2.5.STABLE6-ntlm_noreuse_leak.patch) = 3646 -MD5 (squid2.5/squid-2.5.STABLE6-ntlm_challengereuse_leak.patch) = d6bdb1500f947b5aa67c23561f941ddf -SIZE (squid2.5/squid-2.5.STABLE6-ntlm_challengereuse_leak.patch) = 13473 -MD5 (squid2.5/squid-2.5.STABLE6-rotate_error.patch) = e842e11bd987d56e49df020a17fb1ad9 -SIZE (squid2.5/squid-2.5.STABLE6-rotate_error.patch) = 2238 -MD5 (squid2.5/squid-2.5.STABLE6-digest_crash.patch) = b0e5a15164ac7f14682bc200f2efd6c9 -SIZE (squid2.5/squid-2.5.STABLE6-digest_crash.patch) = 1250 -MD5 (squid2.5/squid-2.5.STABLE6-acl_times.patch) = 91c69f9a5cebd5d84a4eee63ea10be99 -SIZE (squid2.5/squid-2.5.STABLE6-acl_times.patch) = 3047 -MD5 (squid2.5/squid-2.5.STABLE6-http_header_range.patch) = 83b25961601597375682afde86ce23a8 -SIZE (squid2.5/squid-2.5.STABLE6-http_header_range.patch) = 616 -MD5 (squid2.5/squid-2.5.STABLE6-Content-Disposition.patch) = c11ca0bcf406b4240a745fc52b063495 -SIZE (squid2.5/squid-2.5.STABLE6-Content-Disposition.patch) = 1815 diff --git a/www/squid27/files/follow_xff-2.5.patch b/www/squid27/files/follow_xff-2.5.patch deleted file mode 100644 index 6f062e5c3317..000000000000 --- a/www/squid27/files/follow_xff-2.5.patch +++ /dev/null @@ -1,412 +0,0 @@ -! This is a reduced part of the original follow-XFF patchset from -! devel.squid-cache.org for use with the FreeBSD squid-2.5 port. -Index: src/acl.c ---- src/acl.c 13 May 2003 02:14:12 -0000 1.43.2.16 -+++ src/acl.c 23 Nov 2003 14:20:12 -0000 -@@ -2001,6 +2001,11 @@ - cbdataLock(A); - if (request != NULL) { - checklist->request = requestLink(request); -+#if FOLLOW_X_FORWARDED_FOR -+ if (Config.onoff.acl_uses_indirect_client) { -+ checklist->src_addr = request->indirect_client_addr; -+ } else -+#endif /* FOLLOW_X_FORWARDED_FOR */ - checklist->src_addr = request->client_addr; - checklist->my_addr = request->my_addr; - checklist->my_port = request->my_port; -Index: src/cf.data.pre ---- src/cf.data.pre 7 Nov 2003 03:14:30 -0000 1.49.2.46 -+++ src/cf.data.pre 23 Nov 2003 14:20:17 -0000 -@@ -2065,6 +2065,92 @@ - NOCOMMENT_END - DOC_END - -+NAME: follow_x_forwarded_for -+TYPE: acl_access -+IFDEF: FOLLOW_X_FORWARDED_FOR -+LOC: Config.accessList.followXFF -+DEFAULT: none -+DEFAULT_IF_NONE: deny all -+DOC_START -+ Allowing or Denying the X-Forwarded-For header to be followed to -+ find the original source of a request. -+ -+ Requests may pass through a chain of several other proxies -+ before reaching us. The X-Forwarded-For header will contain a -+ comma-separated list of the IP addresses in the chain, with the -+ rightmost address being the most recent. -+ -+ If a request reaches us from a source that is allowed by this -+ configuration item, then we consult the X-Forwarded-For header -+ to see where that host received the request from. If the -+ X-Forwarded-For header contains multiple addresses, and if -+ acl_uses_indirect_client is on, then we continue backtracking -+ until we reach an address for which we are not allowed to -+ follow the X-Forwarded-For header, or until we reach the first -+ address in the list. (If acl_uses_indirect_client is off, then -+ it's impossible to backtrack through more than one level of -+ X-Forwarded-For addresses.) -+ -+ The end result of this process is an IP address that we will -+ refer to as the indirect client address. This address may -+ be treated as the client address for access control, delay -+ pools and logging, depending on the acl_uses_indirect_client, -+ delay_pool_uses_indirect_client and log_uses_indirect_client -+ options. -+ -+ SECURITY CONSIDERATIONS: -+ -+ Any host for which we follow the X-Forwarded-For header -+ can place incorrect information in the header, and Squid -+ will use the incorrect information as if it were the -+ source address of the request. This may enable remote -+ hosts to bypass any access control restrictions that are -+ based on the client's source addresses. -+ -+ For example: -+ -+ acl localhost src 127.0.0.1 -+ acl my_other_proxy srcdomain .proxy.example.com -+ follow_x_forwarded_for allow localhost -+ follow_x_forwarded_for allow my_other_proxy -+DOC_END -+ -+NAME: acl_uses_indirect_client -+COMMENT: on|off -+TYPE: onoff -+IFDEF: FOLLOW_X_FORWARDED_FOR -+DEFAULT: on -+LOC: Config.onoff.acl_uses_indirect_client -+DOC_START -+ Controls whether the indirect client address -+ (see follow_x_forwarded_for) is used instead of the -+ direct client address in acl matching. -+DOC_END -+ -+NAME: delay_pool_uses_indirect_client -+COMMENT: on|off -+TYPE: onoff -+IFDEF: FOLLOW_X_FORWARDED_FOR && DELAY_POOLS -+DEFAULT: on -+LOC: Config.onoff.delay_pool_uses_indirect_client -+DOC_START -+ Controls whether the indirect client address -+ (see follow_x_forwarded_for) is used instead of the -+ direct client address in delay pools. -+DOC_END -+ -+NAME: log_uses_indirect_client -+COMMENT: on|off -+TYPE: onoff -+IFDEF: FOLLOW_X_FORWARDED_FOR -+DEFAULT: on -+LOC: Config.onoff.log_uses_indirect_client -+DOC_START -+ Controls whether the indirect client address -+ (see follow_x_forwarded_for) is used instead of the -+ direct client address in the access log. -+DOC_END -+ - NAME: http_access - TYPE: acl_access - LOC: Config.accessList.http -Index: src/client_side.c ---- src/client_side.c 2 Sep 2003 02:13:45 -0000 1.47.2.39 -+++ src/client_side.c 23 Nov 2003 14:20:22 -0000 -@@ -109,6 +109,11 @@ - #if USE_IDENT - static IDCB clientIdentDone; - #endif -+#if FOLLOW_X_FORWARDED_FOR -+static void clientFollowXForwardedForStart(void *data); -+static void clientFollowXForwardedForNext(void *data); -+static void clientFollowXForwardedForDone(int answer, void *data); -+#endif /* FOLLOW_X_FORWARDED_FOR */ - static int clientOnlyIfCached(clientHttpRequest * http); - static STCB clientSendMoreData; - static STCB clientCacheHit; -@@ -177,10 +182,179 @@ - return ch; - } - -+#if FOLLOW_X_FORWARDED_FOR -+/* -+ * clientFollowXForwardedForStart() copies the X-Forwarded-For -+ * header into x_forwarded_for_iterator and passes control to -+ * clientFollowXForwardedForNext(). -+ * -+ * clientFollowXForwardedForNext() checks the indirect_client_addr -+ * against the followXFF ACL and passes the result to -+ * clientFollowXForwardedForDone(). -+ * -+ * clientFollowXForwardedForDone() either grabs the next address -+ * from the tail of x_forwarded_for_iterator and loops back to -+ * clientFollowXForwardedForNext(), or cleans up and passes control to -+ * clientAccessCheck(). -+ */ -+ -+static void -+clientFollowXForwardedForStart(void *data) -+{ -+ clientHttpRequest *http = data; -+ request_t *request = http->request; -+ if (Config.accessList.followXFF -+ && httpHeaderHas(&request->header, HDR_X_FORWARDED_FOR)) -+ { -+ request->x_forwarded_for_iterator = httpHeaderGetList( -+ &request->header, HDR_X_FORWARDED_FOR); -+ debug(33, 5) ("clientFollowXForwardedForStart: indirect_client_addr=%s XFF='%s'\n", -+ inet_ntoa(request->indirect_client_addr), -+ strBuf(request->x_forwarded_for_iterator)); -+ clientFollowXForwardedForNext(http); -+ } else { -+ /* not configured to follow X-Forwarded-For, or nothing to follow */ -+ debug(33, 5) ("clientFollowXForwardedForStart: nothing to do\n"); -+ clientFollowXForwardedForDone(-1, http); -+ } -+} -+ -+static void -+clientFollowXForwardedForNext(void *data) -+{ -+ clientHttpRequest *http = data; -+ request_t *request = http->request; -+ debug(33, 5) ("clientFollowXForwardedForNext: indirect_client_addr=%s XFF='%s'\n", -+ inet_ntoa(request->indirect_client_addr), -+ strBuf(request->x_forwarded_for_iterator)); -+ if (strLen(request->x_forwarded_for_iterator) != 0) { -+ /* check the acl to see whether to believe the X-Forwarded-For header */ -+ http->acl_checklist = clientAclChecklistCreate( -+ Config.accessList.followXFF, http); -+ aclNBCheck(http->acl_checklist, clientFollowXForwardedForDone, http); -+ } else { -+ /* nothing left to follow */ -+ debug(33, 5) ("clientFollowXForwardedForNext: nothing more to do\n"); -+ clientFollowXForwardedForDone(-1, http); -+ } -+} -+ -+static void -+clientFollowXForwardedForDone(int answer, void *data) -+{ -+ clientHttpRequest *http = data; -+ request_t *request = http->request; -+ /* -+ * answer should be be ACCESS_ALLOWED or ACCESS_DENIED if we are -+ * called as a result of ACL checks, or -1 if we are called when -+ * there's nothing left to do. -+ */ -+ if (answer == ACCESS_ALLOWED) { -+ /* -+ * The IP address currently in request->indirect_client_addr -+ * is trusted to use X-Forwarded-For. Remove the last -+ * comma-delimited element from x_forwarded_for_iterator and use -+ * it to to replace indirect_client_addr, then repeat the cycle. -+ */ -+ const char *p; -+ const char *asciiaddr; -+ int l; -+ struct in_addr addr; -+ debug(33, 5) ("clientFollowXForwardedForDone: indirect_client_addr=%s is trusted\n", -+ inet_ntoa(request->indirect_client_addr)); -+ p = strBuf(request->x_forwarded_for_iterator); -+ l = strLen(request->x_forwarded_for_iterator); -+ -+ /* -+ * XXX x_forwarded_for_iterator should really be a list of -+ * IP addresses, but it's a String instead. We have to -+ * walk backwards through the String, biting off the last -+ * comma-delimited part each time. As long as the data is in -+ * a String, we should probably implement and use a variant of -+ * strListGetItem() that walks backwards instead of forwards -+ * through a comma-separated list. But we don't even do that; -+ * we just do the work in-line here. -+ */ -+ /* skip trailing space and commas */ -+ while (l > 0 && (p[l-1] == ',' || xisspace(p[l-1]))) -+ l--; -+ strCut(request->x_forwarded_for_iterator, l); -+ /* look for start of last item in list */ -+ while (l > 0 && ! (p[l-1] == ',' || xisspace(p[l-1]))) -+ l--; -+ asciiaddr = p+l; -+ if (inet_aton(asciiaddr, &addr) == 0) { -+ /* the address is not well formed; do not use it */ -+ debug(33, 3) ("clientFollowXForwardedForDone: malformed address '%s'\n", -+ asciiaddr); -+ goto done; -+ } -+ debug(33, 3) ("clientFollowXForwardedForDone: changing indirect_client_addr from %s to '%s'\n", -+ inet_ntoa(request->indirect_client_addr), -+ asciiaddr); -+ request->indirect_client_addr = addr; -+ strCut(request->x_forwarded_for_iterator, l); -+ if (! Config.onoff.acl_uses_indirect_client) { -+ /* -+ * If acl_uses_indirect_client is off, then it's impossible -+ * to follow more than one level of X-Forwarded-For. -+ */ -+ goto done; -+ } -+ clientFollowXForwardedForNext(http); -+ return; -+ } else if (answer == ACCESS_DENIED) { -+ debug(33, 5) ("clientFollowXForwardedForDone: indirect_client_addr=%s not trusted\n", -+ inet_ntoa(request->indirect_client_addr)); -+ } else { -+ debug(33, 5) ("clientFollowXForwardedForDone: indirect_client_addr=%s nothing more to do\n", -+ inet_ntoa(request->indirect_client_addr)); -+ } -+done: -+ /* clean up, and pass control to clientAccessCheck */ -+ debug(33, 6) ("clientFollowXForwardedForDone: cleanup\n"); -+ if (Config.onoff.log_uses_indirect_client) { -+ /* -+ * Ensure that the access log shows the indirect client -+ * instead of the direct client. -+ */ -+ ConnStateData *conn = http->conn; -+ conn->log_addr = request->indirect_client_addr; -+ conn->log_addr.s_addr &= Config.Addrs.client_netmask.s_addr; -+ debug(33, 3) ("clientFollowXForwardedForDone: setting log_addr=%s\n", -+ inet_ntoa(conn->log_addr)); -+ } -+ stringClean(&request->x_forwarded_for_iterator); -+ request->flags.done_follow_x_forwarded_for = 1; -+ http->acl_checklist = NULL; /* XXX do we need to aclChecklistFree() ? */ -+ clientAccessCheck(http); -+} -+#endif /* FOLLOW_X_FORWARDED_FOR */ -+ - void - clientAccessCheck(void *data) - { - clientHttpRequest *http = data; -+#if FOLLOW_X_FORWARDED_FOR -+ if (! http->request->flags.done_follow_x_forwarded_for -+ && httpHeaderHas(&http->request->header, HDR_X_FORWARDED_FOR)) -+ { -+ /* -+ * There's an X-ForwardedFor header and we haven't yet tried -+ * to follow it to find the indirect_client_addr. Follow it now. -+ * clientFollowXForwardedForDone() will eventually pass control -+ * back to us. -+ * -+ * XXX perhaps our caller should have called -+ * clientFollowXForwardedForStart instead. Then we wouldn't -+ * need to do this little dance transferring control over -+ * there and then back here, and we wouldn't need the -+ * done_follow_x_forwarded_for flag. -+ */ -+ clientFollowXForwardedForStart(data); -+ return; -+ } -+#endif /* FOLLOW_X_FORWARDED_FOR */ - if (checkAccelOnly(http)) { - /* deny proxy requests in accel_only mode */ - debug(33, 1) ("clientAccessCheck: proxy request denied in accel_only mode\n"); -@@ -325,6 +499,9 @@ - new_request->http_ver = old_request->http_ver; - httpHeaderAppend(&new_request->header, &old_request->header); - new_request->client_addr = old_request->client_addr; -+#if FOLLOW_X_FORWARDED_FOR -+ new_request->indirect_client_addr = old_request->indirect_client_addr; -+#endif /* FOLLOW_X_FORWARDED_FOR */ - new_request->my_addr = old_request->my_addr; - new_request->my_port = old_request->my_port; - new_request->flags.redirected = 1; -@@ -3051,6 +3228,9 @@ - safe_free(http->log_uri); - http->log_uri = xstrdup(urlCanonicalClean(request)); - request->client_addr = conn->peer.sin_addr; -+#if FOLLOW_X_FORWARDED_FOR -+ request->indirect_client_addr = request->client_addr; -+#endif /* FOLLOW_X_FORWARDED_FOR */ - request->my_addr = conn->me.sin_addr; - request->my_port = ntohs(conn->me.sin_port); - request->http_ver = http->http_ver; -Index: src/delay_pools.c ---- src/delay_pools.c 19 Jun 2003 02:13:57 -0000 1.5.54.6 -+++ src/delay_pools.c 23 Nov 2003 14:20:23 -0000 -@@ -318,6 +318,11 @@ - r = http->request; - - memset(&ch, '\0', sizeof(ch)); -+#if FOLLOW_X_FORWARDED_FOR -+ if (Config.onoff.delay_pool_uses_indirect_client) { -+ ch.src_addr = r->indirect_client_addr; -+ } else -+#endif /* FOLLOW_X_FORWARDED_FOR */ - ch.src_addr = r->client_addr; - ch.my_addr = r->my_addr; - ch.my_port = r->my_port; -Index: src/structs.h -*** src/structs.h.orig Thu Feb 26 20:32:47 2004 ---- src/structs.h Thu Feb 26 20:34:51 2004 -*************** -*** 594,599 **** ---- 594,604 ---- - int pipeline_prefetch; - int request_entities; - int detect_broken_server_pconns; -+ #if FOLLOW_X_FORWARDED_FOR -+ int acl_uses_indirect_client; -+ int delay_pool_uses_indirect_client; -+ int log_uses_indirect_client; -+ #endif /* FOLLOW_X_FORWARDED_FOR */ - } onoff; - acl *aclList; - struct { -*************** -*** 615,620 **** ---- 620,628 ---- - acl_access *reply; - acl_address *outgoing_address; - acl_tos *outgoing_tos; -+ #if FOLLOW_X_FORWARDED_FOR -+ acl_access *followXFF; -+ #endif /* FOLLOW_X_FORWARDED_FOR */ - } accessList; - acl_deny_info_list *denyInfoList; - struct _authConfig { -*************** -*** 1611,1616 **** ---- 1619,1629 ---- - unsigned int internal:1; - unsigned int body_sent:1; - unsigned int reset_tcp:1; -+ #if FOLLOW_X_FORWARDED_FOR -+ /* XXX this flag could be eliminated; -+ * see comments in clientAccessCheck */ -+ unsigned int done_follow_x_forwarded_for; -+ #endif /* FOLLOW_X_FORWARDED_FOR */ - }; - - struct _link_list { -*************** -*** 1657,1662 **** ---- 1670,1678 ---- - int max_forwards; - /* these in_addr's could probably be sockaddr_in's */ - struct in_addr client_addr; -+ #if FOLLOW_X_FORWARDED_FOR -+ struct in_addr indirect_client_addr; /* after following X-Forwarded-For */ -+ #endif /* FOLLOW_X_FORWARDED_FOR */ - struct in_addr my_addr; - unsigned short my_port; - HttpHeader header; -*************** -*** 1667,1672 **** ---- 1683,1693 ---- - char *peer_login; /* Configured peer login:password */ - time_t lastmod; /* Used on refreshes */ - const char *vary_headers; /* Used when varying entities are detected. Changes how the store key is calculated */ -+ #if FOLLOW_X_FORWARDED_FOR -+ /* XXX a list of IP addresses would be a better data structure -+ * than this String */ -+ String x_forwarded_for_iterator; -+ #endif /* FOLLOW_X_FORWARDED_FOR */ - }; - - struct _cachemgr_passwd { diff --git a/www/squid27/files/follow_xff-configure.patch b/www/squid27/files/follow_xff-configure.patch deleted file mode 100644 index 0cf30da6c147..000000000000 --- a/www/squid27/files/follow_xff-configure.patch +++ /dev/null @@ -1,65 +0,0 @@ -!Simulate the autotools bootstrap of the follow-x-forwarded-for patchset. -! -!Beware that all line number informations in configure.log greater -!than 2972 are offset by at least -29 (correcting all line numbers would have -!bloated the patch by 92kB!) ---- include/autoconf.h.in.orig Sat Jan 18 02:46:11 2003 -+++ include/autoconf.h.in Thu Jun 24 13:19:07 2004 -@@ -291,6 +291,12 @@ - #define USE_IDENT 1 - - /* -+ * Compile in support for following X-Forwarded-For headers? -+ * Enabled by default. -+ */ -+#define FOLLOW_X_FORWARDED_FOR 1 -+ -+/* - * If your system has statvfs(), and if it actually works! - */ - #undef HAVE_STATVFS ---- configure.orig Tue Mar 2 10:18:14 2004 -+++ configure Tue Mar 2 10:18:56 2004 -@@ -222,6 +222,12 @@ - variance within an accelerator setup. - Typically used together with other code - that adds custom HTTP headers to the requests." -+ac_help="$ac_help -+ --enable-follow-x-forwarded-for -+ Enable support for following the X-Forwarded-For -+ HTTP header to try to find the IP address of the -+ original or indirect client when a request has -+ been forwarded through other proxies." - - # Initialize some variables set by options. - # The variables have the same names as the options, with -@@ -2966,6 +2972,29 @@ - fi - - -+follow_xff=1 -+# Check whether --enable-follow-x-forwarded-for or --disable-follow-x-forwarded-for was given. -+if test "${enable_follow_x_forwarded_for+set}" = set; then -+ enableval="$enable_follow_x_forwarded_for" -+ if test "$enableval" = "yes" ; then -+ echo "follow X-Forwarded-For enabled" -+ follow_xff=1 -+ fi -+ -+fi -+ -+if test $follow_xff = 1; then -+ cat >> confdefs.h <<\EOF -+#define FOLLOW_X_FORWARDED_FOR 1 -+EOF -+ -+else -+ cat >> confdefs.h <<\EOF -+#define FOLLOW_X_FORWARDED_FOR 0 -+EOF -+ -+fi -+ - # Force some compilers to use ANSI features - # - case "$host" in diff --git a/www/squid27/files/patch-aa b/www/squid27/files/patch-aa deleted file mode 100644 index ec93f2dd3c39..000000000000 --- a/www/squid27/files/patch-aa +++ /dev/null @@ -1,11 +0,0 @@ ---- include/squid_types.h.orig Mon Jul 7 00:45:26 2003 -+++ include/squid_types.h Mon Jul 7 00:48:39 2003 -@@ -66,8 +66,5 @@ - #if HAVE_SYS_TYPES_H - #include <sys/types.h> - #endif --#if HAVE_SYS_BITYPES_H --#include <sys/bitypes.h> --#endif - - #endif /* SQUID_TYPES_H */ diff --git a/www/squid27/files/patch-configure b/www/squid27/files/patch-configure deleted file mode 100644 index 2d6d233edac4..000000000000 --- a/www/squid27/files/patch-configure +++ /dev/null @@ -1,11 +0,0 @@ ---- configure.orig Tue Mar 2 11:29:57 2004 -+++ configure Tue Mar 2 11:30:34 2004 -@@ -2236,6 +2236,8 @@ - ;; - *-solaris-*) - ;; -+ *-freebsd*) -+ ;; - *) - echo "WARNING: ARP ACL support probably won't work on $host." - sleep 10 diff --git a/www/squid27/files/patch-helpers-basic_auth-SMB-smb_auth.sh b/www/squid27/files/patch-helpers-basic_auth-SMB-smb_auth.sh deleted file mode 100644 index 8115ac0b7938..000000000000 --- a/www/squid27/files/patch-helpers-basic_auth-SMB-smb_auth.sh +++ /dev/null @@ -1,13 +0,0 @@ -*** helpers/basic_auth/SMB/smb_auth.sh.orig Thu Feb 26 20:58:22 2004 ---- helpers/basic_auth/SMB/smb_auth.sh Thu Feb 26 20:59:45 2004 -*************** -*** 17,22 **** ---- 17,24 ---- - # along with this program; if not, write to the Free Software - # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - -+ SAMBAPREFIX=${SAMBAPREFIX:-/usr/local/bin} -+ - read DOMAINNAME - read PASSTHROUGH - read NMBADDR diff --git a/www/squid27/files/patch-src-cf.data.pre b/www/squid27/files/patch-src-cf.data.pre deleted file mode 100644 index ac5b4bd7ef61..000000000000 --- a/www/squid27/files/patch-src-cf.data.pre +++ /dev/null @@ -1,17 +0,0 @@ ---- src/cf.data.pre.orig Fri Aug 20 16:23:18 2004 -+++ src/cf.data.pre Fri Aug 20 16:25:23 2004 -@@ -2396,12 +2396,12 @@ - - NAME: cache_effective_user - TYPE: string --DEFAULT: nobody -+DEFAULT: %%SQUID_UID%% - LOC: Config.effectiveUser - DOC_START - If you start Squid as root, it will change its effective/real - UID/GID to the user specified below. The default is to change -- to UID to nobody. If you define cache_effective_user, but not -+ to UID to %%SQUID_UID%%. If you define cache_effective_user, but not - cache_effective_group, Squid sets the GID to the effective - user's default group ID (taken from the password file) and - supplementary group list from the from groups membership of diff --git a/www/squid27/files/pf_from_ports.patch.in b/www/squid27/files/pf_from_ports.patch.in deleted file mode 100644 index dd0617e41500..000000000000 --- a/www/squid27/files/pf_from_ports.patch.in +++ /dev/null @@ -1,20 +0,0 @@ ---- configure.orig Thu Jun 10 12:22:06 2004 -+++ configure Thu Jun 10 13:31:53 2004 -@@ -3781,7 +3781,7 @@ - memory.h \ - mount.h \ - net/if.h \ -- net/pfvar.h \ -+ %%PF_INCLUDEDIR%%/net/pfvar.h \ - netdb.h \ - netinet/if_ether.h \ - netinet/in.h \ -@@ -7604,7 +7604,7 @@ - echo $ac_n "checking if PF header file is installed""... $ac_c" 1>&6 - echo "configure:7606: checking if PF header file is installed" >&5 - # hold on to your hats... -- if test "$ac_cv_header_net_pfvar_h" = "yes"; then -+ if test "$ac_cv_header_%%PF_AC_INCLUDEPATH%%_net_pfvar_h" = "yes"; then - PF_TRANSPARENT="yes" - cat >> confdefs.h <<\EOF - #define PF_TRANSPARENT 1 diff --git a/www/squid27/files/squid.sh b/www/squid27/files/squid.sh deleted file mode 100644 index db49ae683c01..000000000000 --- a/www/squid27/files/squid.sh +++ /dev/null @@ -1,82 +0,0 @@ -#!/bin/sh -# -# $FreeBSD$ -# -# --begin rcng -# PROVIDE: squid -# REQUIRE: NETWORKING SERVERS -# BEFORE: DAEMON -# KEYWORD: FreeBSD shutdown -# -# Note: -# Set "squid_enable=yes" in either /etc/rc.conf, /etc/rc.conf.local or -# /etc/rc.conf.d/squid to make this script actually do something. There -# you can also set squid_chdir, squid_user, and squid_flags. -# -# Please see squid(8), rc.conf(5) and rc(8) for further details. -# -# --end rcng - -name=squid -command=%%PREFIX%%/sbin/squid -# --begin rcng -extra_commands=reload -reload_cmd="${command} -k reconfigure" -restart_cmd=squid_restart -# --end rcng -stop_cmd="${command} -k shutdown" -squid_chdir=${squid_chdir:-%%PREFIX%%/squid/logs} -squid_enable=${squid_enable:-"NO"} -squid_flags=${squid_flags-"-D"} -squid_user=${squid_user:-%%SQUID_UID%%} -default_config=%%PREFIX%%/etc/squid/squid.conf - -# --begin rcng -squid_restart() { - run_rc_command stop - run_rc_command poll - run_rc_command start -} - -. %%RC_SUBR%% -rcvar=`set_rcvar` -load_rc_config ${name} - -# squid(8) will not start if ${default_config} is not present so try -# to catch that beforehand via ${required_files} rather than make -# squid(8) crash. -# If you remove the default configuration file make sure to add -# '-f /path/to/your/squid.conf' to squid_flags - -if [ -z "${squid_flags}" ]; then - required_files=${default_config} -fi -required_dirs=${squid_chdir} -run_rc_command "$1" -# --end rcng -# --begin rcold -case $1 in -start) - if [ -x "${command}" -a \ - \( -f "${default_config}" -o "${squid_flags}" \) ]; then - echo -n " ${name}" - (cd ${squid_chdir} && exec su -fm ${squid_user} -c \ - "${command} ${squid_flags}") - fi - ;; -stop) - if [ -x "${command}" ]; then - echo -n " ${name}" - ${stop_cmd} - while ps -xcU ${squid_user} | grep -q squid; do - sleep 2 - done - fi - ;; - *) - echo "usage: ${0##*/} {start|stop}" >&2 - exit 64 - ;; -esac -exit 0 -# --end rcold diff --git a/www/squid27/pkg-deinstall b/www/squid27/pkg-deinstall deleted file mode 100644 index 42ccaecce0b6..000000000000 --- a/www/squid27/pkg-deinstall +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/sh -# -# $FreeBSD$ -# - -PATH=/bin:/usr/bin:/usr/sbin - -case $2 in -DEINSTALL) - cd ${PKG_PREFIX}/etc/squid || exit 1 - for f in squid.conf mime.conf msntauth.conf; do - cmp -s -z ${f} ${f}.default && rm ${f} - done - ;; -POST-DEINSTALL) - rmdir ${PKG_PREFIX}/etc/squid 2>/dev/null - rmdir ${PKG_PREFIX}/squid/cache 2>/dev/null - rmdir ${PKG_PREFIX}/squid/logs 2>/dev/null - rmdir ${PKG_PREFIX}/squid 2>/dev/null - echo "===> post-deinstallation information for $1" - echo "" - echo " Please note that $1 was not completely removed" - echo " from this system." - echo "" - echo " The cache and log directories, squid's user account," - echo " and any modified configuration files have been preserved" - echo " in case you want to install an updated version of squid" - echo " on this system. You must remove them manually if you do" - echo " not want to use squid any longer." - echo "" - ;; -*) - exit 64 - ;; -esac -exit 0 diff --git a/www/squid27/pkg-descr b/www/squid27/pkg-descr deleted file mode 100644 index 46543b891846..000000000000 --- a/www/squid27/pkg-descr +++ /dev/null @@ -1,15 +0,0 @@ -This is the Squid Internet Object Cache developed by the National -Laboratory for Applied Networking Research (NLANR) and Internet -volunteers. This software is freely available for anyone to use. - -This software is based on the Harvest Object Cache developed by -the University of Colorado and the University of Southern California. -The Harvest home page is http://harvest.cs.colorado.edu/. - -ARPA funding for the Harvest project has ended, the squid project has -continued development of the cache where Harvest finished. - -Please see this port's Makefile for a list of compilation options. - -You can find further information on the project's website at -WWW: http://www.squid-cache.org/ diff --git a/www/squid27/pkg-install b/www/squid27/pkg-install deleted file mode 100644 index 16e9aada1108..000000000000 --- a/www/squid27/pkg-install +++ /dev/null @@ -1,164 +0,0 @@ -#!/bin/sh -# -# $FreeBSD$ -# - -PATH=/bin:/usr/bin:/usr/sbin -pkgname=$1 -squid_base=${PKG_PREFIX:-/usr/local}/squid -squid_confdir=${PKG_PREFIX:-/usr/local}/etc/squid -if [ -x /usr/sbin/nologin ]; then - nologin=/usr/sbin/nologin -else - nologin=/sbin/nologin -fi -squid_user=${squid_user:-squid} -squid_group=${squid_group:-squid} -squid_gid=100 -squid_uid=100 -# Try to catch the case where the $squid_user might have been created with an -# id greater than or equal 3128. The valid exception is "nobody". -nobody_uid=65534 -nobody_gid=65534 -squid_oldgid=3128 -squid_olduid=3128 -unset wrong_id -case $2 in -PRE-INSTALL) - echo "===> Pre-installation configuration for ${pkgname}" - if ! pw groupshow ${squid_group} -q >/dev/null ; then - echo "There is no group '${squid_group}' on this system, so I will try to create it:" - if ! pw groupadd ${squid_group} -g ${squid_gid} -q ; then - echo "Failed to create group \"${squid_group}\"!" >&2 - echo "Please create it manually." >&2 - exit 1 - else - echo "Group '${squid_group}' created successfully:" - fi - else - echo "I will use the existing group '${squid_group}':" - current_gid=`pw groupshow ${squid_group}|cut -f 3 -d :` - if [ ${current_gid} -ge ${squid_oldgid} \ - -a ${current_gid} -ne ${nobody_gid} ]; then - wrong_id=1 - fi - fi - pw groupshow ${squid_group} - - if ! pw usershow ${squid_user} -q >/dev/null ; then - echo "There is no account '${squid_user}' on this system, so I will try to create it:" - if ! pw useradd -q -n ${squid_user} \ - -u ${squid_uid} -g ${squid_group} \ - -c "squid caching-proxy pseudo user" \ - -d "${squid_base}" -s "${nologin}" \ - -h - ; then - echo "Failed to create user '${squid_user}'!" >&2 - echo "Please create it manually." >&2 - exit 1 - else - echo "User '${squid_user}' created successfully:" - fi - else - echo "I will use the existing user '${squid_user}':" - current_uid=`id -u ${squid_user}` - if [ ${current_uid} -ge ${squid_olduid} \ - -a ${current_uid} -ne ${nobody_uid} ]; - then - wrong_id=1 - fi - fi - pw usershow ${squid_user} - if [ "${wrong_id}" ]; then - echo "" - echo " * NOTICE *" - echo "" - echo "The squid pseudo-user's uid and/or gid have been found" - echo "to be greater than or equal 3128." - echo "" - echo "This is not a problem as such, but violates the FreeBSD" - echo "ports' principle that a ports must not claim a uid greater" - echo "than 999." - echo "" - echo "Since version 2.5.4_11, the squid user is thus created" - echo "with an id of ${squid_uid}:${squid_gid} while earlier versions of this" - echo "port used the first unused uid/gid greater than or" - echo "equal 3128." - echo "" - echo "If you want to change the existing squid user's id, run" - echo "'make changeuser' after the installation has completed." - echo "If you installed this port via a package, issue the" - echo "following commands as root:" - echo "" - echo "pw userdel -u ${current_uid}" - echo "pw groupadd -n ${squid_group} -g ${squid_gid}" - echo "pw useradd -n ${squid_user} -u ${squid_uid} \\" - echo " -c \"squid caching-proxy pseudo user\" \\" - echo " -g ${squid_group} -d ${squid_base} -s /sbin/nologin \\" - echo " -h -" - echo "find -H ${PKG_PREFIX} -user ${current_uid} -exec chown ${squid_user} {} \\;" - echo "find -H ${PKG_PREFIX} -group ${current_gid} -exec chgrp ${squid_group} {} \\;" - echo "" - echo "In case you have installed third party software for squid" - echo "like squidGuard, you should additionally run:" - echo "find -H /var -user ${current_uid} -exec chown ${squid_user} {} \\;" - echo "find -H /var -group ${current_gid} -exec chgrp ${squid_group} {} \\;" - echo "" - if [ -z "${PACKAGE_BUILDING}" -a -z "${BATCH}" ]; then - sleep 30 - fi - fi - for dir in cache logs; do - if [ ! -d ${squid_base}/${dir} ]; then - echo "Creating ${squid_base}/${dir}..." - install -d -o ${squid_user} -g ${squid_group} \ - -m 0750 ${squid_base}/${dir} - fi - done - if [ ! -d ${squid_confdir} ]; then - echo "Creating ${squid_confdir}..." - install -d -o root -g ${squid_group} \ - -m 0750 ${squid_confdir} - fi - ;; -POST-INSTALL) - for file in mime.conf squid.conf; do - if [ ! -f ${squid_confdir}/${file} \ - -a -f ${squid_confdir}/${file}.default ]; then - echo "Creating ${file} from default..." - install -c -o root -g ${squid_group} -m 0640 \ - ${squid_confdir}/${file}.default ${squid_confdir}/${file} - fi - done - - echo "===> Post-installation informations for ${pkgname}" - echo "" - echo " o You can find the configuration files for this package" - echo " in the directory ${squid_confdir}." - echo "" - echo " o A cache directory has been created in ${squid_base}/cache." - echo " Log files will be written to ${squid_base}/logs." - echo "" - echo " o The default configuration will deny everyone access to the" - echo " proxy service. Edit the \"http_access\" directives in" - echo " ${squid_confdir}/squid.conf to suit your needs." - echo "" - echo " o If you never ran squid on this system before, you need to" - echo " initialize the cache directory by running \"squid -z\"" - echo " as 'root' or '${squid_user}' before starting squid." - echo "" - echo " Please note that ${PKG_PREFIX}/etc/rc.d/squid.sh" - echo " will not start squid automatically anymore unless you" - echo " explicitly configured the port not to install an rcNG" - echo " style startup script via 'make config'." - echo "" - echo " To enable squid, set squid_enable=yes in either" - echo " /etc/rc.conf, /etc/rc.conf.local or /etc/rc.conf.d/squid" - echo " See ${PKG_PREFIX}/etc/rc.d/squid.sh for more" - echo " configuration options." - echo "" - ;; -*) - exit 64 - ;; -esac -exit 0 |