Repository navigation
Refactor NVX confinement into focused modules - #11706
Merged
Merged
Conversation
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
lpcox
marked this pull request as ready for review
November 16, 2026 21:49
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Eight test-only parser exports lack the established internal and audit-suppression markers, potentially causing unused-export audit noise.
1 open issue
What changed in this PR
Refactors NVX host confinement into focused modules, separating launch construction from security verification while preserving existing imports and behavior.
Changes:
- Extracts launch-command construction, cgroup limits, live verification, parsers, and shared assertions.
- Retains the existing public functions and types through a compatibility facade.
- Adds regression coverage for verifier ordering, parser inputs, and malformed identities.
| File | Description |
|---|---|
src/nvx/confinement.ts |
Re-exports the existing public API from the extracted modules. |
src/nvx/confinement.test.ts |
Adds verifier-ordering and UID/GID rejection coverage. |
src/nvx/confinement-verify.ts |
Houses live process, namespace, and cgroup verification with /proc parsers. |
src/nvx/confinement-verify.test.ts |
Directly tests valid and malformed parser inputs. |
src/nvx/confinement-launch-command.ts |
Houses constrained launch construction and cgroup-limit computation. |
src/nvx/confinement-assertions.ts |
Centralizes path, name, integer, and identity assertions. |
Review effort: Max (adaptive)
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
Contributor
|
✅ Copilot review passed with no inline comments. @lpcox Add the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

NVX confinement combines launch construction, cgroup limits, live process verification, and validation helpers. This split isolates security-critical verification while preserving behavior and existing imports.
/procparsers, and path/identity assertions.