Security
How to report a vulnerability in k3sm, starting with the private GitHub advisory flow, then email, then the maintainer, and where the trust boundaries sit.
k3sm runs privileged components (a root networking helper and a process sandbox), so a public bug report is a disclosed zero-day before there is a fix. Please report privately.
Reporting a Vulnerability#
Do not open a public GitHub issue for a security problem. Use these channels, in this order of preference:
- Open a private GitHub security advisory from the affected repository’s Security tab, using Report a vulnerability. This channel comes first because it is private, it supports coordinated and embargoed collaboration, and a CVE can be issued from it. Direct links: k3sm, runtimed, darwin-net, apis, app, k3sm-sdk-cpp, k3sm-sdk-swift. If you are unsure which repository is affected, use k3sm.
- Email kitsumiko@k3sm.io if the advisory flow is unavailable to you, or if you would rather not open a GitHub account to make a report.
- Or contact the maintainer directly by messaging @kitsumiko on GitHub.
Please include the affected component and a reproduction if you have one.
What Counts as High Severity#
- Local privilege escalation is anything that gets from the unprivileged
_k3smuser, or from inside a Pod, to root. Thek3sm-netdhelper is the only long-running root component and accepts a closed, typed RPC over a uid-authenticated socket; making it act outside that contract is serious. (A data root on its own volume adds a root daemon that mounts it at boot.) - Sandbox escape is anything that lets a Pod’s process reach outside its Seatbelt profile, such
as reading
/Users, writing outside its own data volume, or reaching another Pod’s files. - Guest kernel or initramfs substitution is a way to make a
vmguest boot an unpinned kernel or initramfs. The digest pin is the whole trust chain, because a VM-booted kernel gets no OS code-signing check.
Also serious: a way to join a cluster without the join credentials, a way to impersonate a node, a flaw in certificate issuance or trust, and a weakness in the release download path.
Where the Trust Boundaries Sit#
- The server’s own node runs as
system:node:<name>under the Node authorizer, so a node bug cannot act as cluster admin. - Secrets are unencrypted in the datastore unless the cluster was created with
sudo k3sm install --secrets-encryption, which is opt-in and off by default. - The admin token and the datastore connection string stay off the server’s command line, and the mesh keys sit under a root-owned state root.
- A torn-down Pod’s address is blackholed, a defence against a macOS kernel panic seen on the pod network.
- Both download artifacts carry the Developer ID. The k3sm app disk image is Developer ID signed and notarized, and so is every program in the release tarball the install script downloads. The script itself checks the tarball against its published checksum, which shows the file is intact and says nothing about who built it.
- The server runs the cluster’s one image registry,
registry-k3sm:6450, on by default and served over HTTPS under a certificate the cluster CA issues; plain HTTP is refused. Each node keeps a pull cache. Pulls are anonymous, so any process that can reach the registry can read the images the cluster runs. Pushes are authenticated, with a builder token or a Pod’s projected ServiceAccount token, and--registry-port 0turns the registry off. - metrics-server verifies each kubelet’s certificate against the cluster CA and authenticates with
its ServiceAccount token. The apiserver does not verify metrics-server’s certificate, because the
metrics.k8s.ioAPIService keeps upstream’sinsecureSkipTLSVerify: true, unchanged from the vendored upstream manifest. The apiserver does authenticate itself to metrics-server with its proxy client certificate.
Verifying a Download#
For the app, drag it to /Applications, then check the signature and the Gatekeeper assessment:
codesign --verify --deep --strict --verbose=2 /Applications/k3sm.app
spctl --assess --type execute --verbose /Applications/k3sm.app
codesign -dvv /Applications/k3sm.app 2>&1 | grep -E 'Authority|TeamIdentifier'The first command exits 0 when the signature is intact, the second reports accepted with the
notarized Developer ID source, and the third prints the signing authority and the Team ID, which
should be the same on every release. The app pins that Team ID in its own executable.
For the tarball, shasum -a 256 -c against the checksums file published beside it shows the
download is intact. K3SM_INSTALL_DOWNLOAD_ONLY=1 runs the install script’s download and
verification without installing anything. Its programs carry the same Team ID, which
codesign -dvv <program> 2>&1 | grep -E 'Authority|TeamIdentifier' prints for any of them.
What Is a Documented Limitation, Not a Vulnerability#
These design trade-offs are stated in advance in limitations. A report about one is still welcome as a discussion rather than an embargoed advisory.
- Same-node Pods share one trust domain, because every Pod on a node runs as the same
_k3smuser, with no per-Pod uid isolation and no network namespace. ThevmRuntimeClass, the path for untrusted work, boots each Pod into its own micro-VM with the supervisor confined on the host. It islinux/arm64and single-node, and a container in one of its Pods can read volumes it does not mount. - NetworkPolicy is a policy hint, enforced only on Service-VIP-mediated ingress, by each node for
its own Pods. Direct Pod-IP traffic bypasses it, and egress rules and
ipBlockare not enforced. It is not a security boundary. - Seatbelt network permission is all-or-nothing, because macOS accepts no per-address filters in a sandbox profile. The per-Pod egress opt-in is an admission-level contract with no packet filter behind it.
- Pods share the node’s port space, so a Pod and a LoadBalancer listener can collide on a port.
A new case in one of these classes is worth reporting, and so is documentation that describes a boundary as stronger than it is.
Disclosure#
k3sm follows coordinated disclosure. A report is acknowledged, a fix is worked under embargo, and you are credited when the fix is released, unless you would rather not be.
Supported Versions#
Please report against the latest main. There is no supported-versions policy yet; one comes with
the first stable release planned. Fixes ship in a new release, which re-running the
install script installs.
The canonical policy is SECURITY.md in the k3sm repository. The code is licensed under Apache-2.0, as stated in LICENSE.