fix(worker): security audit of R0 — no core dumps, tkill/tgkill limited to SIGABRT on self, mmap without PROT_EXEC, Broken outcome for a broken child environment, frame vs canvas check, unsafe denied with local allows, sandbox tests and derivation on the release profile (syscall marker); wasm proof exports behind a feature; ci: release-images hardened (typed input via env, advisories gate, ephemeral builder, env secrets + logout, ref gate, pinned checkout)

This commit is contained in:
bchanot committed 2026-10-13 00:18:53 +02:00
1 parent 9d3e0294e2
commit 11813f5560
14 files changed
+293 -58

No files matched your search

+4 -3
View File
@@ -19,13 +19,14 @@ RUN --mount=type=cache,id=faunosteo_cargo_registry_musl,target=/usr/local/cargo/
cargo build -p faunosteo-worker --release --locked \
&& cp target/release/faunosteo-worker /faunosteo-worker
# The tests run against the musl binary that ships, inside the default Docker seccomp
# profile (the inner filter is allowed by it). strace serves the allowlist derivation.
# The tests and the derivation run on the release profile (LTO, panic = abort) plus the
# test-hooks feature, inside the default Docker seccomp profile (the inner filter is allowed
# by it): the binary under test differs from the shipped one by the feature-gated hooks only.
FROM base AS test
RUN apk add --no-cache strace
RUN --mount=type=cache,id=faunosteo_cargo_registry_musl,target=/usr/local/cargo/registry \
--mount=type=cache,id=faunosteo_target_musl,target=/w/target \
cargo test -p faunosteo-worker --features test-hooks --locked -- --test-threads=4
cargo test -p faunosteo-worker --release --features test-hooks --locked -- --test-threads=4
RUN --mount=type=cache,id=faunosteo_cargo_registry_musl,target=/usr/local/cargo/registry \
--mount=type=cache,id=faunosteo_target_musl,target=/w/target \
sh crates/worker/scripts/derive-seccomp.sh