mirror of https://github.com/hak5/openwrt-owl.git
curl: Remove PolarSSL and adjust default to mbedTLS
luci-ssl has already made the switch since mainline support for PolarSSL is almost over (2016). Signed-off-by: Rosen Penev <rosenp@gmail.com>owl
parent
cd18ff9ed6
commit
558680012d
|
@ -4,10 +4,7 @@ comment "SSL support"
|
||||||
|
|
||||||
choice
|
choice
|
||||||
prompt "Selected SSL library"
|
prompt "Selected SSL library"
|
||||||
default LIBCURL_POLARSSL
|
default LIBCURL_MBEDTLS
|
||||||
|
|
||||||
config LIBCURL_POLARSSL
|
|
||||||
bool "PolarSSL"
|
|
||||||
|
|
||||||
config LIBCURL_MBEDTLS
|
config LIBCURL_MBEDTLS
|
||||||
bool "mbed TLS"
|
bool "mbed TLS"
|
||||||
|
|
|
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=curl
|
PKG_NAME:=curl
|
||||||
PKG_VERSION:=7.52.1
|
PKG_VERSION:=7.52.1
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||||
PKG_SOURCE_URL:=http://curl.haxx.se/download/ \
|
PKG_SOURCE_URL:=http://curl.haxx.se/download/ \
|
||||||
|
@ -32,7 +32,6 @@ PKG_CONFIG_DEPENDS:= \
|
||||||
CONFIG_LIBCURL_CYASSL \
|
CONFIG_LIBCURL_CYASSL \
|
||||||
CONFIG_LIBCURL_GNUTLS \
|
CONFIG_LIBCURL_GNUTLS \
|
||||||
CONFIG_LIBCURL_OPENSSL \
|
CONFIG_LIBCURL_OPENSSL \
|
||||||
CONFIG_LIBCURL_POLARSSL \
|
|
||||||
CONFIG_LIBCURL_MBEDTLS \
|
CONFIG_LIBCURL_MBEDTLS \
|
||||||
CONFIG_LIBCURL_NOSSL \
|
CONFIG_LIBCURL_NOSSL \
|
||||||
\
|
\
|
||||||
|
@ -87,7 +86,7 @@ define Package/libcurl
|
||||||
$(call Package/curl/Default)
|
$(call Package/curl/Default)
|
||||||
SECTION:=libs
|
SECTION:=libs
|
||||||
CATEGORY:=Libraries
|
CATEGORY:=Libraries
|
||||||
DEPENDS:=+LIBCURL_POLARSSL:libpolarssl +LIBCURL_CYASSL:libcyassl +LIBCURL_OPENSSL:libopenssl +LIBCURL_GNUTLS:libgnutls +LIBCURL_MBEDTLS:libmbedtls
|
DEPENDS:= +LIBCURL_CYASSL:libcyassl +LIBCURL_OPENSSL:libopenssl +LIBCURL_GNUTLS:libgnutls +LIBCURL_MBEDTLS:libmbedtls
|
||||||
DEPENDS += +LIBCURL_ZLIB:zlib +LIBCURL_THREADED_RESOLVER:libpthread +LIBCURL_LDAP:libopenldap +LIBCURL_LIBIDN:libidn +LIBCURL_SSH2:libssh2
|
DEPENDS += +LIBCURL_ZLIB:zlib +LIBCURL_THREADED_RESOLVER:libpthread +LIBCURL_LDAP:libopenldap +LIBCURL_LIBIDN:libidn +LIBCURL_SSH2:libssh2
|
||||||
TITLE:=A client-side URL transfer library
|
TITLE:=A client-side URL transfer library
|
||||||
MENU:=1
|
MENU:=1
|
||||||
|
@ -117,7 +116,6 @@ CONFIGURE_ARGS += \
|
||||||
$(if $(CONFIG_LIBCURL_CYASSL),--with-cyassl="$(STAGING_DIR)/usr" --without-ca-path --with-ca-bundle=/etc/ssl/certs/ca-certificates.crt,--without-cyassl) \
|
$(if $(CONFIG_LIBCURL_CYASSL),--with-cyassl="$(STAGING_DIR)/usr" --without-ca-path --with-ca-bundle=/etc/ssl/certs/ca-certificates.crt,--without-cyassl) \
|
||||||
$(if $(CONFIG_LIBCURL_GNUTLS),--with-gnutls="$(STAGING_DIR)/usr" --without-ca-bundle --with-ca-path=/etc/ssl/certs,--without-gnutls) \
|
$(if $(CONFIG_LIBCURL_GNUTLS),--with-gnutls="$(STAGING_DIR)/usr" --without-ca-bundle --with-ca-path=/etc/ssl/certs,--without-gnutls) \
|
||||||
$(if $(CONFIG_LIBCURL_OPENSSL),--with-ssl="$(STAGING_DIR)/usr" --without-ca-bundle --with-ca-path=/etc/ssl/certs,--without-ssl) \
|
$(if $(CONFIG_LIBCURL_OPENSSL),--with-ssl="$(STAGING_DIR)/usr" --without-ca-bundle --with-ca-path=/etc/ssl/certs,--without-ssl) \
|
||||||
$(if $(CONFIG_LIBCURL_POLARSSL),--with-polarssl="$(STAGING_DIR)/usr" --without-ca-bundle --with-ca-path=/etc/ssl/certs,--without-polarssl) \
|
|
||||||
$(if $(CONFIG_LIBCURL_MBEDTLS),--with-mbedtls="$(STAGING_DIR)/usr" --without-ca-path --with-ca-bundle=/etc/ssl/certs/ca-certificates.crt,--without-mbedtls) \
|
$(if $(CONFIG_LIBCURL_MBEDTLS),--with-mbedtls="$(STAGING_DIR)/usr" --without-ca-path --with-ca-bundle=/etc/ssl/certs/ca-certificates.crt,--without-mbedtls) \
|
||||||
\
|
\
|
||||||
$(if $(CONFIG_LIBCURL_LIBIDN),--with-libidn="$(STAGING_DIR)/usr",--without-libidn) \
|
$(if $(CONFIG_LIBCURL_LIBIDN),--with-libidn="$(STAGING_DIR)/usr",--without-libidn) \
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
--- a/lib/vtls/mbedtls.c
|
||||||
|
+++ b/lib/vtls/mbedtls.c
|
||||||
|
@@ -724,7 +724,7 @@ void Curl_mbedtls_session_free(void *ptr
|
||||||
|
|
||||||
|
size_t Curl_mbedtls_version(char *buffer, size_t size)
|
||||||
|
{
|
||||||
|
- unsigned int version = mbedtls_version_get_number();
|
||||||
|
+ unsigned int version = MBEDTLS_VERSION_NUMBER;
|
||||||
|
return snprintf(buffer, size, "mbedTLS/%d.%d.%d", version>>24,
|
||||||
|
(version>>16)&0xff, (version>>8)&0xff);
|
||||||
|
}
|
|
@ -1,22 +0,0 @@
|
||||||
--- a/lib/vtls/polarssl.c
|
|
||||||
+++ b/lib/vtls/polarssl.c
|
|
||||||
@@ -657,7 +657,7 @@ void Curl_polarssl_session_free(void *pt
|
|
||||||
|
|
||||||
size_t Curl_polarssl_version(char *buffer, size_t size)
|
|
||||||
{
|
|
||||||
- unsigned int version = version_get_number();
|
|
||||||
+ unsigned int version = POLARSSL_VERSION_NUMBER;
|
|
||||||
return snprintf(buffer, size, "%s/%d.%d.%d",
|
|
||||||
version >= 0x01030A00?"mbedTLS":"PolarSSL",
|
|
||||||
version>>24, (version>>16)&0xff, (version>>8)&0xff);
|
|
||||||
--- a/lib/vtls/mbedtls.c
|
|
||||||
+++ b/lib/vtls/mbedtls.c
|
|
||||||
@@ -724,7 +724,7 @@ void Curl_mbedtls_session_free(void *ptr
|
|
||||||
|
|
||||||
size_t Curl_mbedtls_version(char *buffer, size_t size)
|
|
||||||
{
|
|
||||||
- unsigned int version = mbedtls_version_get_number();
|
|
||||||
+ unsigned int version = MBEDTLS_VERSION_NUMBER;
|
|
||||||
return snprintf(buffer, size, "mbedTLS/%d.%d.%d", version>>24,
|
|
||||||
(version>>16)&0xff, (version>>8)&0xff);
|
|
||||||
}
|
|
Loading…
Reference in New Issue