diff options
author | adam <adam@pkgsrc.org> | 2018-06-24 16:54:59 +0000 |
---|---|---|
committer | adam <adam@pkgsrc.org> | 2018-06-24 16:54:59 +0000 |
commit | d5d08136056f3c2ecd1857a7229d9e2c8db22b10 (patch) | |
tree | bba5c74399bc53ff5ea37852468cc9cefcd136ec /www | |
parent | b03700f0922f0b0bb56ab7fb029dadfe29de2720 (diff) | |
download | pkgsrc-d5d08136056f3c2ecd1857a7229d9e2c8db22b10.tar.gz |
libwww: updated to 5.4.2
5.4.2:
Unknown changes.
Changes with libwww 5.4.1
* Removed the expat source code in favor of linking against
the global system expat library to avoid having to track
security advisories in that library
* Updated expat to 2.2.0
* Updated autotools to the current versions
* Library/src/HTSQL.c: add missing mysql_init to HTSQL_connect reported by Xavier Torne
* configure.ac, Library/src/Makefile.am, Library/cvs2sql/Makefile.am,
Robot/src/Makefile.am:
modify configure scripts for mysql_config based autoconf processing
* Library/src/HTSQL.c, Library/src/HTSQL.html, Library/src/HTSQLLog.c: remove
mysql directory from include directiv
* Robot/src/RobotMain.c: added flag MR_KEEP_META for -lm last modified option
detected by Jan Hutaø
* Robot/src/RobotMain.c: added flag MR_KEEP_META for -title option
detected by Jan Hutaø
* close leak in HTBound process_boundary() detected by Sam Varshavchik
using valgrind; excised old #if 0 snippets from HTMIME.c
* Library/src/HTCookie.c: add private function HTCookie_splitPair to
split a KEY=VALUE pair, from Jesse Morgan
* configure.ac: remove unecessary check for appkit.h as
suggested by Roger Persson
* Library/src/wwwsys.html: change genuine angle bracket characters
into the angle bracket entities, thanks to Bobby Jack
* Library/src/HT*.html, Library/src/SSL/HT*.html: wrap
all header files with extern "C"
* Library/src/HTFile, configure.ac: add a basis for
addressing Ben's security concerns
* Library/src/HTBound.c: libwww security advisory fix from
Sam Varshavchik, fix double-counting of processed bytes,
rewrote HTBoundary_put_block, to fix problematic HTTP 1.1
byte range requests
* Library/src/: HTAlert.c, HTHeader.c, HTInit.c, HTNet.c,
HTProfil.c, HTProt.c, HTTrans.c: Patch to greatly speed up
repeated requests, from Arthur Smith
* Library/src/HTSQL.c: modifications to compile without using
deprecated mysql functions
* config/: config.sub, ltmain.sh: updates for recent version of
libtool
* INSTALL.html, Library/src/HTEvtLst.c: cleaning
* libwww-config.in: include -lwwwssl, thanks to mgoddard at
itgs-presearch.com
* Library/src/SSL/HTSSLWriter.c: avoids an eternal loop in libwww
* Library/src/SSL/HTSSL.html, Robot/src/RobotMain.c: fix for webbot
-v option check and documentation addition
* configure.ac, Library/src/SSL/HTSSL.c,
Library/src/SSL/windows/wwwssl.def, Robot/src/HTRobMan.html,
Robot/src/Makefile.am, Robot/src/RobotMain.c: basic support for
client side certificates using PEM format
* Library/src/SSL/: HTSSL.c, HTSSLReader.c, HTSSLWriter.c: add
openssl to include for ssl.h and rand.h
* config/: config.guess, config.sub, ltmain.sh: update after
running libtoolize
* Robot/src/Makefile.am: use SSL directory for libwwwssl.la
* Robot/src/RobotMain.c: include HTSSL.h
* configure.ac: fix aclocal underquoting warnings
* Robot/src/: RobotMain.c, Makefile.am: update to enable https
protocol
* Library/src/HTTPReq.c: fixed , to _ in HTTRACE call
* Library/src/HTTPReq.c: removed LIBWWW_USEIDN, because unnecessary
* modules/idn/unicode_template.c: forgot one file
* Library/src/HTDNS.html: moved IDN to main branch
* Library/src/HTDNS.c: moved IDN to main branch
* Library/src/HTTPReq.c: added "LIBWWW_USEIDN" conditional
* Library/src/HTTPReq.c: moved IDN to main branch
* Library/Overview.html: JK: Added the libwww survey results
Diffstat (limited to 'www')
25 files changed, 154 insertions, 1006 deletions
diff --git a/www/libwww/Makefile b/www/libwww/Makefile index 94d4dcff9a4..8980430c48d 100644 --- a/www/libwww/Makefile +++ b/www/libwww/Makefile @@ -1,38 +1,23 @@ -# $NetBSD: Makefile,v 1.91 2016/07/09 06:39:13 wiz Exp $ +# $NetBSD: Makefile,v 1.92 2018/06/24 16:54:59 adam Exp $ -DISTNAME= w3c-libwww-5.4.0 -PKGNAME= libwww-5.4.0 -PKGREVISION= 17 -CATEGORIES= www devel -MASTER_SITES= http://www.w3.org/Library/Distribution/ -EXTRACT_SUFX= .tgz -DISTFILES= ${DISTNAME}${EXTRACT_SUFX} libwww-configure-5.4.0nb2.gz +DISTNAME= w3c-libwww-5.4.2 +PKGNAME= ${DISTNAME:S/^w3c-//} +CATEGORIES= www devel +MASTER_SITES= http://www.w3.org/Library/Distribution/ +EXTRACT_SUFX= .tgz -MAINTAINER= pkgsrc-users@NetBSD.org -HOMEPAGE= http://www.w3.org/Library/ -COMMENT= The W3C Reference Library - -EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX} -SITES.libwww-configure-5.4.0nb2.gz= ${MASTER_SITE_LOCAL} +MAINTAINER= pkgsrc-users@NetBSD.org +HOMEPAGE= http://www.w3.org/Library/ +COMMENT= The W3C Reference Library +LICENSE= w3c +USE_LIBTOOL= yes USE_TOOLS+= automake14 gmake gzcat perl -USE_LIBTOOL= YES - -GNU_CONFIGURE= YES -CONFIGURE_ARGS+= --with-zlib --without-x -CONFIGURE_ARGS+= --with-ssl=${SSLBASE:Q} - -.include "options.mk" - -post-extract: - gzcat ${DISTDIR}/libwww-configure-5.4.0nb2.gz > ${WRKSRC}/configure - -pre-configure: - chmod a+x ${WRKSRC}/configure -.for f in aclocal.m4 configure stamp-h.in - touch ${WRKSRC}/${f} -.endfor - cd ${WRKSRC} && automake +GNU_CONFIGURE= yes +CONFIGURE_ARGS+= --with-expat=${BUILDLINK_PREFIX.expat} +CONFIGURE_ARGS+= --with-ssl #=${SSLBASE:Q} +CONFIGURE_ARGS+= --with-zlib +CONFIGURE_ARGS+= --without-x .include "../../mk/bsd.prefs.mk" @@ -53,7 +38,9 @@ CONFIGURE_ARGS+= --with-md5=${SSLBASE:Q} . endif .endif +.include "options.mk" + .include "../../devel/zlib/buildlink3.mk" .include "../../security/openssl/buildlink3.mk" - +.include "../../textproc/expat/buildlink3.mk" .include "../../mk/bsd.pkg.mk" diff --git a/www/libwww/PLIST b/www/libwww/PLIST index 91f9194d05b..554a9ff751f 100644 --- a/www/libwww/PLIST +++ b/www/libwww/PLIST @@ -1,4 +1,4 @@ -@comment $NetBSD: PLIST,v 1.7 2009/06/14 22:00:25 joerg Exp $ +@comment $NetBSD: PLIST,v 1.8 2018/06/24 16:54:59 adam Exp $ bin/libwww-config bin/w3c bin/webbot @@ -161,7 +161,6 @@ include/w3c-libwww/WWWWAIS.h include/w3c-libwww/WWWXML.h include/w3c-libwww/WWWZip.h include/w3c-libwww/wwwsys.h -include/w3c-libwww/xmlparse.h include/wwwconf.h ${PLIST.md5}lib/libmd5.la lib/libpics.la @@ -185,8 +184,6 @@ lib/libwwwtrans.la lib/libwwwutils.la lib/libwwwxml.la lib/libwwwzip.la -lib/libxmlparse.la -lib/libxmltok.la share/w3c-libwww/back.xbm share/w3c-libwww/binary.xbm share/w3c-libwww/binhex.xbm diff --git a/www/libwww/distinfo b/www/libwww/distinfo index f22bd06fd3c..5d290a1908d 100644 --- a/www/libwww/distinfo +++ b/www/libwww/distinfo @@ -1,27 +1,13 @@ -$NetBSD: distinfo,v 1.27 2015/11/04 02:46:57 agc Exp $ +$NetBSD: distinfo,v 1.28 2018/06/24 16:54:59 adam Exp $ -SHA1 (libwww-configure-5.4.0nb2.gz) = de3292e2ec4034485b300845e7a0c0ef4ceb0199 -RMD160 (libwww-configure-5.4.0nb2.gz) = bead5840a43b85e7de79e1bf5e26fa997cf827e3 -SHA512 (libwww-configure-5.4.0nb2.gz) = 37609c70925c99cde5ab1b6a6d5051b701cb21cc813d7c05de3d10480492cd56963700b4c92f30789a143a4b906e72005c0f9c2e9463b913cc6d0afa6dcb671e -Size (libwww-configure-5.4.0nb2.gz) = 155806 bytes -SHA1 (w3c-libwww-5.4.0.tgz) = 2394cb4e0dc4e2313a9a0ddbf508e4b726e9af63 -RMD160 (w3c-libwww-5.4.0.tgz) = 12e55ecb2435f9048d627e56f8ae60d4c246648b -SHA512 (w3c-libwww-5.4.0.tgz) = edc87430ca3061e7ea0a9d216a29eec8889c36d4dde59262d0751aea842f1682f1ae8a89bbcb0092d7e298643660ed1c7f9bec007fed8b1f84f3e6eb7e97c24b -Size (w3c-libwww-5.4.0.tgz) = 1129121 bytes -SHA1 (patch-aa) = fc0124c8995992536782e60ce67332c2dc505b10 -SHA1 (patch-ab) = 24db9ca337bd6768fa5b208186f7b55e555beb8f -SHA1 (patch-ac) = d3b153c4360d5eb0439a9d328d259896937902df -SHA1 (patch-ad) = b3c9eaf2e9eabe2ab68b8858f6f9dbe65d650ae4 -SHA1 (patch-ae) = 4130a9a20d806553a79e04c79d652b76ec1dce34 -SHA1 (patch-af) = ce044829940b51037ff37f717dbf92e96504a391 -SHA1 (patch-ai) = 95912fb5b836e4dce01b630f9e6e9c9f41d7bb72 -SHA1 (patch-aj) = 6148ae393aefcce54477b289835038b01a26a0ed -SHA1 (patch-ak) = fb13a43105ee252a461d20b67d5841db6d247dde -SHA1 (patch-al) = dae1e731f7a9ff36ef1f60f2a4a6cc97e359ae63 -SHA1 (patch-am) = 8252ce567efc056daa10af39eeca314f9a915f90 -SHA1 (patch-an) = e7195c25ce08e13e0c8b64b05b737e9a5f5157a8 -SHA1 (patch-ao) = b5489ae73d347c9a4e32a66344e12236e2023520 -SHA1 (patch-ap) = 506ee8ddd2e627aa6ba84b933ca39a6934b95689 -SHA1 (patch-aq) = f44086c50dfe3d5af714b6defcb40ac7a1ed36f1 -SHA1 (patch-ar) = ddbe9f7e7add849dcbdf215d0087bb3e314100c3 -SHA1 (patch-as) = cb88580f74998491eb822227af225055b0eeacee +SHA1 (w3c-libwww-5.4.2.tgz) = 6bc3c0de4cd2e0d51b17789c9a86b5296ce44b2f +RMD160 (w3c-libwww-5.4.2.tgz) = 7b6ecfbd84ca8b2ce3b19d3b60e9f6a75ea914f5 +SHA512 (w3c-libwww-5.4.2.tgz) = d0dbe2be106c4987a5131c22c300bd3fcb1dce1881d0009269dd4e3c8068da1c07e2b1ca4bfd181640f8b467d4a378a9036f9b385d3a28badbe22b2ed74e0e74 +Size (w3c-libwww-5.4.2.tgz) = 2630357 bytes +SHA1 (patch-Library_Makefile.in) = f0ea0413c13501cfa7d038ebfe602d6bdbf02de4 +SHA1 (patch-Library_src_HTMIMImp.c) = 2f14df9867758c69f9e6110b16f75d017e032a8e +SHA1 (patch-Library_src_HTStyle.c) = 2c42a00ce5ed0ff0f34e779582684805e47edce2 +SHA1 (patch-Library_src_SSL_HTSSL.c) = c170125b96ff3fc57e7b193b123b104ab45cb8c8 +SHA1 (patch-Library_src_wwwsys.h) = 25f39cf5afb6e4a2879a0f38129d8a450a863e72 +SHA1 (patch-configure) = 70a7d08b59361bb64069bb27cabfbc6dc2c47ec4 +SHA1 (patch-libwww-config.in) = 438821b7979712cf87781c38c930ab8e24ea1aad diff --git a/www/libwww/options.mk b/www/libwww/options.mk index 2c3d50fe6f3..f37e5e3f4ae 100644 --- a/www/libwww/options.mk +++ b/www/libwww/options.mk @@ -1,6 +1,6 @@ -# $NetBSD: options.mk,v 1.3 2015/09/30 08:25:37 tnn Exp $ +# $NetBSD: options.mk,v 1.4 2018/06/24 16:54:59 adam Exp $ -PKG_OPTIONS_VAR= PKG_OPTIONS.libwww +PKG_OPTIONS_VAR= PKG_OPTIONS.libwww PKG_OPTIONS_OPTIONAL_GROUPS+= socks PKG_OPTIONS_GROUP.socks= socks4 dante diff --git a/www/libwww/patches/patch-Library_Makefile.in b/www/libwww/patches/patch-Library_Makefile.in new file mode 100644 index 00000000000..2c0f253ac2c --- /dev/null +++ b/www/libwww/patches/patch-Library_Makefile.in @@ -0,0 +1,15 @@ +$NetBSD: patch-Library_Makefile.in,v 1.1 2018/06/24 16:54:59 adam Exp $ + +Build only necessary stuff. + +--- Library/Makefile.in.orig 2018-06-20 16:07:11.000000000 +0000 ++++ Library/Makefile.in +@@ -352,7 +352,7 @@ DOCS := $(wildcard *.html *.gif) + EXTRA_DIST = \ + $(DOCS) + +-SUBDIRS = src User Examples External cvs2sql # Test ++SUBDIRS = src User # Examples External cvs2sql # Test + all: all-recursive + + .SUFFIXES: diff --git a/www/libwww/patches/patch-ab b/www/libwww/patches/patch-Library_src_HTMIMImp.c index c8d76796686..7fde3a9515c 100644 --- a/www/libwww/patches/patch-ab +++ b/www/libwww/patches/patch-Library_src_HTMIMImp.c @@ -1,4 +1,6 @@ -$NetBSD: patch-ab,v 1.9 2001/04/20 12:33:53 fredb Exp $ +$NetBSD: patch-Library_src_HTMIMImp.c,v 1.1 2018/06/24 16:54:59 adam Exp $ + +Fix buidling. --- Library/src/HTMIMImp.c.orig Mon Feb 22 16:10:11 1999 +++ Library/src/HTMIMImp.c diff --git a/www/libwww/patches/patch-ac b/www/libwww/patches/patch-Library_src_HTStyle.c index 1c179e7304f..ba2d44bd768 100644 --- a/www/libwww/patches/patch-ac +++ b/www/libwww/patches/patch-Library_src_HTStyle.c @@ -1,4 +1,6 @@ -$NetBSD: patch-ac,v 1.7 2001/04/20 12:33:53 fredb Exp $ +$NetBSD: patch-Library_src_HTStyle.c,v 1.1 2018/06/24 16:54:59 adam Exp $ + +Define application-wide style sheet. --- Library/src/HTStyle.c.orig Mon Feb 22 16:10:12 1999 +++ Library/src/HTStyle.c @@ -6,7 +8,7 @@ $NetBSD: patch-ac,v 1.7 2001/04/20 12:33:53 fredb Exp $ #include "WWWUtil.h" #include "HTStyle.h" -+PUBLIC HTStyleSheet * styleSheet; /* application-wide style sheet */ ++PUBLIC HTStyleSheet * styleSheet; + struct _HTStyle { char * name; /* Style name */ diff --git a/www/libwww/patches/patch-Library_src_SSL_HTSSL.c b/www/libwww/patches/patch-Library_src_SSL_HTSSL.c new file mode 100644 index 00000000000..14313c0a566 --- /dev/null +++ b/www/libwww/patches/patch-Library_src_SSL_HTSSL.c @@ -0,0 +1,56 @@ +$NetBSD: patch-Library_src_SSL_HTSSL.c,v 1.1 2018/06/24 16:54:59 adam Exp $ + +Fix for OpenSSL 1.1.x. + +--- Library/src/SSL/HTSSL.c.orig 2018-06-24 13:38:32.023842509 +0000 ++++ Library/src/SSL/HTSSL.c +@@ -98,6 +98,7 @@ PRIVATE void apps_ssl_info_callback (SSL + PRIVATE int verify_callback (int ok, X509_STORE_CTX * ctx) + { + char buf[256]; ++ int ctx_error; + X509 * err_cert = X509_STORE_CTX_get_current_cert(ctx); + int err = X509_STORE_CTX_get_error(ctx); + int depth = X509_STORE_CTX_get_error_depth(ctx); +@@ -115,24 +116,24 @@ PRIVATE int verify_callback (int ok, X50 + verify_error=X509_V_ERR_CERT_CHAIN_TOO_LONG; + } + } +- switch (ctx->error) { ++ switch (ctx_error = X509_STORE_CTX_get_error(ctx)) { + + case X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT: +- X509_NAME_oneline(X509_get_issuer_name(ctx->current_cert), buf, 256); ++ X509_NAME_oneline(X509_get_issuer_name(X509_STORE_CTX_get0_cert(ctx)), buf, 256); + HTTRACE(PROT_TRACE, "issuer= %s\n" _ buf); + break; + + case X509_V_ERR_CERT_NOT_YET_VALID: + case X509_V_ERR_ERROR_IN_CERT_NOT_BEFORE_FIELD: + HTTRACE(PROT_TRACE, "notBefore="); +-// ASN1_TIME_print(bio_err,X509_get_notBefore(ctx->current_cert)); ++// ASN1_TIME_print(bio_err,X509_get_notBefore(X509_STORE_CTX_get0_cert(ctx))); + HTTRACE(PROT_TRACE, "\n"); + break; + + case X509_V_ERR_CERT_HAS_EXPIRED: + case X509_V_ERR_ERROR_IN_CERT_NOT_AFTER_FIELD: + HTTRACE(PROT_TRACE, "notAfter="); +-// ASN1_TIME_print(bio_err,X509_get_notAfter(ctx->current_cert)); ++// ASN1_TIME_print(bio_err,X509_get_notAfter(X509_STORE_CTX_get0_cert(ctx))); + HTTRACE(PROT_TRACE, "\n"); + break; + } +@@ -214,12 +215,6 @@ PUBLIC BOOL HTSSL_init (void) + + /* select the protocol method */ + switch (ssl_prot_method) { +- case HTSSL_V2: +- meth = SSLv2_client_method(); +- break; +- case HTSSL_V3: +- meth = SSLv3_client_method(); +- break; + case HTSSL_V23: + meth = SSLv23_client_method(); + break; diff --git a/www/libwww/patches/patch-af b/www/libwww/patches/patch-Library_src_wwwsys.h index 2e3459cbf6d..e6759d2780d 100644 --- a/www/libwww/patches/patch-af +++ b/www/libwww/patches/patch-Library_src_wwwsys.h @@ -1,4 +1,6 @@ -$NetBSD: patch-af,v 1.3 2005/05/31 20:51:46 salo Exp $ +$NetBSD: patch-Library_src_wwwsys.h,v 1.1 2018/06/24 16:54:59 adam Exp $ + +Fix building. --- Library/src/wwwsys.h.orig Wed Dec 20 05:00:07 2000 +++ Library/src/wwwsys.h diff --git a/www/libwww/patches/patch-aa b/www/libwww/patches/patch-aa deleted file mode 100644 index e170e72f251..00000000000 --- a/www/libwww/patches/patch-aa +++ /dev/null @@ -1,11 +0,0 @@ -$NetBSD: patch-aa,v 1.4 2001/04/20 12:33:53 fredb Exp $ - ---- Library/Makefile.am.orig Wed Aug 5 20:54:52 1998 -+++ Library/Makefile.am -@@ -5,5 +5,5 @@ - EXTRA_DIST = \ - $(DOCS) - --SUBDIRS = src User Examples External cvs2sql # Test -+SUBDIRS = src User # Examples External cvs2sql Test - diff --git a/www/libwww/patches/patch-ad b/www/libwww/patches/patch-ad deleted file mode 100644 index 32e7f7ce1ef..00000000000 --- a/www/libwww/patches/patch-ad +++ /dev/null @@ -1,58 +0,0 @@ -$NetBSD: patch-ad,v 1.6 2013/07/05 21:06:02 joerg Exp $ - ---- Library/src/Makefile.am.orig 2002-05-29 16:09:13.000000000 +0000 -+++ Library/src/Makefile.am -@@ -1,6 +1,6 @@ - ## Process this file with Automake to create Makefile.in. - --LDFLAGS = -version-info "1:0:1" -+LDFLAGS = @LDFLAGS@ -version-info "1:0:1" - - lib_LTLIBRARIES = \ - libwwwutils.la \ -@@ -253,7 +253,7 @@ libwwwhttp_la_SOURCES = \ - HTPEP.c - - libwwwhttp_la_DEPENDENCIES = \ -- ../../modules/md5/libmd5.la -+ @LIBMD5DEP@ - - libwwwnews_la_SOURCES = \ - WWWNews.h \ -@@ -311,6 +311,13 @@ libwwwdir_la_SOURCES = \ - HTDir.h \ - HTDir.c - -+libwwwapp_la_LDFLAGS = \ -+ @WWWZIP@ \ -+ @WWWXML@ -+libwwwapp_la_DEPENDENCIES = \ -+ @WWWZIP@ \ -+ @WWWXML@ -+ - libwwwapp_la_SOURCES = \ - WWWApp.h \ - HTAccess.h \ -@@ -366,7 +373,9 @@ libwwwxml_la_DEPENDENCIES = \ - ../../modules/expat/xmltok/libxmltok.la \ - ../../modules/expat/xmlparse/libxmlparse.la - --libwwwxml_la_LDFLAGS = -rpath $(libdir) -+libwwwxml_la_LDFLAGS = -rpath $(libdir) \ -+ ../../modules/expat/xmltok/libxmltok.la \ -+ ../../modules/expat/xmlparse/libxmlparse.la - - libwwwzip_la_SOURCES = \ - WWWZip.h \ -@@ -387,9 +396,8 @@ libwwwsql_la_SOURCES = \ - libwwwsql_la_LDFLAGS = -rpath $(libdir) - - INCLUDES = \ -- -I/usr/local/include \ -- -I${top_srcdir}/modules/md5 \ -- -I${top_srcdir}/modules/expat/xmlparse -+ -I${top_srcdir}/modules/expat/xmlparse \ -+ @LIBMD5INC@ - - BUILT_SOURCES = \ - wwwsys.h \ diff --git a/www/libwww/patches/patch-ae b/www/libwww/patches/patch-ae deleted file mode 100644 index 5ff25e64f05..00000000000 --- a/www/libwww/patches/patch-ae +++ /dev/null @@ -1,19 +0,0 @@ -$NetBSD: patch-ae,v 1.4 2001/04/20 12:33:53 fredb Exp $ - ---- Library/src/SSL/Makefile.am.orig Tue Jun 20 06:01:34 2000 -+++ Library/src/SSL/Makefile.am -@@ -39,13 +39,12 @@ - HTSSLhttps.h \ - HTSSLhttps.c - --libwwwssl_la_LDFLAGS = -rpath $(libdir) -+libwwwssl_la_LDFLAGS = @SSLLIBS@ -rpath $(libdir) - - LDADD = \ - libwwwssl.la - - INCLUDES = \ -- -I/usr/local/include \ - -I${top_srcdir}/modules/md5 \ - -I${top_srcdir}/modules/expat/xmlparse \ - -I$(top_srcdir)/Library/src \ diff --git a/www/libwww/patches/patch-ai b/www/libwww/patches/patch-ai deleted file mode 100644 index 6811cc03264..00000000000 --- a/www/libwww/patches/patch-ai +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-ai,v 1.1 2001/04/20 12:33:54 fredb Exp $ - ---- libwww-config.in.orig Wed Jun 23 13:05:01 1999 -+++ libwww-config.in -@@ -48,7 +48,7 @@ - echo -I@includedir@ -I@includedir@/@PACKAGE@ @DEFS@ - ;; - --libs) -- echo -L@libdir@ @LWWWXML@ @LWWWZIP@ @LWWWWAIS@ @LWWWSQL@ -lwwwinit -lwwwapp -lwwwhtml -lwwwtelnet -lwwwnews -lwwwhttp -lwwwmime -lwwwgopher -lwwwftp -lwwwfile -lwwwdir -lwwwcache -lwwwstream -lwwwmux -lwwwtrans -lwwwcore -lwwwutils @LWWWMD5@ @LIBS@ -+ echo -L@libdir@ -Wl,-R@libdir@ @LWWWXML@ @LWWWZIP@ @LWWWWAIS@ @LWWWSQL@ -lwwwinit -lwwwapp -lwwwhtml -lwwwtelnet -lwwwnews -lwwwhttp -lwwwmime -lwwwgopher -lwwwftp -lwwwfile -lwwwdir -lwwwcache -lwwwstream -lwwwmux -lwwwtrans -lwwwcore -lwwwutils @LWWWMD5@ @LIBS@ - ;; - *) - echo "${usage}" 1>&2 diff --git a/www/libwww/patches/patch-aj b/www/libwww/patches/patch-aj deleted file mode 100644 index ccb68746dd4..00000000000 --- a/www/libwww/patches/patch-aj +++ /dev/null @@ -1,47 +0,0 @@ -$NetBSD: patch-aj,v 1.3 2002/08/25 18:40:23 jlam Exp $ ---- acinclude.m4.orig Tue Aug 28 14:56:47 2001 -+++ acinclude.m4 Tue Aug 28 14:58:27 2001 -@@ -251,19 +251,6 @@ - done - ]) - --dnl AC_C_VOLATILE --AC_DEFUN(AC_C_VOLATILE, --[ AC_MSG_CHECKING([for working volatile]) -- AC_CACHE_VAL(ac_cv_c_volatile, -- [ AC_TRY_COMPILE(,[ --extern volatile int errno; --], ac_cv_c_volatile=yes, ac_cv_c_volatile=no)])dnl -- AC_MSG_RESULT($ac_cv_c_volatile) --if test $ac_cv_c_volatile = no; then -- AC_DEFINE(volatile, ) --fi --]) -- - dnl AC_C_NOSHARE - AC_DEFUN(AC_C_NOSHARE, - [ AC_MSG_CHECKING([for working noshare]) -@@ -401,23 +388,6 @@ - if test $ac_cv_weird_accept = yes; then - AC_DEFINE(WEIRD_ACCEPT) - fi --]) -- --dnl AC_HEADER_TIOCGWINSZ --AC_DEFUN(AC_HEADER_TIOCGWINSZ, --[ AC_MSG_CHECKING([for TIOCGWINSZ get-window-size capability]) -- AC_CACHE_VAL(ac_cv_header_tiocgwinsz, -- [ AC_HEADER_INCLUDE(tmp_inc_termios, sys/termios.h termios.h) -- AC_EGREP_HEADER(yes, [ --$tmp_inc_termios --#ifdef TIOCGWINSZ -- yes --#endif --], ac_cv_header_tiocgwinsz=yes, ac_cv_header_tiocgwinsz=no)])dnl -- AC_MSG_RESULT($ac_cv_header_tiocgwinsz) --if test $ac_cv_header_tiocgwinsz = yes; then -- AC_DEFINE(GET_SCREEN_SIZE) --fi - ]) - - dnl AC_SYS_NEED_SIGNAL_RESET diff --git a/www/libwww/patches/patch-ak b/www/libwww/patches/patch-ak deleted file mode 100644 index d9e85f4aacb..00000000000 --- a/www/libwww/patches/patch-ak +++ /dev/null @@ -1,10 +0,0 @@ -$NetBSD: patch-ak,v 1.1 2002/10/26 18:11:20 bouyer Exp $ ---- modules/Makefile.am.orig Mon Oct 21 22:13:28 2002 -+++ modules/Makefile.am Mon Oct 21 22:13:45 2002 -@@ -5,5 +5,5 @@ - EXTRA_DIST = \ - $(DOCS) - --SUBDIRS = expat md5 -+SUBDIRS = expat @MD5DIR@ - diff --git a/www/libwww/patches/patch-al b/www/libwww/patches/patch-al deleted file mode 100644 index 78d40c59022..00000000000 --- a/www/libwww/patches/patch-al +++ /dev/null @@ -1,33 +0,0 @@ -$NetBSD: patch-al,v 1.3 2002/12/04 11:34:14 rearnsha Exp $ - ---- Library/User/Makefile.am.orig Thu Jun 6 16:59:37 2002 -+++ Library/User/Makefile.am -@@ -19,13 +19,20 @@ SUFFIXES = .html - DEPENDENCIES = \ - ../src/libwww.la - --Extrnals.html: -- (cd $(srcdir) && \ -- perl ../../config/makeindx.pl ../src/ ../src/WWW*.html \ -- > Extrnals.html) -+#Extrnals.html: -+# (cd $(srcdir) && \ -+# perl ../../config/makeindx.pl ../src/ ../src/WWW*.html \ -+# > Extrnals.html) -+ -+#export: Extrnals.html -+# -rm $(srcdir)/Extrnals.html; -+# (cd $(srcdir) && \ -+# perl ../../config/makeindx.pl ../src/ ../src/WWW*.html \ -+# > Extrnals.html) -+ -+Extrnals.html : -+ echo Missing perl script to produce Extrnals.html > Extrnals.html - - export: Extrnals.html -- -rm $(srcdir)/Extrnals.html; -- (cd $(srcdir) && \ -- perl ../../config/makeindx.pl ../src/ ../src/WWW*.html \ -- > Extrnals.html) -+ echo Missing perl script to produce Extrnals.html > Extrnals.html -+ diff --git a/www/libwww/patches/patch-am b/www/libwww/patches/patch-am deleted file mode 100644 index d333810d112..00000000000 --- a/www/libwww/patches/patch-am +++ /dev/null @@ -1,146 +0,0 @@ -$NetBSD: patch-am,v 1.3 2004/02/29 11:49:55 markd Exp $ - ---- configure.in.orig 2002-06-12 04:26:46.000000000 -0500 -+++ configure.in -@@ -237,6 +237,8 @@ AC_CHECK_FUNC(unlink) - fi - fi - -+dnl AC_CHECK_FUNC(unlink, , AC_CHECK_FUNC(remove, AC_DEFINE(unlink, remove))) -+ - dnl Checks for configuration arguments - AC_MSG_CHECKING(whether to support direct WAIS access.) - AC_ARG_WITH(wais, -@@ -330,6 +332,11 @@ AC_ARG_WITH(regex, - AC_DEFINE(HT_POSIX_REGEX) - if test "x$withval" = "xyes"; then - AC_CHECK_LIB(rx, regexec, [ LIBS="-lrx $LIBS" ] ) -+ AC_TRY_LINK([], -+ [ regexec(); ], -+ [], -+ [ AC_CHECK_LIB(rx, regexec, [ LIBS="-lrx $LIBS" ] ) ] ) -+ - else - AC_ADDLIB($withval) - AC_TRY_LINK([], -@@ -532,27 +539,39 @@ AC_ARG_WITH(md5, - [ case "$withval" in - no) - AC_MSG_RESULT(no) -+ MD5DIR="" - WWWMD5="" - LWWWMD5="" - LIBWWWMD5="" -+ LIBMD5DEP="" -+ LIBMD5INC="" -+ AC_CHECK_LIB(c, MD5Init, [:], -+ [ AC_CHECK_LIB(md5, MD5Init, [ LWWWMD5="-lmd5"; LIBWWWMD5="-lmd5"], [ AC_MSG_ERROR(Could not find md5 functions. You need to compile in the md5 library.) ] ) ] ) - ;; - *) - AC_MSG_RESULT(yes) - AC_DEFINE(HT_MD5) -+ MD5DIR="md5" - WWWMD5="libmd5.la" - LWWWMD5="-lmd5" - LIBWWWMD5='${top_builddir}/modules/md5/libmd5.la' -+ LIBMD5INC='-I${top_srcdir}/modules/md5' -+ LIBMD5DEP="../../modules/md5/libmd5.la" - ;; - esac ], - AC_MSG_RESULT(yes) - AC_DEFINE(HT_MD5) -+ MD5DIR="md5" - WWWMD5="libmd5.la" - LWWWMD5="-lmd5" - LIBWWWMD5='${top_builddir}/modules/md5/libmd5.la' - ) -+AC_SUBST(MD5DIR) - AC_SUBST(WWWMD5) - AC_SUBST(LWWWMD5) - AC_SUBST(LIBWWWMD5) -+AC_SUBST(LIBMD5INC) -+AC_SUBST(LIBMD5DEP) - - AC_MSG_CHECKING(whether we include WebDAV support.) - AC_ARG_WITH(dav, -@@ -609,31 +628,9 @@ AC_SUBST(MYEXT) - - - --dnl Checks for libwww and OpenSSL: --AC_MSG_CHECKING(whether we can find OpenSSL) --dnl find the ssl library dir (empirical) --if test -d '/usr/local/ssl/lib'; then -- ssllib="-L/usr/local/ssl/lib -lssl -lcrypto" --else -- ssllib="-L/usr/lib -lssl -lcrypto" --fi --dnl find the ssl include dir (empirical) --if test -d '/usr/local/ssl/include'; then -- sslinc="-I/usr/local/ssl/include" --elif test -d '/usr/local/openssl/include'; then -- sslinc="-I/usr/local/openssl/include" --elif test -d '/usr/local/include/openssl'; then -- sslinc="-I/usr/local/include/openssl" --elif test -d '/usr/include/ssl'; then -- sslinc="-I/usr/include/ssl" --elif test -d '/usr/include/openssl'; then -- sslinc="-I/usr/include/openssl" --else -- sslinc="" --fi -+dnl Checks for OpenSSL: -+AC_MSG_CHECKING(whether to support OpenSSL.) - WWWSSL="" --SSLINC="" --LIBSSL="" - LWWWSSL="" - LIBWWWSSL="" - WWWSSLEX="" -@@ -645,10 +642,35 @@ AC_ARG_WITH(ssl, - ;; - *) - if test "x$withval" = "xyes"; then -- withval=$ssllib -- SSLINC=$sslinc -+ dnl find the ssl library dir (empirical) -+ if test -d '/usr/local/ssl/lib'; then -+ ssllib="-L/usr/local/ssl/lib -lssl -lcrypto" -+ else -+ ssllib="-L/usr/lib -lssl -lcrypto" -+ fi -+ dnl find the ssl include dir (empirical) -+ if test -d '/usr/local/ssl/include'; then -+ sslinc="-I/usr/local/ssl/include" -+ elif test -d '/usr/local/openssl/include'; then -+ sslinc="-I/usr/local/openssl/include" -+ elif test -d '/usr/local/include/openssl'; then -+ sslinc="-I/usr/local/include/openssl" -+ elif test -d '/usr/include/ssl'; then -+ sslinc="-I/usr/include/ssl" -+ elif test -d '/usr/include/openssl'; then -+ sslinc="-I/usr/include/openssl" -+ else -+ sslinc="" -+ fi -+ SSLINC="$sslinc" -+ SSLLIBS="$ssllib" -+ else -+ SSLINC="-I${withval}/include/openssl -I${withval}/include" -+ SSLLIBS="-L${withval}/lib -lssl -lcrypto -Wl,-R${withval}/lib" -+ - fi -- LIBS="$LIBS $withval" -+ SAVED_LIBS="${LIBS}" -+ LIBS="${LIBS} ${SSLLIBS}" - AC_TRY_LINK([], - [ SSL_library_init(); ], - [], -@@ -663,6 +685,7 @@ AC_ARG_WITH(ssl, - [ AC_MSG_RESULT(no) ]) - AC_SUBST(WWWSSL) - AC_SUBST(SSLINC) -+AC_SUBST(SSLLIBS) - AC_SUBST(LWWWSSL) - AC_SUBST(LIBWWWSSL) - AC_SUBST(WWWSSLEX) diff --git a/www/libwww/patches/patch-an b/www/libwww/patches/patch-an deleted file mode 100644 index 6f1ef4ce614..00000000000 --- a/www/libwww/patches/patch-an +++ /dev/null @@ -1,12 +0,0 @@ -$NetBSD: patch-an,v 1.1 2003/04/03 18:05:34 jschauma Exp $ - ---- modules/expat/xmltok/Makefile.am.orig Thu Apr 3 12:50:10 2003 -+++ modules/expat/xmltok/Makefile.am Thu Apr 3 12:50:20 2003 -@@ -1,6 +1,6 @@ - ## Process this file with Automake to create Makefile.in. - --LDFLAGS = -version-info "1:0:1" -+LDFLAGS = @LDFLAGS@ -version-info "1:0:1" - - CFLAGS = @CFLAGS@ -DXML_NS - diff --git a/www/libwww/patches/patch-ao b/www/libwww/patches/patch-ao deleted file mode 100644 index cde9bc38251..00000000000 --- a/www/libwww/patches/patch-ao +++ /dev/null @@ -1,21 +0,0 @@ -$NetBSD: patch-ao,v 1.2 2013/07/05 21:06:02 joerg Exp $ - ---- modules/expat/xmlparse/Makefile.am.orig 2000-06-14 08:53:42.000000000 +0000 -+++ modules/expat/xmlparse/Makefile.am -@@ -1,6 +1,6 @@ - ## Process this file with Automake to create Makefile.in. - --LDFLAGS = -version-info "1:0:1" -+LDFLAGS = @LDFLAGS@ -version-info "1:0:1" - - CFLAGS = @CFLAGS@ -DXML_NS - -@@ -17,7 +17,7 @@ libxmlparse_la_SOURCES = \ - hashtable.c \ - xmlparse.c - --libxmlparse_la_LDFLAGS = -rpath $(libdir) -+libxmlparse_la_LDFLAGS = -rpath $(libdir) ../xmltok/libxmltok.la - - pkginclude_HEADERS = \ - xmlparse.h diff --git a/www/libwww/patches/patch-ap b/www/libwww/patches/patch-ap deleted file mode 100644 index 45ab46899c8..00000000000 --- a/www/libwww/patches/patch-ap +++ /dev/null @@ -1,524 +0,0 @@ -$NetBSD: patch-ap,v 1.1 2005/11/03 15:51:59 salo Exp $ - ---- Library/src/HTBound.c.orig 1999-02-22 23:10:10.000000000 +0100 -+++ Library/src/HTBound.c 2005-11-03 16:43:25.000000000 +0100 -@@ -11,9 +11,12 @@ - ** - ** Authors - ** HF Henrik Frystyk <frystyk@w3.org> -+** SV Sam Varshavchik <mrsam@courier-mta.com> - ** - ** History: - ** Nov 95 Written from scratch -+** SV Jun 05 Rewrote HTBoundary_put_block. Fixed many bugs+segfaults. -+** SV Jul 05 Fix double-counting of processed bytes. - ** - */ - -@@ -23,104 +26,395 @@ - #include "WWWCore.h" - #include "HTMerge.h" - #include "HTReqMan.h" -+#include "HTNetMan.h" -+#include "HTChannl.h" - #include "HTBound.h" /* Implemented here */ - --#define PUTBLOCK(b, l) (*me->target->isa->put_block)(me->target, b, l) -+#define PUTBLOCK(b, l) (me->target ? (*me->target->isa->put_block)(me->target, b, l):HT_OK) -+ - #define PUTDEBUG(b, l) (*me->debug->isa->put_block)(me->debug, b, l) - #define FREE_TARGET (*me->target->isa->_free)(me->target) - - struct _HTStream { - const HTStreamClass * isa; -+ HTNet * net; - HTStream * target; - HTStream * orig_target; - HTFormat format; - HTStream * debug; /* For preamble and epilog */ - HTRequest * request; -- BOOL body; /* Body or preamble|epilog */ -- HTEOLState state; -- int dash; /* Number of dashes */ - char * boundary; -- char * bpos; -+ -+ BOOL keptcrlf; -+ int (*state)(HTStream *, const char *, int); -+ -+ char *boundary_ptr; -+ - }; - -+PRIVATE int HTBoundary_flush (HTStream * me); -+ - /* ------------------------------------------------------------------------- */ - -+PRIVATE int start_of_line (HTStream * me, const char * b, int l); -+PRIVATE int seen_dash (HTStream * me, const char * b, int l); -+PRIVATE int seen_doubledash (HTStream * me, const char * b, int l); -+PRIVATE int seen_delimiter_nonterminal(HTStream * me, const char * b, int l); -+PRIVATE int seen_delimiter_nonterminal_CR(HTStream * me, const char * b, int l); -+PRIVATE int seen_delimiter_dash(HTStream * me, const char * b, int l); -+PRIVATE int seen_delimiter_terminal(HTStream * me, const char * b, int l); -+PRIVATE int seen_delimiter_terminal_CR(HTStream * me, const char * b, int l); -+PRIVATE int not_delimiter(HTStream * me, const char * b, int l, int extra); -+PRIVATE int seen_nothing(HTStream * me, const char * b, int l); -+PRIVATE int seen_cr(HTStream * me, const char * b, int l); -+PRIVATE void process_boundary(HTStream *me, int isterminal); -+ -+#define UNUSED(l) (l=l) /* Shut up about unused variables */ -+ - PRIVATE int HTBoundary_put_block (HTStream * me, const char * b, int l) - { -- const char *start = b; -- const char *end = b; -- while (l-- > 0) { -- if (me->state == EOL_FCR) { -- me->state = (*b == LF) ? EOL_FLF : EOL_BEGIN; -- } else if (me->state == EOL_FLF) { -- if (me->dash == 2) { -- while (l>0 && *me->bpos && *me->bpos==*b) l--, me->bpos++, b++; -- if (!*me->bpos) { -- HTTRACE(STREAM_TRACE, "Boundary.... `%s\' found\n" _ me->boundary); -- me->bpos = me->boundary; -- me->body = YES; -- me->state = EOL_DOT; -- } else if (l>0) { -- me->dash = 0; -- me->bpos = me->boundary; -- me->state = EOL_BEGIN; -- } -- } -- if (*b == '-') { -- me->dash++; -- } else if (*b != CR && *b != LF) { -- me->dash = 0; -- me->state = EOL_BEGIN; -- } -- } else if (me->state == EOL_SLF) { /* Look for closing '--' */ -- if (me->dash == 4) { -- if (end > start) { -- int status = PUTBLOCK(start, end-start); -- if (status != HT_OK) return status; -- } -- HTTRACE(STREAM_TRACE, "Boundary.... Ending\n"); -- start = b; -- me->dash = 0; -- me->state = EOL_BEGIN; -- } -- if (*b == '-') { -- me->dash++; -- } else if (*b != CR && *b != LF) { -- me->dash = 0; -- me->state = EOL_BEGIN; -- } -- me->body = NO; -- } else if (me->state == EOL_DOT) { -- int status; -- if (me->body) { -- if (me->target) FREE_TARGET; -- me->target = HTStreamStack(WWW_MIME,me->format, -- HTMerge(me->orig_target, 2), -- me->request, YES); -- if (end > start) { -- if ((status = PUTBLOCK(start, end-start)) != HT_OK) -- return status; -+ /* -+ ** The HTBoundary object gets attached downstream of HTMime. -+ ** The HTBoundary object creates another HTMime object downstream of -+ ** the HTBoundary object. -+ ** -+ ** When we push data downstream to the second HTBoundary object, it -+ ** updates the bytes read count in the HTNet object. -+ ** -+ ** When we return to the parent HTMime object, itupdates the -+ ** bytes read count in the HTNet object again. Oops. -+ ** -+ ** Same thing happens with the consumed byte count. We can prevent -+ ** the consumed byte counts from being updated by temporary setting -+ ** the input channel stream pointer to NULL, but for the byte counts -+ ** we have to save them and restore them before existing. -+ ** -+ ** This bug was discovered by chance when a multipart/partial response -+ ** was partially received, and as a result of double-counting the -+ ** real response got cut off (because HTMime thought that more bytes -+ ** were processed than actually were, thus it processed only the -+ ** partial count of the remaining bytes in the response). When the -+ ** multipart/partial response was received all at once this bug did -+ ** not get triggered. -+ */ -+ -+ HTHost *host=HTNet_host(me->net); -+ HTChannel *c=HTHost_channel(host); -+ HTInputStream *i=HTChannel_input(c); -+ -+ long saveBytesRead=HTNet_bytesRead(me->net); -+ long saveHeaderBytesRead=HTNet_headerBytesRead(me->net); -+ -+ if (i) -+ HTChannel_setInput(c, NULL); -+ -+ HTTRACE(STREAM_TRACE, "Boundary: processing %d bytes\n" _ l); -+ /* Main loop consumes all input */ -+ -+ while (l) -+ { -+ int n= (*me->state)(me, b, l); -+ -+ if (n == 0) -+ return HT_ERROR; -+ b += n; -+ l -= n; -+ } -+ -+ if (i) -+ HTChannel_setInput(c, i); -+ HTNet_setBytesRead(me->net, saveBytesRead); -+ HTNet_setHeaderBytesRead(me->net, saveHeaderBytesRead); -+ -+ return HT_OK; -+} -+ -+/* -+** Start of line, keptcrlf=YES if we've kept the preceding CRLF from downstream -+** and we'll pass it along if we decide that this is not a boundary delimiter. -+*/ -+ -+PRIVATE int start_of_line (HTStream * me, const char * b, int l) -+{ -+ if (*b != '-') -+ return not_delimiter(me, b, l, 0); -+ -+ HTTRACE(STREAM_TRACE, "Boundary: start of line: input '-'\n"); -+ -+ me->state= seen_dash; -+ -+ return 1; -+} -+ -+/* -+** Line: - -+*/ -+ -+PRIVATE int seen_dash (HTStream * me, const char * b, int l) -+{ -+ if (*b != '-') -+ return not_delimiter(me, b, l, 1); -+ -+ HTTRACE(STREAM_TRACE, "Boundary: start of line: input '--'\n"); -+ -+ me->state= seen_doubledash; -+ me->boundary_ptr=me->boundary; -+ return 1; -+} -+ -+/* -+** Line: -- -+*/ -+ -+PRIVATE int seen_doubledash (HTStream * me, const char * b, int l) -+{ -+ me->state=seen_doubledash; -+ -+ if (*me->boundary_ptr) -+ { -+ if (*b != *me->boundary_ptr) -+ { -+ return not_delimiter(me, b, l, -+ me->boundary_ptr - me->boundary -+ + 2); - } -- } else { -- if (me->debug) -- if ((status = PUTDEBUG(start, end-start)) != HT_OK) -- return status; -+ ++me->boundary_ptr; -+ return 1; - } -- start = b; -- if (*b == '-') me->dash++; -- me->state = EOL_SLF; -- } else if (*b == CR) { -- me->state = EOL_FCR; -- end = b; -- } else if (*b == LF) { -- if (me->state != EOL_FCR) end = b; -- me->state = EOL_FLF; -+ -+ /* -+ ** Line: --delimiter -+ */ -+ -+ if (*b == '-') -+ { -+ HTTRACE(STREAM_TRACE, -+ "Boundary: start of line: input '--%s-'\n" -+ _ me->boundary); -+ -+ me->state=seen_delimiter_dash; -+ return 1; - } -- b++; -+ -+ HTTRACE(STREAM_TRACE, -+ "Boundary: Found: '--%s'\n" _ me->boundary); -+ -+ return seen_delimiter_nonterminal(me, b, l); -+} -+ -+/* -+** Line: --delimiter -+** -+** Waiting for CRLF. -+*/ -+ -+ -+PRIVATE int seen_delimiter_nonterminal(HTStream * me, const char * b, int l) -+{ -+ UNUSED(l); -+ -+ me->state=seen_delimiter_nonterminal; -+ if (*b == CR) -+ me->state=seen_delimiter_nonterminal_CR; -+ -+ return 1; -+} -+ -+/* -+** Line: --delimiter<CR> -+*/ -+ -+PRIVATE int seen_delimiter_nonterminal_CR(HTStream * me, const char * b, int l) -+{ -+ HTTRACE(STREAM_TRACE, -+ "Boundary: Found: '--%s<CR>'\n" _ me->boundary); -+ -+ if (*b != LF) -+ return seen_delimiter_nonterminal(me, b, l); -+ -+ HTTRACE(STREAM_TRACE, -+ "Boundary: Found: '--%s<CR><LF>'\n" _ me->boundary); -+ -+ process_boundary(me, NO); -+ return 1; -+} -+ -+/* -+** Line: --delimiter- -+*/ -+ -+PRIVATE int seen_delimiter_dash(HTStream * me, const char * b, int l) -+{ -+ if (*b != '-') -+ return seen_delimiter_nonterminal(me, b, l); -+ -+ HTTRACE(STREAM_TRACE, -+ "Boundary: start of line: input '--%s--'\n" -+ _ me->boundary); -+ -+ me->state=seen_delimiter_terminal; -+ return 1; -+} -+ -+/* -+** Line: --delimiter-- -+*/ -+ -+PRIVATE int seen_delimiter_terminal(HTStream * me, const char * b, int l) -+{ -+ UNUSED(l); -+ -+ me->state=seen_delimiter_terminal; -+ -+ if (*b == CR) -+ me->state=seen_delimiter_terminal_CR; -+ return 1; -+} -+/* -+** Line: --delimiter--<CR> -+*/ -+ -+PRIVATE int seen_delimiter_terminal_CR(HTStream * me, const char * b, int l) -+{ -+ HTTRACE(STREAM_TRACE, -+ "Boundary: Found '--%s--<CR>'\n" -+ _ me->boundary); -+ -+ if (*b != LF) -+ return seen_delimiter_terminal(me, b, l); -+ HTTRACE(STREAM_TRACE, -+ "Boundary: Found '--%s--<CR><LF>'\n" -+ _ me->boundary); -+ -+ process_boundary(me, YES); -+ return 1; -+} -+ -+/* -+** Beginning of the line does not contain a delimiter. -+** -+** -+** extra: Count of characters in a partially matched delimiter. Since it's -+** not a delimiter this is content that needs to go downstream. -+*/ -+ -+PRIVATE int not_delimiter(HTStream * me, const char * b, int l, int extra) -+{ -+ HTTRACE(STREAM_TRACE, "Boundary: not a delimiter line\n"); -+ -+ if (me->keptcrlf) -+ { -+ HTTRACE(STREAM_TRACE, "Boundary: Sending previous line's <CR><LF>\n"); -+ /* -+ ** Did not process CRLF from previous line, because prev CRLF -+ ** is considered a part of the delimiter. See MIME RFC. -+ */ -+ -+ me->keptcrlf=NO; -+ if (PUTBLOCK("\r\n", 2) != HT_OK) -+ return 0; -+ } -+ -+ /* -+ ** Potentially matched some of: --DELIMITER -+ */ -+ -+ if (extra) -+ { -+ HTTRACE(STREAM_TRACE, "Boundary: Sending partially-matched %d characters\n" _ extra); -+ -+ if (PUTBLOCK("--", extra > 2 ? 2:extra) != HT_OK) -+ return 0; -+ -+ if (extra > 2) -+ if (PUTBLOCK(me->boundary, extra-2) != HT_OK) -+ return 0; -+ } -+ return seen_nothing(me, b, l); -+} -+ -+/* -+** We're not looking for a delimiter. Look for the next line of input -+** in the data that could potentially be a delimiter. -+*/ -+ -+PRIVATE int seen_nothing(HTStream * me, const char * b, int l) -+{ -+ int i; -+ -+ me->state=seen_nothing; -+ -+ for (i=0; i<l; i++) -+ { -+ if (b[i] != CR) -+ continue; -+ -+ /* -+ ** If we have at least four more characters in unconsumed -+ ** input, and they're not \r\n--, we can safely skip over -+ ** them. -+ */ -+ -+ if (l-i > 4 && -+ strncmp(b+i, "\r\n--", 4)) -+ continue; -+ break; -+ } -+ -+ if (i == 0) -+ { -+ /* Could only be a CR here. */ -+ -+ me->state=seen_cr; -+ return 1; -+ } -+ -+ HTTRACE(STREAM_TRACE, "Boundary: Processed %d (out of %d) bytes\n" -+ _ i _ l); -+ -+ if (PUTBLOCK(b, i) != HT_OK) -+ return 0; -+ -+ return i; -+} -+ -+/* -+** State: seen a CR -+*/ -+ -+PRIVATE int seen_cr(HTStream * me, const char * b, int l) -+{ -+ HTTRACE(STREAM_TRACE, "Boundary: Processed <CR>\n"); -+ -+ if (*b != LF) -+ { -+ HTTRACE(STREAM_TRACE, "Boundary: ... <LF> didn't follow\n"); -+ if (PUTBLOCK("\r", 1) != HT_OK) -+ return 0; -+ return seen_nothing(me, b, l); - } -- return (start<b && me->body) ? PUTBLOCK(start, b-start) : HT_OK; -+ -+ HTTRACE(STREAM_TRACE, "Boundary: Processed <CR><LF>\n"); -+ me->state=start_of_line; -+ me->keptcrlf=YES; -+ return 1; -+} -+ -+PRIVATE void process_boundary(HTStream *me, int isterminal) -+{ -+ HTBoundary_flush(me); -+ if (me->target) FREE_TARGET; -+ me->target=NULL; -+ me->state=start_of_line; -+ me->keptcrlf=NO; -+ -+ if (!isterminal) -+ me->target = HTStreamStack(WWW_MIME,me->format, -+ HTMerge(me->orig_target, 2), -+ me->request, YES); - } - -+ - PRIVATE int HTBoundary_put_string (HTStream * me, const char * s) - { - return HTBoundary_put_block(me, s, (int) strlen(s)); -@@ -133,6 +427,8 @@ - - PRIVATE int HTBoundary_flush (HTStream * me) - { -+ if (me->target == NULL) -+ return HT_OK; - return (*me->target->isa->flush)(me->target); - } - -@@ -182,18 +478,26 @@ - HTResponse_formatParam(response) : - HTAnchor_formatParam(anchor); - char * boundary = HTAssocList_findObject(type_param, "boundary"); -+ -+ UNUSED(param); -+ UNUSED(input_format); -+ - if (boundary) { - HTStream * me; - if ((me = (HTStream *) HT_CALLOC(1, sizeof(HTStream))) == NULL) - HT_OUTOFMEM("HTBoundary"); - me->isa = &HTBoundaryClass; -+ me->net = HTRequest_net(request); - me->request = request; - me->format = output_format; - me->orig_target = output_stream; - me->debug = HTRequest_debugStream(request); -- me->state = EOL_FLF; -+ -+ me->state = start_of_line; -+ me->keptcrlf=NO; -+ - StrAllocCopy(me->boundary, boundary); /* Local copy */ -- me->bpos = me->boundary; -+ - HTTRACE(STREAM_TRACE, "Boundary.... Stream created with boundary '%s\'\n" _ me->boundary); - return me; - } else { diff --git a/www/libwww/patches/patch-aq b/www/libwww/patches/patch-aq deleted file mode 100644 index b45a646d669..00000000000 --- a/www/libwww/patches/patch-aq +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-aq,v 1.1 2006/10/04 19:45:21 rillig Exp $ - ---- configure.orig 2006-10-04 21:39:50.000000000 +0200 -+++ configure 2006-10-04 21:40:36.000000000 +0200 -@@ -31593,7 +31593,7 @@ fi - echo "$as_me:$LINENO: result: $ac_cv_func_remove" >&5 - echo "${ECHO_T}$ac_cv_func_remove" >&6 - -- if test "$ac_cv_func_remove" == yes ; then -+ if test "$ac_cv_func_remove" = yes ; then - cat >>confdefs.h <<\_ACEOF - #define unlink remove - _ACEOF diff --git a/www/libwww/patches/patch-ar b/www/libwww/patches/patch-ar deleted file mode 100644 index 50a58bbdca8..00000000000 --- a/www/libwww/patches/patch-ar +++ /dev/null @@ -1,15 +0,0 @@ -$NetBSD: patch-ar,v 1.1 2009/11/08 08:38:54 obache Exp $ - -CVE-2009-3720 - ---- modules/expat/xmltok/xmltok_impl.c.orig 2000-08-28 08:52:01.000000000 +0000 -+++ modules/expat/xmltok/xmltok_impl.c -@@ -1753,7 +1753,7 @@ void PREFIX(updatePosition)(const ENCODI - const char *end, - POSITION *pos) - { -- while (ptr != end) { -+ while (ptr < end) { - switch (BYTE_TYPE(enc, ptr)) { - #define LEAD_CASE(n) \ - case BT_LEAD ## n: \ diff --git a/www/libwww/patches/patch-as b/www/libwww/patches/patch-as deleted file mode 100644 index dc6baee9c2b..00000000000 --- a/www/libwww/patches/patch-as +++ /dev/null @@ -1,16 +0,0 @@ -$NetBSD: patch-as,v 1.1 2010/01/26 18:38:27 drochner Exp $ - -CVE-2009-3560 - ---- modules/expat/xmlparse/xmlparse.c.orig 2000-08-28 08:52:01.000000000 +0000 -+++ modules/expat/xmlparse/xmlparse.c -@@ -2199,6 +2199,9 @@ doProlog(XML_Parser parser, - return XML_ERROR_UNCLOSED_TOKEN; - case XML_TOK_PARTIAL_CHAR: - return XML_ERROR_PARTIAL_CHAR; -+ case -XML_TOK_PROLOG_S: -+ tok = -tok; -+ break; - case XML_TOK_NONE: - #ifdef XML_DTD - if (enc != encoding) diff --git a/www/libwww/patches/patch-configure b/www/libwww/patches/patch-configure new file mode 100644 index 00000000000..1b957f46538 --- /dev/null +++ b/www/libwww/patches/patch-configure @@ -0,0 +1,24 @@ +$NetBSD: patch-configure,v 1.1 2018/06/24 16:54:59 adam Exp $ + +Explicit declaration of SSL_library_init(). +Portability fix. + +--- configure.orig 2017-06-24 06:11:34.000000000 +0000 ++++ configure +@@ -15439,7 +15439,7 @@ if test "x$ac_cv_func_remove" = xyes; th + + fi + +- if test "$ac_cv_func_remove" == yes ; then ++ if test "$ac_cv_func_remove" = yes ; then + + $as_echo "#define unlink remove" >>confdefs.h + +@@ -16420,6 +16420,7 @@ $as_echo "no" >&6; } + LIBS="$LIBS $withval" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ ++#include <openssl/ssl.h> + + int + main () diff --git a/www/libwww/patches/patch-libwww-config.in b/www/libwww/patches/patch-libwww-config.in new file mode 100644 index 00000000000..9d9127afe96 --- /dev/null +++ b/www/libwww/patches/patch-libwww-config.in @@ -0,0 +1,15 @@ +$NetBSD: patch-libwww-config.in,v 1.1 2018/06/24 16:54:59 adam Exp $ + +Add proper linker flags. + +--- libwww-config.in.orig 2017-06-24 05:51:38.000000000 +0000 ++++ libwww-config.in +@@ -48,7 +48,7 @@ while test $# -gt 0; do + echo -I@includedir@ -I@includedir@/@PACKAGE@ @DEFS@ + ;; + --libs) +- echo -L@libdir@ @LWWWZIP@ @LWWWWAIS@ @LWWWSQL@ -lwwwinit -lwwwapp @LWWWXML@ -lwwwhtml -lwwwtelnet -lwwwnews -lwwwhttp -lwwwmime -lwwwgopher -lwwwftp -lwwwfile -lwwwdir -lwwwcache -lwwwstream -lwwwmux -lwwwtrans -lwwwcore -lwwwutils @LWWWMD5@ @LWWWSSL@ @LIBS@ ++ echo -L@libdir@ -Wl,-R@libdir@ @LWWWZIP@ @LWWWWAIS@ @LWWWSQL@ -lwwwinit -lwwwapp @LWWWXML@ -lwwwhtml -lwwwtelnet -lwwwnews -lwwwhttp -lwwwmime -lwwwgopher -lwwwftp -lwwwfile -lwwwdir -lwwwcache -lwwwstream -lwwwmux -lwwwtrans -lwwwcore -lwwwutils @LWWWMD5@ @LWWWSSL@ @LIBS@ + ;; + *) + echo "${usage}" 1>&2 |