From b3835ae6e0d734c9144b584d8dbdf305eb18448d Mon Sep 17 00:00:00 2001 From: ShahanaFarooqui Date: Tue, 28 Oct 2025 19:40:08 -0700 Subject: [PATCH 1/2] tests: check openssl version compatibility for fuzz tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This check will exclude fuzz tests for Ubuntu Focal as it supports OpenSSL v1.1.1f while CLN requires ≥ v3.0. --- Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Makefile b/Makefile index 32293fd73403..32e95d48327b 100644 --- a/Makefile +++ b/Makefile @@ -392,7 +392,12 @@ include cln-grpc/Makefile endif include plugins/Makefile include tests/plugins/Makefile + +# Only include fuzz tests if OpenSSL >= 3.0, will be disabled on ubuntu focal +OPENSSL_VERSION := $(shell openssl version | sed -n 's/OpenSSL \([0-9]\+\)\..*/\1/p') +ifneq ($(shell test $(OPENSSL_VERSION) -ge 3 && echo yes),) include tests/fuzz/Makefile +endif ifneq ($V,1) MSGGEN_ARGS := -s From d02fb3b3645020e74e2a6d4d43efe97251b28499 Mon Sep 17 00:00:00 2001 From: ShahanaFarooqui Date: Tue, 28 Oct 2025 20:00:55 -0700 Subject: [PATCH 2/2] docker: install lowdown and libsodium-dev for reproducible builds After external lowdown and libsodium-dev removal with PR #8536, we need to explicitly install them in Dockerfiles. --- contrib/docker/Dockerfile.builder.fedora | 12 +++++- contrib/reprobuild/Dockerfile.focal | 42 +++++++++++++-------- contrib/reprobuild/Dockerfile.jammy | 47 +++++++++++++++--------- contrib/reprobuild/Dockerfile.noble | 2 + tools/repro-build.sh | 1 + 5 files changed, 69 insertions(+), 35 deletions(-) diff --git a/contrib/docker/Dockerfile.builder.fedora b/contrib/docker/Dockerfile.builder.fedora index 617467c65d7a..7d4b903fd02f 100644 --- a/contrib/docker/Dockerfile.builder.fedora +++ b/contrib/docker/Dockerfile.builder.fedora @@ -20,7 +20,17 @@ RUN dnf update -y && \ jq \ xz \ zlib-devel \ - cargo && \ + cargo \ + libsodium-devel && \ + wget https://github.com/kristapsdz/lowdown/archive/refs/tags/VERSION_1_0_2.tar.gz && \ + tar -xzf VERSION_1_0_2.tar.gz && \ + cd lowdown-VERSION_1_0_2 && \ + ./configure && \ + make && \ + make install && \ + ldconfig && \ + cd /tmp && \ + rm -rf VERSION_1_0_2.tar.gz lowdown-VERSION_1_0_2 && \ dnf clean all RUN wget https://storage.googleapis.com/c-lightning-tests/bitcoind/bitcoin-${BITCOIN_VERSION}-x86_64-linux-gnu.tar.gz \ diff --git a/contrib/reprobuild/Dockerfile.focal b/contrib/reprobuild/Dockerfile.focal index 4d960aa6906b..7c716e766677 100644 --- a/contrib/reprobuild/Dockerfile.focal +++ b/contrib/reprobuild/Dockerfile.focal @@ -11,22 +11,32 @@ RUN sed -i '/updates/d' /etc/apt/sources.list && \ sed -i '/security/d' /etc/apt/sources.list RUN apt-get update \ - && apt-get install -y --no-install-recommends \ - autoconf \ - build-essential \ - ca-certificates \ - file \ - gettext \ - git \ - libpq-dev \ - libsodium23 \ - libtool \ - m4 \ - sudo \ - unzip \ - wget \ - git \ - zip + && apt-get install -y --no-install-recommends \ + autoconf \ + build-essential \ + ca-certificates \ + file \ + gettext \ + git \ + libpq-dev \ + libsodium23 \ + libsodium-dev \ + libtool \ + m4 \ + sudo \ + unzip \ + wget \ + zip \ + && cd /tmp \ + && wget https://github.com/kristapsdz/lowdown/archive/refs/tags/VERSION_1_0_2.tar.gz \ + && tar -xzf VERSION_1_0_2.tar.gz \ + && cd lowdown-VERSION_1_0_2 \ + && ./configure \ + && make \ + && make install \ + && ldconfig \ + && cd / \ + && rm -rf /tmp/VERSION_1_0_2.tar.gz /tmp/lowdown-VERSION_1_0_2 # Ensure correct ownership RUN chown root:root /etc/sudoers diff --git a/contrib/reprobuild/Dockerfile.jammy b/contrib/reprobuild/Dockerfile.jammy index 3f156a6f6658..dd97604921db 100644 --- a/contrib/reprobuild/Dockerfile.jammy +++ b/contrib/reprobuild/Dockerfile.jammy @@ -10,24 +10,35 @@ ENV PROTOC_VERSION=29.4 RUN sed -i '/updates/d' /etc/apt/sources.list && \ sed -i '/security/d' /etc/apt/sources.list -RUN apt-get update \ - && apt-get install -y --no-install-recommends \ - autoconf \ - build-essential \ - ca-certificates \ - file \ - gettext \ - git \ - libsqlite3-dev \ - libpq-dev \ - libsodium23 \ - libtool \ - m4 \ - sudo \ - unzip \ - wget \ - jq \ - zip +RUN apt-get update && \ + apt-get install -y --no-install-recommends \ + autoconf \ + build-essential \ + ca-certificates \ + file \ + gettext \ + git \ + libsqlite3-dev \ + libpq-dev \ + libsodium23 \ + libsodium-dev \ + libtool \ + m4 \ + sudo \ + unzip \ + wget \ + jq \ + zip \ + && cd /tmp \ + && wget https://github.com/kristapsdz/lowdown/archive/refs/tags/VERSION_1_0_2.tar.gz \ + && tar -xzf VERSION_1_0_2.tar.gz \ + && cd lowdown-VERSION_1_0_2 \ + && ./configure \ + && make \ + && make install \ + && ldconfig \ + && cd / \ + && rm -rf /tmp/VERSION_1_0_2.tar.gz /tmp/lowdown-VERSION_1_0_2 # Ensure correct ownership RUN chown root:root /etc/sudoers diff --git a/contrib/reprobuild/Dockerfile.noble b/contrib/reprobuild/Dockerfile.noble index a630596bd765..8752d231811e 100644 --- a/contrib/reprobuild/Dockerfile.noble +++ b/contrib/reprobuild/Dockerfile.noble @@ -22,6 +22,8 @@ RUN apt-get update \ libsqlite3-dev \ libpq-dev \ libsodium23 \ + libsodium-dev \ + lowdown \ libtool \ m4 \ sudo \ diff --git a/tools/repro-build.sh b/tools/repro-build.sh index 02cdddd19610..eaebe8733c1d 100755 --- a/tools/repro-build.sh +++ b/tools/repro-build.sh @@ -118,6 +118,7 @@ adae5a301c7899c1bce8ae26b5423716a47e516df25c09d6d536607bc34853bc /var/cache/apt d8b8653388e676a3ae2fcf565c2b1a42a01a1104062317f641e8d24f0eaff9c3 /var/cache/apt/archives/libpq-dev_14.2-1ubuntu1_amd64.deb 542dcee1409c74d03ecdd4ca4a0cfd467e5d2804d9985b58e39d3c5889a409e3 /var/cache/apt/archives/libpq5_14.2-1ubuntu1_amd64.deb 885ee09c37d0e37ef6042e8cb4a22ccbab92101f21ab0c8f51ae961e4484407c /var/cache/apt/archives/libsodium23_1.0.18-1build2_amd64.deb +09584c8ab2f840bf3db4a5763f6e4b450688aa8879acd4c8f4c1942375b9ca57 /var/cache/apt/archives/libsodium-dev_1.0.18-1build2_amd64.deb 000a1d5c0df0373c75fadbfea604afb6b1325bf866a3ce637ae0138abe6d556d /var/cache/apt/archives/libsqlite3-0_3.37.2-2_amd64.deb 1b2a93020593c9e94a25f750ce442da5a6e8ff48a20f52cec92dfc3fa35336d8 /var/cache/apt/archives/linux-libc-dev_5.15.0-25.25_amd64.deb 572a544d2c18bf49d25c465720c570cd8e6e38731386ac9c0a7f29bed2486f3e /var/cache/apt/archives/m4_1.4.18-5ubuntu2_amd64.deb