Skip to content

Commit

Permalink
Add fix to kernel mmap rnd bit to github action script (#492)
Browse files Browse the repository at this point in the history
* Until the below issue is fixed:
actions/runner-images#9524
  • Loading branch information
greensky00 authored Mar 20, 2024
1 parent bc1db87 commit 2f3fd1f
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ env:
BUILD_TYPE: Debug

permissions:
# Setting token permissions to read-only follows the principle of least privilege. This
# is important because attackers may use a compromised token with write access to push
# Setting token permissions to read-only follows the principle of least privilege. This
# is important because attackers may use a compromised token with write access to push
# malicious code into the project.
# See https://github.com/ossf/scorecard/blob/e42af756609b2cde6d757fd45ea05ddf0016ff62/docs/checks.md#token-permissions
contents: read
Expand All @@ -33,6 +33,12 @@ jobs:
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # pin@v2

- name: Fix kernel mmap rnd bits
# Asan in llvm 14 provided in ubuntu 22.04 is incompatible with
# high-entropy ASLR in much newer kernels that GitHub runners are
# using leading to random crashes: https://reviews.llvm.org/D148280
run: sudo sysctl vm.mmap_rnd_bits=28

- name: Dependency Install
shell: bash
# Some projects don't allow in-source building, so create a separate build directory
Expand All @@ -41,7 +47,7 @@ jobs:

- name: Build and Test
shell: bash
# Execute tests defined by the CMake configuration.
# Execute tests defined by the CMake configuration.
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
run: ./github_action_build.sh

Expand Down

0 comments on commit 2f3fd1f

Please sign in to comment.