CVE-2021-22114: Path Traversal in Spring-integration-zip

Summary

18/03/2022
Yes i
Moderate
5.3

CVE-2021-22114: Path Traversal in Spring-integration-zip. Affects org.springframework.integration:spring-integration-zip versions < 1.0.4. Fixed in 1.0.4. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

Spring-integration-zip is a Maven package that provides integration support for handling zip archives in Spring applications. It allows for the extraction and manipulation of zip files within the Spring framework. However, versions prior to 1.0.4 are vulnerable to a path traversal attack, which can lead to arbitrary file write vulnerabilities. This vulnerability can be exploited by using a specially crafted zip archive that contains filenames with path traversal sequences. When these filenames are concatenated to the target extraction directory, the resulting path can extend outside of the intended target folder.

Vulnerability Detail

The path traversal vulnerability in Spring-integration-zip allows an attacker to write arbitrary files to the file system by manipulating the filenames within a zip archive. By including path traversal sequences in the filenames, an attacker can bypass the intended extraction directory and write files to arbitrary locations on the file system. This can lead to unauthorized access, data leakage, or even remote code execution if the written files are subsequently executed. The vulnerability affects other archive formats as well, including bzip2, tar, xz, war, cpio, and 7z.

How To Fix

Latest published version: 7.2.0-RC1 as of 22 Oct 2026

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.0.4

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a workaround, developers can implement input validation and sanitization measures to ensure that filenames within zip archives do not contain path traversal sequences. This can be done by checking the filenames against a whitelist of allowed characters and rejecting any filenames that contain directory traversal sequences such as '../'. Additionally, it is recommended to restrict the extraction directory to a specific location within the file system to prevent files from being written to unintended locations.

Conclusion

The path traversal vulnerability in Spring-integration-zip exposes an arbitrary file write vulnerability that can be exploited through specially crafted zip archives. Upgrading to version 1.0.4 or later and implementing input validation and sanitization measures can help mitigate the risk of this vulnerability. For further support on vulnerability remediation, contact DevNack.com.

See every vulnerability recorded for org.springframework.integration:spring-integration-zip →

Share this vulnerability

FAQ

The vulnerability allows an attacker to write arbitrary files to the file system, potentially leading to unauthorized access, data leakage, or remote code execution.

Versions prior to 1.0.4 are affected by this vulnerability.

Yes, other archive formats such as bzip2, tar, xz, war, cpio, and 7z are also vulnerable to this path traversal attack.

Yes, upgrading to version 1.0.4 or later of the Spring-integration-zip package includes a partial fix for this vulnerability.

Implement input validation and sanitization measures to ensure that filenames within zip archives do not contain path traversal sequences. Additionally, restrict the extraction directory to a specific location within the file system.

Related vulnerabilities

Recent vulnerabilities recorded for org.springframework.integration:spring-integration-zip.

How To Fix

Latest published version: 7.2.0-RC1 as of 22 Oct 2026

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.0.4

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback