Skip to content

Commit f836853

Browse files
authored
Fix CI fuzz job (#12835)
* Disable BUILD_TESTING option in build_boringssl_h3_tools.sh Disable testing during the build process for both shared and static libraries. * Add workflow_dispatch trigger to CIFuzz workflow * Update cifuzz.yml * Update cifuzz.yml * Pin libc-ares-dev package version to 1.16.0 * Update oss-fuzz.sh * Update oss-fuzz.sh * Update Python version in oss-fuzz.sh script * Update oss-fuzz.sh * Update CI to use Ubuntu 24.04 for fuzzing * Update CIFuzz workflow actions to latest version Updated CIFuzz workflow to use the latest actions from Google OSS-Fuzz. * Update BoringSSL checkout and CMake configuration Updated the BoringSSL checkout commit and modified CMake flags for building shared and static libraries. * Update Go version to 1.24.12 * Create symbolic links for libswoc libraries Add symbolic links for libswoc shared libraries * Update symbolic links for libswoc in oss-fuzz.sh * Fix symlink creation for libswoc in oss-fuzz.sh * Fix symlink creation for libswoc in oss-fuzz.sh Change directory to $OUT/lib before creating symlinks for libswoc.
1 parent 2747c99 commit f836853

3 files changed

Lines changed: 17 additions & 6 deletions

File tree

.github/workflows/cifuzz.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ on:
55
permissions: {}
66
jobs:
77
Fuzzing:
8-
runs-on: ubuntu-latest
8+
runs-on: ubuntu-24.04
99
permissions:
1010
security-events: write
1111
steps:

tests/fuzzing/oss-fuzz.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ unset CXXFLAGS
2626
unset RUSTFLAGS
2727
export AFL_NOOPT=1
2828

29-
apt-get install -y libev-dev libjemalloc-dev python2-dev libxml2-dev libpython2-dev libc-ares-dev libsystemd-dev libevent-dev libjansson-dev zlib1g-dev sudo autoconf libtool pkg-config
29+
apt-get install -y libev-dev libjemalloc-dev python3-dev libxml2-dev libpython3-dev libpsl-dev libc-ares-dev libsystemd-dev libevent-dev libjansson-dev zlib1g-dev sudo autoconf libtool pkg-config
3030
curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain=nightly
3131
export PATH="/root/.cargo/bin:${PATH}"
3232

@@ -63,6 +63,11 @@ cp /opt/h3-tools-boringssl/boringssl/lib/libssl.so $OUT/lib/
6363
cp /opt/h3-tools-boringssl/boringssl/lib/libcrypto.so $OUT/lib/
6464
cp /opt/h3-tools-boringssl/quiche/lib/libquiche.so $OUT/lib/
6565
cp /opt/h3-tools-boringssl/quiche/lib/libquiche.so $OUT/lib/libquiche.so.0
66+
67+
cd $OUT/lib
68+
ln -sf libswoc.so.1.5.15 libswoc.so.1
69+
ln -sf libswoc.so.1.5.15 libswoc.so
70+
6671
export LD_LIBRARY_PATH=$OUT/lib/
6772
ldconfig
6873

tools/build_boringssl_h3_tools.sh

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ else
112112
OS="linux"
113113
fi
114114

115-
go_version=1.24.1
115+
go_version=1.24.12
116116
wget https://go.dev/dl/go${go_version}.${OS}-${ARCH}.tar.gz
117117
rm -rf ${BASE}/go && tar -C ${BASE} -xf go${go_version}.${OS}-${ARCH}.tar.gz
118118
rm go${go_version}.${OS}-${ARCH}.tar.gz
@@ -121,7 +121,7 @@ GO_BINARY_PATH=${BASE}/go/bin/go
121121
if [ ! -d boringssl ]; then
122122
git clone https://boringssl.googlesource.com/boringssl
123123
cd boringssl
124-
git checkout 45b2464158379f48cec6e35a1ef503ddea1511a6
124+
git checkout 02bc0949e5cac0e1ee82c6f365f5a6c3cfd0cfa9
125125
cd ..
126126
fi
127127
cd boringssl
@@ -146,18 +146,24 @@ cmake \
146146
-DGO_EXECUTABLE=${GO_BINARY_PATH} \
147147
-DCMAKE_INSTALL_PREFIX=${BASE}/boringssl \
148148
-DCMAKE_BUILD_TYPE=Release \
149-
-DCMAKE_CXX_FLAGS='-Wno-error=ignored-attributes -UBORINGSSL_HAVE_LIBUNWIND' \
149+
-DCMAKE_CXX_FLAGS='-Wno-error=character-conversion -Wno-error=ignored-attributes -UBORINGSSL_HAVE_LIBUNWIND' \
150150
-DCMAKE_C_FLAGS=${BSSL_C_FLAGS} \
151151
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
152+
-DBUILD_TESTING=0 \
153+
-DCMAKE_THREAD_LIBS_INIT="-lpthread" \
154+
-DTHREADS_PREFER_PTHREAD_FLAG=ON \
152155
-DBUILD_SHARED_LIBS=1
153156
cmake \
154157
-B build-static \
155158
-DGO_EXECUTABLE=${GO_BINARY_PATH} \
156159
-DCMAKE_INSTALL_PREFIX=${BASE}/boringssl \
157160
-DCMAKE_BUILD_TYPE=Release \
158-
-DCMAKE_CXX_FLAGS='-Wno-error=ignored-attributes -UBORINGSSL_HAVE_LIBUNWIND' \
161+
-DCMAKE_CXX_FLAGS='-Wno-error=character-conversion -Wno-error=ignored-attributes -UBORINGSSL_HAVE_LIBUNWIND' \
159162
-DCMAKE_C_FLAGS="${BSSL_C_FLAGS}" \
160163
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
164+
-DBUILD_TESTING=0 \
165+
-DCMAKE_THREAD_LIBS_INIT="-lpthread" \
166+
-DTHREADS_PREFER_PTHREAD_FLAG=ON \
161167
-DBUILD_SHARED_LIBS=0
162168
cmake --build build-shared -j ${num_threads}
163169
cmake --build build-static -j ${num_threads}

0 commit comments

Comments
 (0)