Skip to main content

dasel EUVDEUVD-2026-44994

| CVE-2026-46378 MEDIUM
Loop with Unreachable Exit Condition (Infinite Loop) (CWE-835)
2026-05-19 https://github.com/TomWright/dasel GHSA-m6xr-fvfg-5g64
6.2
CVSS 3.1 · Vendor: https://github.com/TomWright/dasel
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Identify endpoint passing user input to dasel selector
  2. Delivery
    Submit selector containing `r/` with no closing slash
  3. Exploit
    Lexer enters infinite loop in matchRegexPattern
  4. Execution
    Worker goroutine pins one CPU core at 100%
  5. Persist
    Repeat across workers to exhaust all cores
  6. Impact
    Service becomes unresponsive until process restart

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Loop termination conditions
MITRE ATT&CK

1 technique across 1 tactic: Impact

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires that an attacker can place arbitrary bytes into the selector/query string argument that the application passes to dasel's selector/lexer (for example dasel.Select or a direct lexer.NewTokenizer call). The trigger is a regex literal opener r/ without a closing / anywhere later in the string. There is no authentication, no user interaction, and no special platform required beyond the affected dasel v3 versions (>= 3.0.0, < 3.10.1). The principal limiting factor is exposure: dasel selectors are normally hardcoded by developers, so applications that hardcode or strictly whitelist selectors are not exploitable - only deployments that build selectors from untrusted input (web APIs that accept selector paths, shared automation that takes selectors as parameters, plugins that forward user fields into dasel) are at risk.

Impact

CVSS 7.5 (AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H) reflects pure availability impact with no confidentiality or integrity loss, scored as network-reachable and unauthenticated - but this rating assumes a deployment in which the attacker can reach the selector parser over a network, which is not dasel's typical usage profile. In most real deployments dasel is a CLI invoked by a developer or operator with trusted selector strings, so the practical exposure is limited to the specific scenarios the reporter calls out (web apps that pass user input into selectors, automation that templates selectors from untrusted data). EPSS and KEV signals were not provided in the input; absent KEV listing and with no evidence of in-the-wild exploitation, this is a low-urgency issue for typical CLI users and a moderate-urgency issue for the narrow class of services that expose dasel selectors to untrusted callers. The attack is trivially automatable once that exposure exists - a 2-byte payload is sufficient - so where the exposure does exist, fix quickly.

Exploit ScenarioDerived

An attacker who can influence a selector string that is passed to dasel - for example, a query parameter in a web service that forwards user-supplied paths into dasel.Select - submits the 2-byte payload r/. The lexer enters the infinite loop, pinning one CPU core at 100% and never returning to handle that request; repeating the request across worker goroutines saturates every core and renders the service unresponsive. The reporter's published Go PoC reproduces the hang reliably within five seconds.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.1% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – May 19, 2026

Denial of service in dasel (Go data selector library) versions 3.0.0 through 3.10.0 allows attackers who control selector query strings to pin a CPU core at 100% indefinitely via a 2-byte payload (r/). The selector lexer's matchRegexPattern closure lacks an end-of-input bounds check, causing an infinite loop when tokenizing unterminated regex literals. No public exploit identified at time of analysis beyond the reporter's PoC, and the issue is not listed in CISA KEV.

RemediationAI

Vendor-released patch: 3.10.1 - upgrade github.com/tomwright/dasel/v3 to v3.10.1 or later via go get github.com/tomwright/dasel/v3@v3.10.1 and rebuild any dependent binaries (fix commit https://github.com/TomWright/dasel/commit/95f8dd3af12958bf6ca2a737b3ec0267280f86ed; advisory https://github.com/TomWright/dasel/security/advisories/GHSA-m6xr-fvfg-5g64). If immediate upgrade is not possible, the only effective compensating control is to validate or sanitize selector strings before passing them to dasel - specifically reject any selector containing the substring r/ that is not followed by a closing /, or reject untrusted selector input entirely. Wrapping calls to lexer.Tokenize with a goroutine plus context timeout will recover the calling request but does not free the leaked CPU-bound goroutine, which will continue to consume one core until process restart, so timeouts are a partial mitigation only.

Affected VersionsENISA

dasel 3.0.0, < 3.10.1

Affected Packages

go github.com/tomwright/dasel no fix
go github.com/tomwright/dasel/v2 no fix
go github.com/tomwright/dasel/v3 fix: 3.10.1
euvd dasel_3_0_0 fix: 3.10.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 4 packages in go, euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

dasel is a Go-based command-line and library tool for querying and modifying structured data (JSON, YAML, TOML, XML) via a selector syntax, distributed as the Go module github.com/tomwright/dasel/v3. The flaw is a classic CWE-835 (Loop with Unreachable Exit Condition): the matchRegexPattern closure in selector/lexer/tokenize.go advances pos while peekRuneEqual(pos, '/') returns false, but peekRuneEqual also returns false when pos >= srcLen, so once the scanner passes the end of input without finding a closing /, the negated condition stays true forever and pos increments without bound. The same lexer correctly handles unterminated quoted strings with an UnexpectedEOFError, making this an inconsistency in error handling rather than a deep design flaw. The CPE pkg:go/github.com_tomwright_dasel_v3 confirms the v3 module line is affected.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (https://github.com/TomWright/dasel) PRIMARY 6.2 MEDIUM
AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
SUSE HIGH

Primary rating from Vendor (https://github.com/TomWright/dasel).

CVSS VectorVendor: https://github.com/TomWright/dasel

Attack Vector
Local
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

Lifecycle Timeline

2
Severity Changed
Jul 16, 2026 - 19:22 NVD
HIGH MEDIUM
CVSS changed
Jul 16, 2026 - 19:22 NVD
7.5 (HIGH) 6.2 (MEDIUM)

DescriptionCVE.org

Summary

dasel's selector lexer enters a non-terminating loop when tokenizing an unterminated regex pattern such as r/abc. A 2-byte input (r/) is sufficient to cause the tokenizer to consume 100% CPU on one core indefinitely.

I confirmed the issue on v3.3.1 (fba653c7f248aff10f2b89fca93929b64707dfc8) and on master commit 0dd6132e0c58edbd9b1a5f7ffd00dfab1e6085ad. I also verified the same code path is present in v3.0.0 (648f83baf070d9e00db8ff312febef857ec090a3). No fix is available yet.

Details

The bug is in the matchRegexPattern closure within (*Tokenizer).parseCurRune in selector/lexer/tokenize.go#L237-L247:

go
matchRegexPattern := func(pos int) *Token {
    if p.src[pos] != 'r' || !p.peekRuneEqual(pos+1, '/') {
        return nil
    }
    start := pos
    pos += 2
    for !p.peekRuneEqual(pos, '/') {  // line 243
        pos++
    }
    pos++
    return ptr.To(NewToken(RegexPattern, p.src[start+2:pos-1], start, pos-start))
}

When no closing / exists, peekRuneEqual returns false when pos >= srcLen (because the bounds check at line 40 returns false for out-of-range positions). Since !false = true, the loop condition remains true and pos increments indefinitely. The function never returns.

Notably, the same function already handles unterminated quoted strings by returning UnexpectedEOFError, but the regex pattern path does not perform a similar end-of-input check.

Minimal trigger: r/ (2 bytes)

Test environment:

  • MacBook Air (Apple M2), macOS / Darwin arm64
  • Go 1.26.1
  • dasel v3.3.1 (fba653c7f248aff10f2b89fca93929b64707dfc8)

PoC

go
package main

import (
	"fmt"
	"runtime"
	"time"

	"github.com/tomwright/dasel/v3/selector/lexer"
)

func main() {
	fmt.Printf("Go version: %s\n", runtime.Version())
	fmt.Printf("GOARCH: %s\n", runtime.GOARCH)
	fmt.Println()

	for _, input := range []string{"r/unterminated", "r/"} {
		fmt.Printf("Input: %s\n", input)
		done := make(chan string, 1)
		go func() {
			t := lexer.NewTokenizer(input)
			start := time.Now()
			tokens, err := t.Tokenize()
			elapsed := time.Since(start)
			if err != nil {
				done <- fmt.Sprintf("Error after %v: %v", elapsed, err)
			} else {
				done <- fmt.Sprintf("OK after %v: %d tokens", elapsed, len(tokens))
			}
		}()

		select {
		case result := <-done:
			fmt.Println(result)
		case <-time.After(5 * time.Second):
			fmt.Println("CONFIRMED: did not complete within 5s; tokenizer is stuck in non-terminating loop")
		}
		fmt.Println()
	}
}

Observed output on v3.3.1 in the test environment above:

text
Go version: go1.26.1
GOARCH: arm64

Input: r/unterminated
CONFIRMED: did not complete within 5s; tokenizer is stuck in non-terminating loop

Input: r/
CONFIRMED: did not complete within 5s; tokenizer is stuck in non-terminating loop

Impact

An attacker who can control or influence the selector/query string passed to dasel can cause the tokenizer to enter a non-terminating loop. The affected process consumes 100% CPU on one core and does not make progress until externally terminated.

The selector string is typically provided by the application developer, but there are deployment scenarios where it may be attacker-influenced:

  • Web applications using dasel for dynamic data querying
  • Applications that construct selectors from user input
  • Shared tooling environments where selectors are passed as parameters

Suggested Fix

The regex scanner should bounds-check and return an error on unterminated regex literals, consistent with unterminated quoted strings. Since matchRegexPattern currently returns *Token, the fix also requires changing the function signature to propagate errors. For example:

go
matchRegexPattern := func(pos int) (*Token, error) {
    if p.src[pos] != 'r' || !p.peekRuneEqual(pos+1, '/') {
        return nil, nil
    }
    start := pos
    pos += 2
    for pos < p.srcLen && p.src[pos] != '/' {
        pos++
    }
    if pos >= p.srcLen {
        return nil, &UnexpectedEOFError{Pos: pos}
    }
    pos++
    return ptr.To(NewToken(RegexPattern, p.src[start+2:pos-1], start, pos-start)), nil
}

Executive ViewAI

Why It Matters

Dasel (Go data selector library) versions 3.0.0-3.10.0 contain a denial-of-service vulnerability that exhausts CPU resources through crafted selector query inputs; no public exploit identified at time of analysis. Organizations deploying these versions face risk of service interruption. A vendor patch is available and should be deployed as a priority.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.1%
Top 84% exploitable
Threat Intel
1
1 source
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS GHSA Vendor GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact
High

Priority Score

31
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +31
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

Vendor StatusVendor

SUSE

Severity: Important
Product Status
SUSE Linux Enterprise Server 16.1 Affected
SUSE Linux Enterprise Server for SAP applications 16.1 Affected
SUSE Linux Enterprise Module for Package Hub 15 SP5 Affected
SUSE Linux Enterprise Module for Package Hub 15 SP6 Affected
openSUSE Leap 15.5 Affected

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy