Only the latest release receives fixes. A security fix merges to main and
ships in the next release; when it cannot wait, maintainers cut an out-of-cycle
release from main. Older releases get no fixes, so upgrade to the latest
release. The support policy describes the
release life cycle.
If you discover a security vulnerability in this project, please report it responsibly.
Please do NOT open a public GitHub issue for security vulnerabilities.
Instead, please report them via GitHub's private vulnerability reporting:
- Go to the Security Advisories page
- Click "Report a vulnerability"
- Fill in the details
Alternatively, email psirt@nvidia.com with:
- Description of the vulnerability
- Steps to reproduce
- Affected versions
- Any potential impact
- Acknowledgment: within 3 business days
- Initial assessment: within 10 business days
- Fix timeline: depends on severity, typically within 30-90 days
This project provides mock GPU infrastructure for testing. It does not handle real GPU workloads or sensitive data. However, we take security of our CI/CD pipelines, container images, and supply chain seriously.
Areas of particular interest:
- Container image vulnerabilities
- GitHub Actions workflow security
- Supply chain integrity (dependencies, build process)
- Helm chart security (RBAC, privileges)
Mokka is a test double for CI and test clusters, not production.
When enabled, the control-plane pod mounts a dedicated ServiceAccount token
for Kubernetes API access. Its ClusterRole grants Node reads and patches and
the Mokka resource permissions needed for reconciliation; its namespaced Role
grants leader-election Lease access in the release namespace. The node
DaemonSet, including its optional NRI sidecar, does not mount a ServiceAccount
token. See the
Mokka Control Plane for its reconciliation and
single-writer lifecycle. The node agent runs privileged to use bidirectional
mount propagation; the other chart containers are not privileged. The node pod
shares the host's PID namespace to restart containerd; no component uses
another host namespace.
Privilege is scoped per container:
| Container | Security context | Filesystem | User |
|---|---|---|---|
node-agent |
privileged | writable, to stage the mock driver tree | image default |
allocation-watcher |
drops ALL; disallows privilege escalation |
readOnlyRootFilesystem |
image default |
control-plane |
drops ALL; RuntimeDefault seccomp; no privilege escalation |
readOnlyRootFilesystem |
non-root, UID 65532 |
nvml-mock-nri |
capabilities not dropped; no privilege escalation | writable | root (UID 0) |
The privileged node agent is the exception to the other containers' explicit
allowPrivilegeEscalation: false setting.
Mokka's reach into a node comes from its host mounts. The node agent writes to
/var/lib/nvml-mock, /run/nvidia, /run/cdi, the fabricmanager state
directory, and the Node Feature Discovery features directory, and, to set up
the container runtime, to /usr/bin, /usr/local/nvml-mock,
/etc/nvidia-container-runtime and /etc/containerd. /sys, the
pod-resources socket and the host's root filesystem are mounted read-only.
Inputs come from the operator installing the chart rather than from untrusted
third parties, so validation is scoped accordingly: chart values are checked
against deployments/nvml-mock/helm/nvml-mock/values.schema.json, and the YAML
device profile is checked by validateYAMLConfig in
pkg/gpu/mocknvml/engine/config.go. Review attention goes to the error classes
this codebase can actually hit — memory handling across the CGo boundary in
shims/ and pkg/gpu/mocknvml, and path handling in the code that writes to
hostPath mounts and performs NRI injection.
Mokka implements no cryptography. It stores no passwords and generates no keys,
and where TLS is needed to reach the Kubernetes API server it calls client-go
and the Go standard library, which verify certificates by default.
CodeQL, golangci-lint, and go test -race run on every pull request and every
push to main. -Wall -Wextra gates the C shims, and
pkg/gpu/mocknvml/engine/fuzz_test.go provides a Go fuzz target. Dependabot
proposes weekly Go module and GitHub Actions updates, and
OpenSSF Scorecard
reports supply-chain posture publicly.