Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CVE-2023-40028 PoC — Ghost Foundation Ghost 后置链接漏洞

Source
Associated Vulnerability
Title:Ghost Foundation Ghost 后置链接漏洞 (CVE-2023-40028)
Description:Ghost Foundation Ghost是Ghost开源的一款用 JavaScript 编写的个人博客系统。 Ghost 5.59.1 版本之前存在后置链接漏洞,该漏洞源于允许经过身份验证的用户上传符号链接文件。攻击者利用该漏洞可以读取任意文件。
Description
CVE-2023-40028 is a security vulnerability affecting Ghost CMS versions prior to 5.59.1.
Readme
# CVE-2023-40028: Ghost CMS Symlink Exploitation (PoC)

## Overview

This repository contains a **Proof-of-Concept (PoC)** script designed to demonstrate the exploitation of **CVE-2023-40028**, a Local File Inclusion (LFI) vulnerability affecting **Ghost CMS versions prior to 5.59.1**. The vulnerability allows authenticated users to upload files that are symbolic links (symlinks), enabling attackers to access arbitrary files on the host system.

This PoC script will show how an attacker can upload a crafted zip file containing a symlink pointing to sensitive system files, potentially leading to information disclosure.

> **Disclaimer:**  
> This script is for educational and research purposes only. It is the user's responsibility to ensure they have permission to test the targeted systems. Unauthorized access to systems is illegal and unethical. Always obtain explicit permission before testing systems for vulnerabilities.

## Vulnerability Details

- **CVE ID**: CVE-2023-40028
- **Vulnerability Type**: Local File Inclusion (LFI)
- **Affected Product**: Ghost CMS (versions prior to 5.59.1)
- **Impact**: Attackers can upload symbolic link files to access sensitive system files on the server.
- **Fix**: Ghost CMS released version 5.59.1 to address this vulnerability.

### CVE-2023-40028 Summary:
The vulnerability exists due to improper handling of file uploads in Ghost CMS. Authenticated users can upload symbolic link files, which can be used to access sensitive files outside of the CMS’s intended directories.

## Prerequisites

Before using this PoC script, ensure you meet the following requirements:

- A running instance of **Ghost CMS** prior to version 5.59.1.
- An authenticated admin account for the Ghost CMS instance you are targeting.
- Python 3.x installed on your local system.
- Required Python libraries:
  - `requests`
  - `argparse`
  - `json`
  - `os`
  - `shutil`
  - `time`

You can install the required libraries using pip:
```bash
pip install requests
File Snapshot

[4.0K] /data/pocs/9e4c631ef379f5c993d4ec83d72e2279c1413710 ├── [3.5K] exploit.py ├── [ 34K] LICENSE └── [2.0K] README.md 0 directories, 3 files
Shenlong Bot has cached this for you
Remarks
    1. It is advised to access via the original source first.
    2. If the original source is unavailable, please email f.jinxu#gmail.com for a local snapshot (replace # with @).
    3. Shenlong has snapshotted the POC code for you. To support long-term maintenance, please consider donating. Thank you for your support.