diff options
author | mjl <mjl> | 2009-04-07 00:21:46 +0000 |
---|---|---|
committer | mjl <mjl> | 2009-04-07 00:21:46 +0000 |
commit | 29d587bf47a3577c6a1568edf1383eb89c7ae219 (patch) | |
tree | 37da12db0aad716dced5c9a3c6dea5aecd070992 /www | |
parent | 72d949da952e1ea3f25c1568222d03af245eb637 (diff) | |
download | pkgsrc-29d587bf47a3577c6a1568edf1383eb89c7ae219.tar.gz |
Update privoxy to 3.0.12
This is a stable release which includes many enhancements but no major
new features. The most prominent improvement is support for keep-alive
connections.
Also add a patch to deal with non-availability of gethostbyname_r()
on NetBSD -- privoxy then uses gethostbyname() in a mutexed section,
effectively single threading DNS lookup. This is extremely annoying when
running into DNS timeouts. Hack around it by implementing functionality
using getaddrinfo().
Diffstat (limited to 'www')
-rw-r--r-- | www/privoxy/Makefile | 8 | ||||
-rw-r--r-- | www/privoxy/PLIST | 5 | ||||
-rw-r--r-- | www/privoxy/distinfo | 10 | ||||
-rw-r--r-- | www/privoxy/patches/patch-af | 22 | ||||
-rw-r--r-- | www/privoxy/patches/patch-ag | 59 |
5 files changed, 71 insertions, 33 deletions
diff --git a/www/privoxy/Makefile b/www/privoxy/Makefile index 7ba0e0327f1..d0a210c8bc8 100644 --- a/www/privoxy/Makefile +++ b/www/privoxy/Makefile @@ -1,12 +1,12 @@ -# $NetBSD: Makefile,v 1.37 2009/02/04 21:30:53 drochner Exp $ +# $NetBSD: Makefile,v 1.38 2009/04/07 00:21:46 mjl Exp $ # DISTNAME= ${PKGNAME_NOREV}-stable-src -PKGNAME= privoxy-3.0.10 +PKGNAME= privoxy-3.0.12 CATEGORIES= www MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=ijbswa/} -MAINTAINER= kim@tac.nyc.ny.us +MAINTAINER= pkgsrc-users@NetBSD.org HOMEPAGE= http://www.privoxy.org/ COMMENT= Web proxy with advanced filtering capabilities @@ -47,7 +47,7 @@ CONFIGURE_ARGS+= --with-group=${PRIVOXY_GROUP:Q} USER_GROUP= ${PRIVOXY_USER} ${PRIVOXY_GROUP} .for i in \ - config trust default.action standard.action user.action default.filter + config trust default.action user.action default.filter match-all.action CONF_FILES_PERMS+= ${EGDIR}/${i} ${PKG_SYSCONFDIR}/${i} ${USER_GROUP} 0660 .endfor diff --git a/www/privoxy/PLIST b/www/privoxy/PLIST index 3150082b8fc..3aa6240d0a2 100644 --- a/www/privoxy/PLIST +++ b/www/privoxy/PLIST @@ -1,4 +1,4 @@ -@comment $NetBSD: PLIST,v 1.6 2009/02/04 21:30:53 drochner Exp $ +@comment $NetBSD: PLIST,v 1.7 2009/04/07 00:21:46 mjl Exp $ man/man1/privoxy.1 sbin/privoxy share/doc/privoxy/AUTHORS @@ -48,10 +48,11 @@ share/doc/privoxy/user-manual/startup.html share/doc/privoxy/user-manual/templates.html share/doc/privoxy/user-manual/upgradersnote.html share/doc/privoxy/user-manual/whatsnew.html +share/examples/privoxy/templates/url-info-osd.xml share/examples/privoxy/config share/examples/privoxy/default.action share/examples/privoxy/default.filter -share/examples/privoxy/standard.action +share/examples/privoxy/match-all.action share/examples/privoxy/templates/blocked share/examples/privoxy/templates/cgi-error-404 share/examples/privoxy/templates/cgi-error-bad-param diff --git a/www/privoxy/distinfo b/www/privoxy/distinfo index 330cb06cf86..535ab4fbdef 100644 --- a/www/privoxy/distinfo +++ b/www/privoxy/distinfo @@ -1,8 +1,8 @@ -$NetBSD: distinfo,v 1.11 2009/02/11 17:59:32 drochner Exp $ +$NetBSD: distinfo,v 1.12 2009/04/07 00:21:46 mjl Exp $ -SHA1 (privoxy-3.0.10-stable-src.tar.gz) = 0ce51a8dc938fe6412daa7f6edf159b98fd66d54 -RMD160 (privoxy-3.0.10-stable-src.tar.gz) = 91c8d56b71a5c606554bf509827197d689d8fc10 -Size (privoxy-3.0.10-stable-src.tar.gz) = 1957465 bytes +SHA1 (privoxy-3.0.12-stable-src.tar.gz) = 1118d6a7b4980f26c9ad0902c0e6af5aaaf1a640 +RMD160 (privoxy-3.0.12-stable-src.tar.gz) = 32509b897e073f1cc100b8a4a157d19a219b51cd +Size (privoxy-3.0.12-stable-src.tar.gz) = 1811124 bytes SHA1 (patch-aa) = c263d2a4b9522a33613f82ab2bc18d5c2b554b21 SHA1 (patch-ac) = e39ffe694462b952c5ad66ac577a0acbee0a1d9f -SHA1 (patch-af) = cb4249abd1c2f4f5d256ab4c3b56d04213ee820f +SHA1 (patch-ag) = 9ec6d971382f145d11c5f6e0d13381fdfe3cd31f diff --git a/www/privoxy/patches/patch-af b/www/privoxy/patches/patch-af deleted file mode 100644 index a3ad2ef59cb..00000000000 --- a/www/privoxy/patches/patch-af +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-af,v 1.2 2009/02/11 17:59:32 drochner Exp $ - ---- ./jcc.c.orig 2008-06-27 13:13:56.000000000 +0200 -+++ ./jcc.c -@@ -3349,6 +3349,17 @@ int main(int argc, const char *argv[]) - { - log_error(LOG_LEVEL_FATAL, "Cannot setgid(): Insufficient permissions."); - } -+ if (NULL != grp) -+ { -+ if (setgroups(1, &grp->gr_gid)) -+ { -+ log_error(LOG_LEVEL_FATAL, "setgroups() failed: %E"); -+ } -+ } -+ else if (initgroups(pw->pw_name, pw->pw_gid)) -+ { -+ log_error(LOG_LEVEL_FATAL, "initgroups() failed: %E"); -+ } - if (do_chroot) - { - if (!pw->pw_dir) diff --git a/www/privoxy/patches/patch-ag b/www/privoxy/patches/patch-ag new file mode 100644 index 00000000000..363813deab8 --- /dev/null +++ b/www/privoxy/patches/patch-ag @@ -0,0 +1,59 @@ +$NetBSD: patch-ag,v 1.1 2009/04/07 00:21:47 mjl Exp $ + +--- jbsockets.c.orig 2009-03-31 14:08:54.000000000 +0200 ++++ jbsockets.c 2009-03-31 14:36:35.000000000 +0200 +@@ -945,6 +945,14 @@ + struct sockaddr_in inaddr; + struct hostent *hostp; + unsigned int dns_retries = 0; ++#if defined(__NetBSD__) ++ struct hostent result; ++ struct sockaddr_in raddr; ++ struct sockaddr_in *rlist[2]; ++ ++ memset(&result, '\0', sizeof(struct hostent)); ++#endif ++ + #if defined(HAVE_GETHOSTBYNAME_R_6_ARGS) || defined(HAVE_GETHOSTBYNAME_R_5_ARGS) || defined(HAVE_GETHOSTBYNAME_R_3_ARGS) + struct hostent result; + #if defined(HAVE_GETHOSTBYNAME_R_6_ARGS) || defined(HAVE_GETHOSTBYNAME_R_5_ARGS) +@@ -995,7 +1003,39 @@ + { + hostp = NULL; + } ++#elif defined(__NetBSD__) ++ /* mjl */ ++ { ++ struct addrinfo *resp = NULL; ++ struct addrinfo hints; ++ ++ memset(&hints, '\0', sizeof(struct addrinfo)); ++ hints.ai_family = AF_INET; ++ ++ while (getaddrinfo(host, NULL, &hints, &resp) == EAI_AGAIN ++ && (dns_retries++ < MAX_DNS_RETRIES)) ++ { ++ log_error(LOG_LEVEL_ERROR, ++ "Timeout #%u while trying to resolve %s. Trying again.", ++ dns_retries, host); ++ } ++ ++ if(resp) ++ { ++ result.h_addrtype = resp->ai_family; ++ memcpy(&raddr, &((struct sockaddr_in *) resp->ai_addr) ++ ->sin_addr, sizeof(struct sockaddr_in)); ++ /* set up fake hostent */ ++ rlist[0] = &raddr; ++ rlist[1] = NULL; ++ result.h_addr_list = (char **)rlist; ++ hostp = &result; ++ ++ freeaddrinfo(resp); ++ } ++ } ++ + #elif FEATURE_PTHREAD + privoxy_mutex_lock(&resolver_mutex); + while (NULL == (hostp = gethostbyname(host)) + && (h_errno == TRY_AGAIN) && (dns_retries++ < MAX_DNS_RETRIES)) |