# CVE-2023-45878: File upload in n/a

> Unauthenticated attackers can write arbitrary files via an insecure endpoint, leading to remote code execution in GibbonEdu Gibbon.

- **Severity:** Critical 9.8 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** No
- **Published:** 14 Nov 2023
- **Updated:** 8 Jan 2025
- **Also known as:** GHSA-r526-pvv3-w6p8

## What is CVE-2023-45878?

CVE-2023-45878 is a critical vulnerability in n/a, published on 14 Nov 2023. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

GibbonEdu Gibbon version 25.0.1 and before allows Arbitrary File Write because rubrics_visualise_saveAjax.phps does not require authentication. The endpoint accepts the img, path, and gibbonPersonID parameters. The img parameter is expected to be a base64 encoded image. If the path parameter is set, the defined path is used as the destination folder, concatenated with the absolute path of the installation directory. The content of the img parameter is base64 decoded and written to the defined file path. This allows creation of PHP files that permit Remote Code Execution (unauthenticated).

Weakness: CWE-787 (Out-of-bounds Write)

## Which versions are affected by CVE-2023-45878?

It affects 1 product.


Products: Gibbonedu Gibbon.

## How do I fix CVE-2023-45878?

No fix has been published for CVE-2023-45878 yet. Limit exposure of the affected software until one is available.

## Is CVE-2023-45878 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2023-45878 exists.

Public exploit code:

- CVE-2023-45878 GibbonEdu Arbitrary File Write (github_poc): https://github.com/killercd/CVE-2023-45878
- This script chains and automates Arbitrary File Write to RCE on Gibbon LMS through CVE-2023-45878 exploitation. (github_poc): https://github.com/byt3loss/CVE-2023-45878_to_RCE
- GibbonEdu Arbitrary File Write to Remote Code Execution (github_poc): https://github.com/davidzzo23/CVE-2023-45878
- https://github.com/Can0I0Ever0Enter/CVE-2023-45878 (github_poc): https://github.com/Can0I0Ever0Enter/CVE-2023-45878
- https://github.com/dgoorden/CVE-2023-45878 (github_poc): https://github.com/dgoorden/CVE-2023-45878
- CVE-2023-45878 easy exploit | revers sehell  (github_poc): https://github.com/nrazv/CVE-2023-45878

## Other vulnerabilities in n/a

- [CVE-2024-24724](https://insights.sbomify.com/CVE-2024-24724/): Code injection in n/a (critical 9.8)
- [CVE-2023-34598](https://insights.sbomify.com/CVE-2023-34598/): Path traversal in n/a (critical 9.8)
- [CVE-2024-24725](https://insights.sbomify.com/CVE-2024-24725/): Deserialization in n/a (high 8.8)
- [CVE-2022-27305](https://insights.sbomify.com/CVE-2022-27305/): Auth bypass in n/a (high 8.8)
- [CVE-2023-45880](https://insights.sbomify.com/CVE-2023-45880/): Path traversal in n/a (high 7.2)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2023-45878 and fix it if it is affected.

What it is: CVE-2023-45878 is a critical vulnerability in n/a, published on 14 Nov 2023. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2023-45878 exists.

Affected product: n/a. No package-level version data is available, so check the vendor advisory linked from the reference page.

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2023-45878/ (Markdown: https://insights.sbomify.com/CVE-2023-45878/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2023-45878
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2023-45878
- OSV: https://osv.dev/vulnerability/CVE-2023-45878

---
From sbomify Insights: https://insights.sbomify.com/CVE-2023-45878/
Summaries are generated and may contain mistakes; the official description above is the record.
