Skip to content

Commit

Permalink
Re-enable CodeQL for TTY Resizer (#57)
Browse files Browse the repository at this point in the history
* Re-enable CodeQL for TTY Resizer

* Generate vmlinux.h before building TTY Resizer
  • Loading branch information
YaSuenag authored Oct 14, 2024
1 parent 94e3560 commit 3e88fbd
Showing 1 changed file with 35 additions and 33 deletions.
68 changes: 35 additions & 33 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,38 +61,40 @@ jobs:
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3

#

# analyze-tty-resizer should be activated when Linux GH runner has v6.0 kernel or later.
# https://github.com/torvalds/linux/commit/fcb14cb1bdacec5b4374fe161e83fb8208164a85
#
# analyze-tty-resizer:
# runs-on: ubuntu-latest
# permissions:
# actions: read
# contents: read
# security-events: write
#
# strategy:
# fail-fast: false
#
# steps:
# - name: Setup
# run: |
# sudo apt-get update
# sudo apt-get install -y libbpf-dev linux-tools-common
#
# - name: Checkout repository
# uses: actions/[email protected]
#
# # Initializes the CodeQL tools for scanning.
# - name: Initialize CodeQL
# uses: github/codeql-action/init@v3
# with:
# languages: cpp
# queries: security-extended,security-and-quality
#
# - name: Build TTY Resizer
# run: make -C tty-resizer
#
# - name: Perform CodeQL Analysis
# uses: github/codeql-action/analyze@v3
analyze-tty-resizer:
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false

steps:
- name: Setup
run: |
sudo apt-get update
sudo apt-get install -y libbpf-dev linux-tools-common
- name: Checkout repository
uses: actions/[email protected]

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: cpp
queries: security-extended,security-and-quality

- name: Build TTY Resizer
working-directory: tty-resizer
run: |
bpftool btf dump file /sys/kernel/btf/vmlinux format c > vmlinux.h
make
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3

0 comments on commit 3e88fbd

Please sign in to comment.