Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
01a11c9
feat(ami): enforce file policy on images
brainrake Nov 23, 2026
b136c37
refactor(ami): drop standalone file policy check
brainrake Nov 25, 2026
c09d890
feat(supascan): add filesystem discovery check
brainrake Nov 24, 2026
9803c2f
feat(supascan): support include in discovery policy
brainrake Nov 25, 2026
4919a39
Merge remote-tracking branch 'origin/develop' into tmp-pr2709
brainrake Nov 25, 2026
1bc6ae4
refactor(supascan): slim discovery check
brainrake Nov 25, 2026
ba4f634
refactor(audit-specs): share identical baselines across builds
brainrake Nov 25, 2026
40ae2a0
feat(supascan): scope discovery exceptions to rules
brainrake Nov 25, 2026
2010e09
refactor(supascan): trim discovery code
brainrake Nov 25, 2026
f363673
docs(supascan): list discovery rules
brainrake Nov 25, 2026
ca58764
feat(supascan): re-run discover under sudo
brainrake Nov 25, 2026
5e187cd
refactor(supascan): shorten comments
brainrake Nov 25, 2026
ac308bb
fix(supascan): skip setuid assertion when the bit is not kept
brainrake Nov 25, 2026
bf81469
refactor(supascan): fold setuid list into exceptions
brainrake Nov 25, 2026
2748042
ci(ansible): print supascan output on failure
brainrake Nov 26, 2026
a3fd4d0
fix(supascan): add discovery exceptions seen on AMI and qemu
brainrake Nov 26, 2026
213dab2
fix(supascan): narrow discovery roots and categorize exceptions
brainrake Nov 26, 2026
d645d7b
ci(docker): check file policy on docker images
brainrake Nov 26, 2026
d25cabf
ci(docker): fix file policy extraction root and unix_chkpwd
brainrake Nov 26, 2026
085df0c
chore(supascan): mark adminapi-written config exceptions as required
brainrake Nov 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .github/workflows/docker-image-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,17 @@ jobs:
echo "=== Running tests for ${{ matrix.name }} ==="
nix run .#docker-image-test -- --no-build --target ${{ matrix.target }} ${{ matrix.dockerfile }}

- name: Check file policy
run: |
echo "=== File policy check for ${{ matrix.name }} ==="
root=$(mktemp -d)
sudo chown root:root "$root"
container=$(docker create "pg-docker-test:${{ matrix.name }}")
trap 'docker rm "$container" >/dev/null; sudo rm -rf "$root"' EXIT
docker export "$container" | sudo tar -xpf - -C "$root"
supascan=$(nix build .#supascan --no-link --print-out-paths)
sudo "$supascan/bin/supascan" discover audit-specs/docker/file-discovery.yml --root "$root"

- name: Show container logs on failure
if: failure()
run: |
Expand Down
12 changes: 12 additions & 0 deletions ansible/playbook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,18 @@
nix shell {{ nix_store_paths['supascan'] }} --command
/tmp/ansible-playbook/ansible/files/supascan_ami.sh
/tmp/ansible-playbook/audit-specs/baselines/$baseline
register: supascan
failed_when: false

- name: Print supascan output
when: stage2 and supascan.rc != 0
debug:
msg: "{{ supascan.stdout_lines + supascan.stderr_lines }}"

- name: Fail on supascan errors
when: stage2 and supascan.rc != 0
fail:
msg: supascan validation failed

- name: Tune Swap
when: stage2
Expand Down
97 changes: 0 additions & 97 deletions audit-specs/baselines/ami-build-arm64/files-postgres-config.yml

This file was deleted.

19 changes: 0 additions & 19 deletions audit-specs/baselines/ami-build-arm64/files-postgres-data.yml

This file was deleted.

77 changes: 0 additions & 77 deletions audit-specs/baselines/ami-build-arm64/files-security.yml

This file was deleted.

42 changes: 0 additions & 42 deletions audit-specs/baselines/ami-build-arm64/files-ssl.yml

This file was deleted.

11 changes: 0 additions & 11 deletions audit-specs/baselines/ami-build-arm64/kernel-param.yml

This file was deleted.

Loading
Loading