create storageclasses
A StorageClass with a dangerous provisioner can be abused for host access or privileged operations during volume provisioning.
- API Group
- storage.k8s.io
- Scope
- cluster
- Audit Level
- Request
Escalation Paths
Create a StorageClass, or patch an existing one, and set the storageclass.kubernetes.io/is-default-class annotation to make it the cluster default
The API server allows more than one default class, and the DefaultStorageClass plugin breaks the tie by newest creationTimestamp, so a freshly created default wins without touching the existing one
With reclaimPolicy Retain on that class, the provisioned volume and its data survive deletion of the requesting namespace
Every PersistentVolumeClaim that omits storageClassName then binds through the attacker class.
Patch alone also suffices, since it moves the annotation between existing classes with no create
Additional rights needed:
