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

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CVE-2023-37625 PoC — Netbox 跨站脚本漏洞

Source
Associated Vulnerability
Title:Netbox 跨站脚本漏洞 (CVE-2023-37625)
Description:NetBox是NetBox社区的一款基于Django、PostgreSql 用于IP地址管理(IPAM)和数据中心基础结构管理(DCIM)的工具。 Netbox v3.4.7版本存在安全漏洞,该漏洞源于允许攻击者通过注入精心设计的有效负载来执行任意 Web 脚本或 HTML。
Readme
# Netbox-CVE-2023-37625
## Description
A stored cross-site scripting (XSS) vulnerability in Netbox < 3.4.7 allows attackers to execute arbitrary web scripts or HTML via a crafted payload injected into the Custom Link templates.

## Technical Details
A stored Cross-Site Scripting vulnerability was discovered in the custom link function of the web application. This vulnerability is a result of insufficient sanitisation of the Link URL field.

To reproduce this vulnerability, the following steps may be performed:

1. Navigate to Custom Links under the Other tab.
2. Create a custom link with the following Link URL value, and assign the link to a model. In this example 'manufacturer' has been selected.:

```
{{'test1"</a><script>alert(1)</script>'}}
```

<img width="1094" alt="XSScustomlink" src="https://github.com/benjaminpsinclair/Netbox-CVE-2023-37625/assets/93361940/77ceb82d-8d12-490d-97bc-5d2db45a3260">

3. Add a new model, in this example add a 'manufacturer' model.

<img width="1238" alt="addmanufacturer" src="https://github.com/benjaminpsinclair/Netbox-CVE-2023-37625/assets/93361940/4e12634f-6bc6-4317-a827-14b41da5075f">

4. Open the newly created model as any authenticated user, and observer that the alert box has executed.
   
<img width="1104" alt="payload" src="https://github.com/benjaminpsinclair/Netbox-CVE-2023-37625/assets/93361940/f5ada457-d359-4f9b-b070-9d64dee9550a">
File Snapshot

[4.0K] /data/pocs/0751b7ebcdc4df7a6e7f3fb118351ff7f4c4974b └── [1.4K] 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.