Skip to content

Commit

Permalink
Restore most OpenSSF hardening for abseil-cpp-dependent packages
Browse files Browse the repository at this point in the history
We only need to override -fno-delete-null-pointer-checks
for these packages to build.

Add explicit build-deps on openssf-compiler-options so that CI
orders the builds correctly. Also fix some incorrect issue links.

Signed-off-by: dann frazier <[email protected]>
  • Loading branch information
dannf committed Jan 5, 2025
1 parent 73fe0a3 commit e1ecd09
Show file tree
Hide file tree
Showing 10 changed files with 50 additions and 34 deletions.
8 changes: 5 additions & 3 deletions falco-no-driver.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: falco-no-driver
name: falco-no-driver # On update, please check if -fdelete-null-pointer-checks is still required
version: 0.39.2
epoch: 0
epoch: 1
description: Cloud Native Runtime Security
copyright:
- license: Apache-2.0
Expand Down Expand Up @@ -31,14 +31,15 @@ environment:
- libelf-static
- libtool
- mpc-dev
- openssf-compiler-options
- openssl-dev
- pkgconf
- protobuf-dev
- yaml-cpp-dev
- zlib-dev
environment:
# See https://github.com/wolfi-dev/os/issues/34075
GCC_SPEC_FILE: "/dev/null"
CMAKE_CXX_FLAGS: -fdelete-null-pointer-checks

pipeline:
- uses: git-checkout
Expand All @@ -60,6 +61,7 @@ pipeline:
mkdir build && cd build
cmake \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_CXX_FLAGS="$CMAKE_CXX_FLAGS" \
-DUSE_BUNDLED_DEPS=On \
-DFALCO_ETC_DIR=/etc/falco \
-DBUILD_FALCO_MODERN_BPF=ON \
Expand Down
12 changes: 7 additions & 5 deletions grpc-1.66.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: grpc-1.66
name: grpc-1.66 # On update, please check if -fdelete-null-pointer-checks is still required
version: 1.66.2
epoch: 3
epoch: 4
description: The C based gRPC
copyright:
- license: Apache-2.0 AND BSD-3-Clause AND MIT
Expand Down Expand Up @@ -38,6 +38,7 @@ environment:
- libsystemd
- libtool
- linux-headers
- openssf-compiler-options
- openssl-dev
- protobuf-dev
- py3-setuptools
Expand All @@ -52,8 +53,8 @@ environment:
- yaml-dev
- zlib-dev
environment:
# https://github.com/wolfi-dev/os/issues/34568
GCC_SPEC_FILE: /dev/null
# https://github.com/wolfi-dev/os/issues/34075
CMAKE_CXX_FLAGS: -fdelete-null-pointer-checks

pipeline:
- uses: git-checkout
Expand All @@ -71,7 +72,8 @@ pipeline:
cmake -B _build -G Ninja \
-DCMAKE_BUILD_TYPE=None \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_CXX_STANDARD=17 \
-DCMAKE_CXX_FLAGS="$CMAKE_CXX_FLAGS" \
-DCMAKE_CXX_STANDARD=17 \
-DBUILD_SHARED_LIBS=True \
-DgRPC_INSTALL=ON \
-DgRPC_CARES_PROVIDER=package \
Expand Down
10 changes: 6 additions & 4 deletions grpc-1.67.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: grpc-1.67
name: grpc-1.67 # On update, please check if -fdelete-null-pointer-checks is still required
version: 1.67.1
epoch: 4
epoch: 5
description: The C based gRPC
copyright:
- license: Apache-2.0 AND BSD-3-Clause AND MIT
Expand Down Expand Up @@ -49,6 +49,7 @@ environment:
- libsystemd
- libtool
- linux-headers
- openssf-compiler-options
- openssl-dev
- protobuf-dev
- py3-supported-build-base
Expand All @@ -64,8 +65,8 @@ environment:
- yaml-dev
- zlib-dev
environment:
# https://github.com/wolfi-dev/os/issues/34568
GCC_SPEC_FILE: /dev/null
# https://github.com/wolfi-dev/os/issues/34075
CMAKE_CXX_FLAGS: -fdelete-null-pointer-checks

pipeline:
- uses: git-checkout
Expand All @@ -83,6 +84,7 @@ pipeline:
cmake -B _build -G Ninja \
-DCMAKE_BUILD_TYPE=None \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_CXX_FLAGS="$CMAKE_CXX_FLAGS" \
-DCMAKE_CXX_STANDARD=17 \
-DBUILD_SHARED_LIBS=True \
-DgRPC_INSTALL=ON \
Expand Down
10 changes: 6 additions & 4 deletions grpc-1.68.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: grpc-1.68
name: grpc-1.68 # On update, please check if -fdelete-null-pointer-checks is still required
version: 1.68.2
epoch: 2
epoch: 3
description: The C based gRPC
copyright:
- license: Apache-2.0 AND BSD-3-Clause AND MIT
Expand Down Expand Up @@ -49,6 +49,7 @@ environment:
- libsystemd
- libtool
- linux-headers
- openssf-compiler-options
- openssl-dev
- protobuf-dev
- py3-supported-build-base
Expand All @@ -64,8 +65,8 @@ environment:
- yaml-dev
- zlib-dev
environment:
# https://github.com/wolfi-dev/os/issues/34568
GCC_SPEC_FILE: /dev/null
# https://github.com/wolfi-dev/os/issues/34075
CMAKE_CXX_FLAGS: -fdelete-null-pointer-checks

pipeline:
- uses: git-checkout
Expand All @@ -83,6 +84,7 @@ pipeline:
cmake -B _build -G Ninja \
-DCMAKE_BUILD_TYPE=None \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_CXX_FLAGS="$CMAKE_CXX_FLAGS" \
-DCMAKE_CXX_STANDARD=17 \
-DBUILD_SHARED_LIBS=True \
-DgRPC_INSTALL=ON \
Expand Down
7 changes: 4 additions & 3 deletions libreoffice-24.8.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: libreoffice-24.8
name: libreoffice-24.8 # On update, please check if -fdelete-null-pointer-checks is still required
version: 24.8.4.2
epoch: 0
epoch: 1
description:
# https://www.libreoffice.org/about-us/licenses
copyright:
Expand Down Expand Up @@ -81,6 +81,7 @@ environment:
- nasm
- openjdk-${{vars.java-version}}
- openjdk-${{vars.java-version}}-default-jvm
- openssf-compiler-options
- openssl-dev
- orc-dev
- pango-dev
Expand All @@ -93,7 +94,7 @@ environment:
- zip
environment:
# https://github.com/wolfi-dev/os/issues/34075
GCC_SPEC_FILE: /dev/null
CXXFLAGS: -fdelete-null-pointer-checks
JAVA_HOME: ${{vars.java-home}}

pipeline:
Expand Down
8 changes: 5 additions & 3 deletions nodejs-22.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: nodejs-22
version: 22.12.0
epoch: 1
version: 22.12.0 # On update, please check if -fdelete-null-pointer-checks is still required
epoch: 2
description: "JavaScript runtime built on V8 engine"
dependencies:
provides:
Expand All @@ -27,6 +27,7 @@ environment:
- libuv-dev
- linux-headers
- nghttp2-dev
- openssf-compiler-options
- openssl-dev
- py${{vars.py-version}}-jinja2
- py${{vars.py-version}}-setuptools
Expand All @@ -35,7 +36,8 @@ environment:
- wolfi-base
- zlib-dev
environment:
GCC_SPEC_FILE: /dev/null # https://github.com/wolfi-dev/os/issues/34075
# https://github.com/wolfi-dev/os/issues/34075
CXXFLAGS: -fdelete-null-pointer-checks

pipeline:
- uses: git-checkout
Expand Down
8 changes: 5 additions & 3 deletions nodejs-23.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: nodejs-23
version: 23.5.0
epoch: 1
version: 23.5.0 # On update, please check if -fdelete-null-pointer-checks is still required
epoch: 2
description: "JavaScript runtime built on V8 engine"
dependencies:
provides:
Expand All @@ -27,6 +27,7 @@ environment:
- libuv-dev
- linux-headers
- nghttp2-dev
- openssf-compiler-options
- openssl-dev
- py${{vars.py-version}}-jinja2
- py${{vars.py-version}}-setuptools
Expand All @@ -35,7 +36,8 @@ environment:
- wolfi-base
- zlib-dev
environment:
GCC_SPEC_FILE: /dev/null # https://github.com/wolfi-dev/os/issues/34075
# https://github.com/wolfi-dev/os/issues/34075
CXXFLAGS: -fdelete-null-pointer-checks

pipeline:
- uses: git-checkout
Expand Down
7 changes: 4 additions & 3 deletions protobuf-c.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: protobuf-c
version: 1.5.0
epoch: 12
version: 1.5.0 # On update, please check if -fdelete-null-pointer-checks is still required
epoch: 13
description: Protocol Buffers implementation in C
copyright:
- license: BSD-2-Clause
Expand All @@ -16,10 +16,11 @@ environment:
- busybox
- ca-certificates-bundle
- libtool
- openssf-compiler-options
- protobuf-dev
environment:
# https://github.com/wolfi-dev/os/issues/34075
GCC_SPEC_FILE: /dev/null
CXXFLAGS: -fdelete-null-pointer-checks

pipeline:
- uses: git-checkout
Expand Down
8 changes: 5 additions & 3 deletions protobuf.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: protobuf
version: 3.29.2
epoch: 0
version: 3.29.2 # On update, please check if -fdelete-null-pointer-checks is still required
epoch: 1
description: Library for extensible, efficient structure packing
copyright:
- license: BSD-3-Clause
Expand All @@ -26,11 +26,12 @@ environment:
- cmake
- git
- libtool
- openssf-compiler-options
- samurai
- zlib-dev
environment:
# https://github.com/wolfi-dev/os/issues/34075
GCC_SPEC_FILE: /dev/null
CMAKE_CXX_FLAGS: -fdelete-null-pointer-checks

pipeline:
- uses: git-checkout
Expand All @@ -49,6 +50,7 @@ pipeline:
cmake -B build -G Ninja \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DCMAKE_CXX_FLAGS="$CMAKE_CXX_FLAGS" \
-DBUILD_SHARED_LIBS=True \
-DCMAKE_BUILD_TYPE=Release \
-Dprotobuf_ABSL_PROVIDER=package \
Expand Down
6 changes: 3 additions & 3 deletions py3-grpcio-tools.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: py3-grpcio-tools
version: 1.69.0
epoch: 0
version: 1.69.0 # On update, please check if -fdelete-null-pointer-checks is still required
epoch: 1
description: Protobuf code generator for gRPC
copyright:
- license: Apache-2.0
Expand Down Expand Up @@ -36,7 +36,7 @@ environment:
- wolfi-base
environment:
# https://github.com/wolfi-dev/os/issues/34075
GCC_SPEC_FILE: /dev/null
CXXFLAGS: -fdelete-null-pointer-checks
GRPC_PYTHON_BUILD_WITH_CYTHON: 1

pipeline:
Expand Down

0 comments on commit e1ecd09

Please sign in to comment.