Record summary

CVE-2020-28949 has a selected CVSS score of 7.8 (high); EIP currently links 1 catalogued exploit, 2 repository PoCs, and 1 lab environment. CISA lists CVE-2020-28949 in KEV; VulnCheck reports CVE-2020-28949 use in known ransomware campaigns.

Description

Archive_Tar through 1.4.10 has :// filename sanitization only to address phar attacks, and thus any other stream-wrapper attack (such as file:// to overwrite files) can still succeed.

Description source: CVE List

Exploitation context

Known exploitation

CISA KEV
Listed · Aug 25, 2022 · CISA
VulnCheck KEV
Listed · Aug 25, 2022 · VulnCheck
Reported exploitation
Observed · VulnCheck
Ransomware use
Observed · VulnCheck

Available material

Catalogued exploits
1
Repository PoCs
2
Lab environments
1

CISA SSVC decision

ExploitationActive
AutomatableNo
Technical impactTotal

CISA Coordinator · SSVC 2.0.3 · Evaluated Feb 7, 2025 · Source: CVE List

Affected products and versions

2
ProductSourceVersion rangeStatus
CISAVersion data not supplied
GitHub AdvisoryBefore 1.4.11 · Fixed in 1.4.11affected

Proofs of concept

3

Catalogued exploits

MetasploitPEAR Archive_Tar 1.4.10 Arbitrary File WriteMetasploit exploitby gwillcox-r7 +1 moreNot analyzed1 file

Ruby

Metasploit

PoC details

Repository PoCs

GitHub0x240x23elu/CVE-2020-28948-and-CVE-2020-28949Repository PoCby 0x240x23eluStars: 6Not analyzed2 files

17.8 KiB · linked to 2 vulnerabilities

GitHub

PoC details
GitHubJinHao-L/PoC-for-CVE-2020-28948-CVE-2020-28949Repository PoCby JinHao-LStars: 0Not analyzed24 files

216.6 KiB · linked to 2 vulnerabilities

GitHub

PoC details

Docker lab environments

1
GitHub

server

JinHao-L/PoC-for-CVE-2020-28948-CVE-2020-28949Created
Vuln labCVE-2020-28948CVE-2020-28949Standalone Multiple Dockerfiles

2 Dockerfiles

Analysisdeepseek-v4-pro:cloud ·

Environment assessment

A containerized PHP 7.2 Apache web server that accepts tar file uploads, extracts them using the Archive_Tar library, and lists the extracted contents. It provides both a vulnerable and a patched version of the library to demonstrate CVE-2020-28948 and CVE-2020-28949.

README.md:1-50server/Dockerfile:1-10server/Dockerfile-patched:1-13server/uploads/index.php:1-44

Lab assessment

Vulnerability lab

The README explicitly states it is a PoC for CVE-2020-28948 and CVE-2020-28949, and the server code uses a vulnerable Archive_Tar library to process uploaded tar files, which is the target of the described exploits.

README.md:1-3server/uploads/index.php:2server/uploads/index.php:17-18
Lab shapeStandalone Multiple Dockerfiles
ServicesUnknown
Compose manifests0
Dockerfiles2
Evidence & reasoningComponents · CVE assessment · exercise context · review boundaries
Components

Services and files described by the evidence

Vulnerable Archive_Tar library

vulnerable dependencytar extraction library

The PEAR Archive_Tar library used by the upload handler to extract uploaded tar files. The vulnerable version (Tar.php) lacks the phar:// check in _maliciousFilename, while the patched version (Tar-patched.php) includes it.

server/Archive/Tar.php:1-2491server/Archive/Tar-patched.php:1-2491server/uploads/index.php:2

Upload handler (uploads/index.php)

file upload endpointtar extraction trigger

Receives uploaded tar files, instantiates Archive_Tar, calls extract() without a path argument, and lists extracted contents. It is the entry point for the exploit.

server/uploads/index.php:1-44

Apache web server (php:7.2-apache)

web serverPHP runtime

The base Docker image providing Apache with PHP 7.2, serving the upload form and handling requests.

server/Dockerfile:1

Dockerfile (vulnerable)

builds vulnerable server image

Builds the cve-server image using the vulnerable Archive_Tar library (Tar.php).

server/Dockerfile:1-10

Dockerfile-patched

builds patched server image

Builds the cve-server-patched image, replacing Tar.php with Tar-patched.php which includes the phar:// check.

server/Dockerfile-patched:1-13

Makefile

build and run automation

Provides make targets to build and start both the vulnerable and patched server containers, mapping port 8080 to container port 80.

server/Makefile:1-11

.htaccess (uploads/.htaccess)

access control

Denies all access to the uploads directory except for index.php, protecting extracted files from direct web access.

server/uploads/.htaccess:1-7

secret.md

target file for demonstration

A sample file in the uploads directory used to demonstrate arbitrary file read after .htaccess deletion.

server/uploads/secret.md:1
CVE assessment

How the supplied evidence relates each vulnerability

CVE-2020-28948

Supported by supplied evidence

The vulnerable Archive_Tar library (Tar.php) does not check for 'phar://' in filenames, allowing a PHAR deserialization attack when a tar file containing a phar:// filename is extracted. The README describes this as arbitrary file deletion, and the patched version adds the missing check.

server/Archive/Tar.php:1-2491server/Archive/Tar-patched.php:1-2491README.md:19-30

CVE-2020-28949

Supported by supplied evidence

The vulnerable Archive_Tar library (Tar.php) does not check for 'phar://' in filenames, allowing a PHAR inclusion attack when a tar file containing a phar:// filename is extracted. The README describes this as uploading a shell.php for RCE, and the patched version adds the missing check.

server/Archive/Tar.php:1-2491server/Archive/Tar-patched.php:1-2491README.md:32-42
Exercise context

Requirements and sequence described by the evidence

Prerequisites

  • Docker must be installed to build and run the server images.server/Makefile:1-11
  • The attacker must craft a malicious tar file containing a phar:// filename to trigger the deserialization or inclusion vulnerability.README.md:19-42
  • The server must be running the vulnerable image (cve-server) for the exploit to work.README.md:7-9

Evidence-described exercise path

  1. Build and start the vulnerable server using 'make build' and 'make start' in the server directory.README.md:7-9
  2. For CVE-2020-28948: Navigate to the PoC folder, modify $delete_target in create_phar.php, and run 'make create_exploit' to generate exploit.tar.README.md:21-26
  3. Upload exploit.tar via the web form at http://localhost:8080.README.md:27
  4. Observe the file deletion (e.g., .htaccess) and access secret.md at http://localhost:8080/uploads/secret.md.README.md:28-30
  5. For CVE-2020-28949: Navigate to the PoC folder, run 'make create_exploit' to generate exploit.tar.README.md:34-36
  6. Upload exploit.tar and observe shell.php is created; access http://localhost:8080/shell.php?cmd=whoami for RCE.README.md:37-42
Safety-review evidence

Behaviors behind the stored safety assessment

No harmful behavior observed

All visible behavior is confined to the lab's own container. The server extracts uploaded tar files and lists contents, which is the intended vulnerable functionality. The Dockerfiles only expose port 80, install netcat (a common debugging tool), and copy local source code. No evidence of host escape, external connections, persistence, credential theft, or destructive behavior beyond the lab target is present.

server/Dockerfile:1-10server/Dockerfile-patched:1-13server/uploads/index.php:1-44server/Makefile:1-11
Review boundaries

What the analysis did not establish

  • The packet does not include the PoC exploit generation scripts (create_phar.php, Makefile for exploits) referenced in the README, so the exact exploit payloads cannot be analyzed.
  • The netcat installation in the Dockerfiles is not explained; its purpose is unclear but does not appear to be used in the visible server code.
  • The analysis is limited to static file content; runtime behavior of the tar extraction and potential phar deserialization is not observed.
Model interpretation

This review is limited to the supplied lab evidence packet. It does not assert that the environment runs, reproduces a vulnerability, or is safe to execute. Contract: eip-docker-lab-analysis-v1.

References

Showing 12 of 23