CVE-2023-39135
Swift vulnerability analysis and mitigation

Overview

An issue in Zip Swift v2.1.2 allows attackers to execute a path traversal attack via a crafted zip entry. The vulnerability was discovered and reported on July 24, 2023, affecting the Zip library for Swift programming language (Ostorlab Blog, GitHub Issue).

Technical details

The vulnerability exists in the unzipFile function where the package does not validate paths coming from zip entries. The pathString from the zip entry is directly appended to the destination directory without any sanitization, allowing for path traversal attacks. The vulnerability has been assigned a CVSS v3.1 base score of 7.8 (HIGH) with vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H (NVD).

Impact

This vulnerability could allow attackers to write files outside the intended extraction directory, potentially overwriting sensitive user data. In some cases, this could lead to code execution if an attacker manages to overwrite application files (Ostorlab Blog).

Mitigation and workarounds

Users should upgrade to a patched version of the Zip library. The vulnerability is similar to the previously known Zip Slip vulnerability, and proper path validation should be implemented to ensure extracted files remain within the intended directory (Snyk Research).

Additional resources


SourceThis report was generated using AI

Related Swift vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-54951CRITICAL9.8
  • JavaJava
  • executorch
NoYesAug 07, 2025
CVE-2025-54950CRITICAL9.8
  • JavaJava
  • org.pytorch:executorch-android
NoYesAug 07, 2025
CVE-2025-54949CRITICAL9.8
  • JavaJava
  • org.pytorch:executorch-android
NoYesAug 07, 2025
CVE-2025-30405CRITICAL9.8
  • JavaJava
  • org.pytorch:executorch-android
NoYesAug 07, 2025
GHSA-xvr7-p2c6-j83wMEDIUM6.3
  • SwiftSwift
  • SwiftNIOHPACK
NoYesAug 13, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management