aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorTim Rühsen <tim.ruehsen@gmx.de>2015-09-29 11:33:01 +0200
committerDaniel Stenberg <daniel@haxx.se>2015-10-17 16:37:49 +0200
commite77b5b7453c1e8ccd7ec0816890d98e2f392e465 (patch)
treeae7b513cc29249c745755a353ecc240dee912f0f /configure.ac
parent684816cd9b846a955947ef57e269b12e5224f408 (diff)
cookies: Add support for Mozilla's Publix Suffix List
Use libpsl to check the domain value of Set-Cookie headers (and cookie jar entries) for not being a Publix Suffix. The configure script checks for "libpsl" by default. Disable the check with --without-libpsl. Ref: https://publicsuffix.org/ Ref: https://github.com/publicsuffix/list Ref: https://github.com/rockdaboot/libpsl
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac23
1 files changed, 23 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 0ee4943f5..549cd96ff 100644
--- a/configure.ac
+++ b/configure.ac
@@ -167,6 +167,7 @@ curl_verbose_msg="enabled (--disable-verbose)"
curl_rtsp_msg="no (--enable-rtsp)"
curl_rtmp_msg="no (--with-librtmp)"
curl_mtlnk_msg="no (--with-libmetalink)"
+ curl_psl_msg="no (--with-libpsl)"
init_ssl_msg=${curl_ssl_msg}
@@ -2315,6 +2316,27 @@ dnl **********************************************************************
CURL_CHECK_CA_BUNDLE
dnl **********************************************************************
+dnl Check for libpsl
+dnl **********************************************************************
+
+AC_ARG_WITH(libpsl,
+ AS_HELP_STRING([--without-libpsl],
+ [disable support for libpsl cookie checking]),
+ with_libpsl=$withval,
+ with_libpsl=yes)
+if test $with_libpsl != "no"; then
+ AC_SEARCH_LIBS(psl_builtin, psl,
+ [curl_psl_msg="yes";
+ AC_DEFINE([USE_LIBPSL], [1], [PSL support enabled])
+ ],
+ [curl_psl_msg="no (libpsl not found)";
+ AC_MSG_WARN([libpsl was not found])
+ ]
+ )
+fi
+AM_CONDITIONAL([USE_LIBPSL], [test "$curl_psl_msg" = "yes"])
+
+dnl **********************************************************************
dnl Check for libmetalink
dnl **********************************************************************
@@ -3742,6 +3764,7 @@ AC_MSG_NOTICE([Configured to build curl/libcurl:
RTSP support: ${curl_rtsp_msg}
RTMP support: ${curl_rtmp_msg}
metalink support: ${curl_mtlnk_msg}
+ PSL support: ${curl_psl_msg}
HTTP2 support: ${curl_h2_msg}
Protocols: ${SUPPORT_PROTOCOLS}
])