summaryrefslogtreecommitdiffstats
path: root/meta/recipes-support/curl/curl_8.12.0.bb
diff options
context:
space:
mode:
authorPeter Marko <peter.marko@siemens.com>2025-02-08 17:33:00 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2025-02-10 13:03:58 +0000
commitf7174e591f6be2669542cbcfc326ca36dca5b61b (patch)
tree156a78aa4aae4978008921f7e5b892c2156c724d /meta/recipes-support/curl/curl_8.12.0.bb
parent10870db533607cd6db73801f4c044ef58a5a06d7 (diff)
downloadpoky-f7174e591f6be2669542cbcfc326ca36dca5b61b.tar.gz
curl: upgrade 8.11.1 -> 8.12.0
Solves CVE-2025-0167, CVE-2025-0665 and CVE-2025-0725. Initialize WATT_ROOT variable to avoid looking in host dirs when autotools are checking available features. License-Update: copyright year refreshed (From OE-Core rev: dd642c786e9c9eee06a90562e69e70cb37e704df) Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-support/curl/curl_8.12.0.bb')
-rw-r--r--meta/recipes-support/curl/curl_8.12.0.bb155
1 files changed, 155 insertions, 0 deletions
diff --git a/meta/recipes-support/curl/curl_8.12.0.bb b/meta/recipes-support/curl/curl_8.12.0.bb
new file mode 100644
index 0000000000..7b5e6350ba
--- /dev/null
+++ b/meta/recipes-support/curl/curl_8.12.0.bb
@@ -0,0 +1,155 @@
1SUMMARY = "Command line tool and library for client-side URL transfers"
2DESCRIPTION = "It uses URL syntax to transfer data to and from servers. \
3curl is a widely used because of its ability to be flexible and complete \
4complex tasks. For example, you can use curl for things like user authentication, \
5HTTP post, SSL connections, proxy support, FTP uploads, and more!"
6HOMEPAGE = "https://curl.se/"
7BUGTRACKER = "https://github.com/curl/curl/issues"
8SECTION = "console/network"
9LICENSE = "curl"
10LIC_FILES_CHKSUM = "file://COPYING;md5=72f4e9890e99e68d77b7e40703d789b8"
11
12SRC_URI = " \
13 https://curl.se/download/${BP}.tar.xz \
14 file://run-ptest \
15 file://disable-tests \
16 file://no-test-timeout.patch \
17"
18SRC_URI[sha256sum] = "9a4628c764be6b1a9909567c13e8e771041609df43b2158fcac4e05ea7097e5d"
19
20# Curl has used many names over the years...
21CVE_PRODUCT = "haxx:curl haxx:libcurl curl:curl curl:libcurl libcurl:libcurl daniel_stenberg:curl"
22CVE_STATUS[CVE-2024-32928] = "ignored: CURLOPT_SSL_VERIFYPEER was disabled on google cloud services causing a potential man in the middle attack"
23
24inherit autotools pkgconfig binconfig multilib_header ptest
25
26COMMON_PACKAGECONFIG = "basic-auth bearer-auth digest-auth ipfs negotiate-auth openssl proxy threaded-resolver verbose zlib"
27PACKAGECONFIG ??= "${COMMON_PACKAGECONFIG} ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} aws libidn"
28PACKAGECONFIG:class-native = "${COMMON_PACKAGECONFIG} ipv6"
29PACKAGECONFIG:class-nativesdk = "${COMMON_PACKAGECONFIG} ipv6"
30
31# 'ares' and 'threaded-resolver' are mutually exclusive
32PACKAGECONFIG[ares] = "--enable-ares,--disable-ares,c-ares,,,threaded-resolver"
33PACKAGECONFIG[aws] = "--enable-aws,--disable-aws"
34PACKAGECONFIG[basic-auth] = "--enable-basic-auth,--disable-basic-auth"
35PACKAGECONFIG[bearer-auth] = "--enable-bearer-auth,--disable-bearer-auth"
36PACKAGECONFIG[brotli] = "--with-brotli,--without-brotli,brotli"
37PACKAGECONFIG[builtinmanual] = "--enable-manual,--disable-manual"
38# Don't use this in production
39PACKAGECONFIG[debug] = "--enable-debug,--disable-debug"
40PACKAGECONFIG[dict] = "--enable-dict,--disable-dict,"
41PACKAGECONFIG[digest-auth] = "--enable-digest-auth,--disable-digest-auth"
42PACKAGECONFIG[gnutls] = "--with-gnutls,--without-gnutls,gnutls"
43PACKAGECONFIG[gopher] = "--enable-gopher,--disable-gopher,"
44PACKAGECONFIG[imap] = "--enable-imap,--disable-imap,"
45PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
46PACKAGECONFIG[ipfs] = "--enable-ipfs,--disable-ipfs,"
47PACKAGECONFIG[kerberos-auth] = "--enable-kerberos-auth,--disable-kerberos-auth"
48PACKAGECONFIG[krb5] = "--with-gssapi,--without-gssapi,krb5"
49PACKAGECONFIG[ldap] = "--enable-ldap,--disable-ldap,openldap"
50PACKAGECONFIG[ldaps] = "--enable-ldaps,--disable-ldaps,openldap"
51PACKAGECONFIG[libgsasl] = "--with-libgsasl,--without-libgsasl,libgsasl"
52PACKAGECONFIG[libidn] = "--with-libidn2,--without-libidn2,libidn2"
53PACKAGECONFIG[libssh2] = "--with-libssh2,--without-libssh2,libssh2"
54PACKAGECONFIG[mbedtls] = "--with-mbedtls=${STAGING_DIR_TARGET},--without-mbedtls,mbedtls"
55PACKAGECONFIG[mqtt] = "--enable-mqtt,--disable-mqtt,"
56PACKAGECONFIG[negotiate-auth] = "--enable-negotiate-auth,--disable-negotiate-auth"
57PACKAGECONFIG[nghttp2] = "--with-nghttp2,--without-nghttp2,nghttp2"
58PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl"
59PACKAGECONFIG[pop3] = "--enable-pop3,--disable-pop3,"
60PACKAGECONFIG[proxy] = "--enable-proxy,--disable-proxy,"
61PACKAGECONFIG[rtmpdump] = "--with-librtmp,--without-librtmp,rtmpdump"
62PACKAGECONFIG[rtsp] = "--enable-rtsp,--disable-rtsp,"
63PACKAGECONFIG[smb] = "--enable-smb,--disable-smb,"
64PACKAGECONFIG[smtp] = "--enable-smtp,--disable-smtp,"
65PACKAGECONFIG[telnet] = "--enable-telnet,--disable-telnet,"
66PACKAGECONFIG[tftp] = "--enable-tftp,--disable-tftp,"
67PACKAGECONFIG[threaded-resolver] = "--enable-threaded-resolver,--disable-threaded-resolver,,,,ares"
68PACKAGECONFIG[verbose] = "--enable-verbose,--disable-verbose"
69PACKAGECONFIG[websockets] = "--enable-websockets,--disable-websockets"
70PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_LIBDIR}/../,--without-zlib,zlib"
71PACKAGECONFIG[zstd] = "--with-zstd,--without-zstd,zstd"
72
73EXTRA_OECONF = " \
74 --disable-libcurl-option \
75 --with-ca-bundle=${sysconfdir}/ssl/certs/ca-certificates.crt \
76 --without-libpsl \
77 --enable-optimize \
78 ${@'--without-ssl' if (bb.utils.filter('PACKAGECONFIG', 'gnutls mbedtls openssl', d) == '') else ''} \
79 WATT_ROOT=${STAGING_DIR_TARGET}${prefix} \
80"
81
82fix_absolute_paths () {
83 # cleanup buildpaths from curl-config
84 sed -i \
85 -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
86 -e 's,--with-libtool-sysroot=${STAGING_DIR_TARGET},,g' \
87 -e 's|${DEBUG_PREFIX_MAP}||g' \
88 -e 's|${@" ".join(d.getVar("DEBUG_PREFIX_MAP").split())}||g' \
89 ${D}${bindir}/curl-config
90}
91
92do_install:append:class-target() {
93 fix_absolute_paths
94}
95
96do_install:append:class-nativesdk() {
97 fix_absolute_paths
98}
99
100do_compile_ptest() {
101 oe_runmake -C ${B}/tests
102}
103
104do_install_ptest() {
105 install -d ${D}${PTEST_PATH}/tests
106 cp ${S}/tests/*.p[lmy] ${D}${PTEST_PATH}/tests/
107
108 install -d ${D}${PTEST_PATH}/tests/libtest
109 for name in $(makefile-getvar ${B}/tests/libtest/Makefile noinst_PROGRAMS noinst_LTLIBRARIES); do
110 ${B}/libtool --mode=install install ${B}/tests/libtest/$name ${D}${PTEST_PATH}/tests/libtest
111 done
112 rm -f ${D}${PTEST_PATH}/tests/libtest/libhostname.la
113
114 install -d ${D}${PTEST_PATH}/tests/server
115 for name in $(makefile-getvar ${B}/tests/server/Makefile noinst_PROGRAMS); do
116 ${B}/libtool --mode=install install ${B}/tests/server/$name ${D}${PTEST_PATH}/tests/server
117 done
118
119 cp -r ${S}/tests/data ${D}${PTEST_PATH}/tests/
120
121 # More tests that we disable for automated QA as they're not reliable
122 cat ${UNPACKDIR}/disable-tests >>${D}${PTEST_PATH}/tests/data/DISABLED
123}
124
125RDEPENDS:${PN}-ptest += " \
126 locale-base-en-us \
127 perl-module-b \
128 perl-module-base \
129 perl-module-cwd \
130 perl-module-digest \
131 perl-module-digest-md5 \
132 perl-module-digest-sha \
133 perl-module-file-basename \
134 perl-module-file-spec \
135 perl-module-file-temp \
136 perl-module-i18n-langinfo \
137 perl-module-io-socket \
138 perl-module-ipc-open2 \
139 perl-module-list-util \
140 perl-module-memoize \
141 perl-module-storable \
142 perl-module-time-hires \
143"
144
145PACKAGES =+ "lib${BPN}"
146
147FILES:lib${BPN} = "${libdir}/lib*.so.*"
148RRECOMMENDS:lib${BPN} += "ca-certificates"
149
150FILES:${PN} += "${datadir}/zsh"
151
152inherit multilib_script
153MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/curl-config"
154
155BBCLASSEXTEND = "native nativesdk"