---
id: CVE-2026-120194
title: >-
  Json-glib: json-glib: infinite loop in json_path_query() with negative
  jsonpath slice step
summary: >-
  A flaw was found in json-glib. The JSONPath slice evaluator used by
  json_path_query() can enter an infinite loop when given a slice expression
  with a negative step. An application that evaluates attacker-controlled
  JSONPath expressions c…
severity: high
cvss: 7.5
cvssVector: 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H'
cvssSource: cna
cwe:
  - CWE-835
vendor: Red Hat
product: json-glib
affected:
  - json-glib (all versions)
  - json-glib (all versions)
  - json-glib (all versions)
  - json-glib (all versions)
  - openshift/ose-rhel-coreos-8 (all versions)
  - openshift/ose-rhel-coreos-9 (all versions)
  - openshift/ose-rhel-coreos-9 (all versions)
ssvc:
  exploitation: none
  automatable: 'yes'
  technicalImpact: partial
  timestamp: '2026-11-02T17:12:50.335733Z'
published: '2026-10-31'
updated: '2026-11-04'
sourceUpdated: '2026-11-04T22:06:32.135Z'
source: CVEORG
sourceUrl: 'https://www.cve.org/CVERecord?id=CVE-2026-120194'
references:
  - url: 'https://access.redhat.com/security/cve/CVE-2026-120194'
  - url: 'https://bugzilla.redhat.com/show_bug.cgi?id=2564418'
    label: RHBZ#2564418
  - url: 'https://gitlab.gnome.org/GNOME/json-glib/-/issues/96'
tags:
  - cve.org
epss: 0.00475
epssPercentile: 0.41194
ingestedAt: '2026-11-05T21:36:00.633Z'
---

## Overview

A flaw was found in json-glib. The JSONPath slice evaluator used by json_path_query() can enter an infinite loop when given a slice expression with a negative step. An application that evaluates attacker-controlled JSONPath expressions can be forced into a hang, leading to a denial of service.

## Affected

- `json-glib (all versions)`
- `json-glib (all versions)`
- `json-glib (all versions)`
- `json-glib (all versions)`
- `openshift/ose-rhel-coreos-8 (all versions)`
- `openshift/ose-rhel-coreos-9 (all versions)`
- `openshift/ose-rhel-coreos-9 (all versions)`

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.

### Workarounds

Do not evaluate untrusted JSONPath expressions with json_path_query() or json_path_compile()/json_path_match() until a fix is available. Prefer fixed, application-defined path expressions. In particular, reject or avoid slice expressions that specify a negative step.
