REDHAT-BUG-2501801: Medium severity Helm helm vulnerability
Helm through 4.2.3, fixed in commit ba6c9a2, contains a denial of service vulnerability in the Files.Lines template helper in pkg/engine/files.go that allows attackers to trigger an index out of range panic by including zero-length byte slices in chart files. Attackers can include empty files in Helm charts to cause deterministic render failures across template, install, upgrade, lint, and SDK Engine.Render operations.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Patch ba6c9a2
Event History
Frequently Asked Questions
Who can trigger the denial of service?
An attacker who can supply or influence a Helm chart can include empty files in that chart. Rendering operations that process the affected template helper can then fail deterministically.
Which Helm operations are affected?
The issue can cause failures during template rendering, install, upgrade, lint, and SDK Engine.Render operations.
Are default Helm deployments affected?
The provided information does not identify a configuration prerequisite. Exposure depends on processing a chart containing zero-length byte slices, such as empty chart files.
How can I determine whether a chart is triggering this issue?
Check whether the chart contains empty files and whether rendering, installation, upgrade, linting, or SDK Engine.Render fails with an index-out-of-range panic. The failure is described as deterministic when the affected helper processes those files.
What can be done before updating Helm?
Avoid processing charts that contain empty files, or remove/replace empty files from charts before rendering or deployment. The issue is fixed in commit ba6c9a2.