---
title: "CWE-1322: Use of Blocking Code in Single-threaded, Non-blocking Context"
url: https://radicalnotion.ai/cwe/cwe-1322
type: cwe
description: "The product uses a non-blocking model that relies on a single threaded process for features such as scalability, but it contains code that can block when it is invoked."
updated: 2026-11-10
source: RadicalNotion.AI
license: CC BY-NC 4.0 (https://creativecommons.org/licenses/by-nc/4.0/)
---

# CWE-1322: Use of Blocking Code in Single-threaded, Non-blocking Context

- **Abstraction:** Base
- **Structure:** Simple
- **Status:** Incomplete
- **CVEs with this as primary weakness:** 10
- **Of those, in CISA KEV:** 0
- **New in 2026:** 7
- **CWE catalog version:** 4.21

## Description

The product uses a non-blocking model that relies on a single threaded process for features such as scalability, but it contains code that can block when it is invoked.

## Background

Due to limitations in multi-thread models, single-threaded models are used to overcome the resource constraints that are caused by using many threads. In such a model, all code should generally be non-blocking. If blocking code is called, then the event loop will effectively be stopped, which can be undesirable or dangerous. Such models are used in Python asyncio, Vert.x, and Node.js, or other custom event loop code.

Examples of blocking code might be an expensive computation or calling blocking library calls, such as those that perform exclusive file operations or require a successful network operation.

## Modes of introduction

| Phase | Note |
| --- | --- |
| Implementation | - |

## Common consequences

| Scope | Impact | Note |
| --- | --- | --- |
| Availability | DoS: Resource Consumption (CPU) | When an attacker can directly invoke the blocking code, or the blocking code can be affected by environmental conditions that can be influenced by an attacker, then this can lead to a denial of service by causing unexpected hang or freeze of the code. An unexpected call to blocking code can trigger an infinite loop, or a large loop that causes the software to pause and wait indefinitely. |

## Potential mitigations

### Implementation

Generally speaking, blocking calls should be replaced with non-blocking alternatives that can be used asynchronously. Expensive computations should be passed off to worker threads, although the correct approach depends on the framework being used.

### Implementation

For expensive computations, consider breaking them up into multiple smaller computations. Refer to the documentation of the framework being used for guidance.

## Real CVEs with this weakness

| CVE | Title | Severity | CVSS | EPSS | CISA KEV | Published |
| --- | --- | --- | --- | --- | --- | --- |
| CVE-2026-120399 | Flightctl-api: flightctl-remote-access: flightctl: unbounded tls handshake in conncontext can block accepting connections | high | 7.5 | - | No | 2026-11-10 |
| CVE-2026-43245 | ntfs: -\>d\_compare() must not block | high | 7.5 | - | No | 2026-05-06 |
| CVE-2026-98046 | bpf: Mark bpf\_btf\_find\_by\_name\_kind() as sleepable | high | 7.1 | - | No | 2026-09-25 |
| CVE-2026-128886 | Dbus: server accept watch can be stalled by blocking nonce-tcp accept\_with\_noncefile path | medium | 6.2 | - | No | 2026-11-13 |
| CVE-2026-89329 | Device-mapper-multipath: local denial of service via blocking ipc send operations | medium | 6.2 | - | No | 2026-09-11 |
| CVE-2026-42256 | net-imap: Denial of service via high iteration count for \`SCRAM-\*\` authentication | medium | 6.0 | - | No | 2026-05-09 |
| CVE-2026-98045 | bpf: Mark faultable stack helpers as sleepable | medium | 5.5 | - | No | 2026-09-25 |
| CVE-2022-50491 | coresight: cti: Fix hang in cti\_disable\_hw() | medium | 5.5 | - | No | 2025-10-04 |
| CVE-2023-53558 | rcu-tasks: Avoid pr\_info() with spin lock in cblist\_init\_generic() | medium | 5.5 | - | No | 2025-10-04 |
| CVE-2025-40071 | tty: n\_gsm: Don't block input queue by waiting MSC | medium | 4.9 | - | No | 2025-10-28 |

## Related attack patterns (CAPEC)

- [CAPEC-25](https://radicalnotion.ai/capec/capec-25): Forced Deadlock

## Related weaknesses

| Relationship | CWE | Name |
| --- | --- | --- |
| Parent | [CWE-834](https://radicalnotion.ai/cwe/cwe-834) | Excessive Iteration |
| Can precede | [CWE-835](https://radicalnotion.ai/cwe/cwe-835) | Loop with Unreachable Exit Condition |

## Frequently asked questions

### What is CWE-1322?

The product uses a non-blocking model that relies on a single threaded process for features such as scalability, but it contains code that can block when it is invoked.

### What CVEs are caused by CWE-1322?

10 recorded CVEs are attributed to CWE-1322, including CVE-2026-120399, CVE-2026-43245 and CVE-2026-98046.

### How do you prevent CWE-1322?

Generally speaking, blocking calls should be replaced with non-blocking alternatives that can be used asynchronously. Expensive computations should be passed off to worker threads, although the correct approach depends on the framework being used.

### What are the consequences of CWE-1322?

Exploiting CWE-1322 can lead to: DoS: Resource Consumption (CPU).

### Is CWE-1322 actively exploited?

10 recorded CVEs are caused by CWE-1322; none are currently in CISA's KEV catalog of actively exploited flaws.

Primary source: [MITRE CWE](https://cwe.mitre.org/data/definitions/1322.html)

---

Source: [RadicalNotion.AI](https://radicalnotion.ai/cwe/cwe-1322). Licensed CC BY-NC 4.0; attribute RadicalNotion.AI and link the source page when you reuse this data.
