Skip to content

tests: failing regression tests for the open audit findings - #110

Draft
perbu wants to merge 1 commit into
masterfrom
audit-regression-tests
Draft

tests: failing regression tests for the open audit findings#110
perbu wants to merge 1 commit into
masterfrom
audit-regression-tests

Conversation

@perbu

@perbu perbu commented Aug 2, 2026

Copy link
Copy Markdown
Collaborator

Draft on purpose — this branch is red, and should stay red until the bugs are fixed.

Every test here asserts the correct behaviour, so each fails on master and passes once the corresponding issue is closed. The point is to give #99#104 something concrete to point at, and to make "is it actually fixed" a ctest run rather than a judgement call.

file tests issue
syscalls.cpp dup2 onto a fresh vfd; poll with >256 valid fds; futex with an unimplemented op #99, #102, #101
reset.cpp signal handlers, cwd and brk across reset_to #103
remote.cpp remote call with a guest-zeroed FSBASE #104
elfmal.cpp new file, five malformed-ELF cases #100

elfmal.cpp is registered in CMakeLists.txt. Four of its five cases crash the process rather than failing an assertion, so run them individually by name filter — and note that a name filter also skips the Initialize KVM case that calls Machine::init(), so pass it too:

./elfmal "Initialize KVM,resolve must not trust snprintf would-be length (cand1)"

The tests for #94#97 are not here; they are in #108 alongside their fixes, so that branch stays green.

Two failures on this branch are not from these tests and also fail on pristine master: the reset suite's "Execute function in VM (crash recovery)" case, and two cases in tegridy. Worth a look independently of this audit.

🤖 Generated with Claude Code

Each test asserts the correct behaviour, so all of them fail on master and
pass once the corresponding bug is fixed. Filed as a draft so the issues
have something concrete to point at; not for merging before the fixes.

  syscalls.cpp  dup2 onto a fresh vfd, poll with >256 valid fds, futex with
                an unimplemented op                          (#99 #102 #101)
  reset.cpp     signal handlers, cwd and brk across reset_to        (#103)
  remote.cpp    remote call with a guest-zeroed FSBASE              (#104)
  elfmal.cpp    new file: five malformed-ELF cases covering resolve(),
                section_by_name(), resolve_symbol() and is_dynamic_elf()
                                                                    (#100)

elfmal.cpp is registered in CMakeLists.txt. Four of its five cases crash
the process rather than failing an assertion, so run them individually by
name filter -- and note that a name filter skips the "Initialize KVM" case
that calls Machine::init(), so pass it as well:

  ./elfmal "Initialize KVM,resolve must not trust*"

Known-unrelated failures on master, present before these tests: the reset
suite's "Execute function in VM (crash recovery)" case and two cases in
the tegridy suite.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant