Summary
Fission's podSpec passthrough allowed unvalidated and dangerous Kubernetes fields to be merged into generated pods, effectively granting users more control than intended over runtime configuration.
Under certain configurations, an attacker who can define or modify Fission Environments or Builders could escalate privileges, weaken isolation, or escape intended security controls on the Kubernetes cluster.
Affected context
The vulnerability affects Fission deployments on Kubernetes where:
- Users can create or modify
EnvironmentorBuilderresources withspec.runtime.podSpecand/orspec.builder.podSpec. - Fission's controller uses
MergePodSpecto combine user-provided pod specs with system-generated pod specs. - Cluster policies rely on Fission to restrict which pod-level capabilities and security-relevant fields users may influence.
In such setups, unvalidated passthrough of podSpec fields can undermine namespace, RBAC, and PodSecurity/PodSecurityPolicy-style controls that operators assume are enforced.
Exploit preconditions
- Attack surface: Fission control-plane APIs for defining or updating
EnvironmentandBuilderspecifications, either directly via Kubernetes manifests or through higher-level tooling. - Required access: Ability to submit or modify Fission
EnvironmentorBuilderobjects (e.g., developer or tenant-level permissions within the cluster). - Trigger point: Creation or update of an Environment/Builder that includes crafted
podSpecfields, which are then processed byMergePodSpecto generate runtime or builder pods. - Why exploitation is possible: The podSpec passthrough lacked validation, and
MergePodSpecpropagated security-sensitive fields (such as securityContext, host access, capabilities, or other policy-relevant settings) into pods, allowing users to influence runtime permissions beyond their intended authorization boundaries.
Why this happens
The root cause lies in insufficient authorization boundaries around configuration fields that map directly to powerful Kubernetes pod capabilities.
Specifically, Fission allowed user-controlled Environment.spec.runtime.podSpec and spec.builder.podSpec to be merged wholesale into the final pod definition using MergePodSpec, without robust validation or filtering of sensitive options. This behavior aligns with:
- CWE-284: Improper Access Control, as users could indirectly gain access to elevated pod permissions.
- CWE-269: Improper Privilege Management, because privileges associated with pod-level controls were delegated without correctly constraining what users may request.
- CWE-693: Protection Mechanism Failure, since the expected security mechanisms (RBAC, pod security policies, or operator assumptions about Fission's enforcement) were effectively bypassed by design.
Abstractly, the pattern is: treating highly privileged infrastructure configuration (pod specs) as user-configurable without applying a dedicated validation and policy layer to strip or constrain dangerous fields.
Potential impact
- Fission functions or builder pods may run with elevated Linux capabilities or privileged security contexts.
- Attackers could influence pod-level settings to weaken isolation and potentially achieve container breakout or host interaction, depending on cluster configuration.
- Bypass of organizational pod security policies or hardening baselines that operators assume are enforced.
- Lateral movement opportunities within the Kubernetes cluster by gaining broader network access or access to sensitive service accounts.
- Execution of workloads with access to host resources or sensitive volumes that users were not meant to control.
General mitigation guidance
Effective mitigation focuses on treating pod specifications as a privileged control surface and enforcing strict boundaries around them:
- Introduce a validation layer that explicitly whitelists safe podSpec fields that tenants are allowed to set, and rejects or strips security-sensitive fields (e.g., privileged flags, host namespaces, hostPath volumes, serviceAccountName changes, and securityContext overrides).
- Separate user-intent configuration (resource limits, environment variables, image references) from low-level pod security configuration, ensuring only trusted components can modify the latter.
- Apply the principle of least privilege to both Fission's own controller permissions and to the pods it creates; restrict default capabilities and avoid implicit elevation paths.
- Use Kubernetes policy mechanisms (such as admission controllers, Pod Security Standards, or policy engines like OPA/Gatekeeper/Kyverno) to enforce constraints on pods originating from Fission namespaces.
- Treat multi-tenant Fission deployments as security-sensitive and avoid granting broad permissions to tenant identities to define raw pod-level configuration without additional checks.
How teams detect issues like this
Organizations can detect and monitor for this class of issue using a mix of configuration review and policy enforcement:
- Perform static configuration analysis of Fission CRDs and controllers to identify code paths or templates where user-supplied podSpecs are merged into final templates without filtering.
- During code review, flag any logic that passes user-controlled Kubernetes objects directly into pod creation APIs (Deployments, Jobs, Pods) without a validation or normalization step.
- Use admission controllers or policy-as-code tools (e.g., OPA/Gatekeeper, Kyverno) with rules that detect and optionally block pods created by Fission which include disallowed fields (privileged, hostNetwork, hostPID, hostPath, custom service accounts, etc.).
- Enable audit logging for Kubernetes API server and cluster policies to track when Fission-created pods deviate from expected security baselines, and investigate unusual securityContext or host-level configuration.
- Integrate automated security scanning tools in CI/CD that can parse Fission configuration and templates, alerting on patterns indicative of CWE-284/CWE-269 style misconfigurations.

