> 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/es/cms/froxlor-cms-exploitation.md).

# Froxlor

Notas de explotación de Froxlor para abuso del comando de reinicio de PHP-FPM, copia de archivos root, cambios de permisos, recuperación de clave privada SSH y escalada de privilegios.

## Explotando Froxlor - PHP-FPM

<div data-full-width="false"><figure><img src="https://754079710-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>

**Creación de una nueva versión de PHP :**

Después de iniciar sesión, vaya a `PHP > versiones de PHP-FPM` y cree una nueva versión. En el campo de comando de reinicio de PHP-FPM, introduzca: `cp /root/root.txt /tmp/root.txt`

<figure><img src="https://754079710-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>

Guarde la configuración, luego vaya a `http://127.0.0.1:8081/admin_settings.php?start=phpfpm`. Desactive PHP-FPM, guarde, vuelva a activarlo y guarde de nuevo. Esto activa el comando de copia.

<figure><img src="https://754079710-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>

El archivo ahora está copiado; a continuación, ajuste los permisos:

<figure><img src="https://754079710-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>

Repita el mismo proceso, reemplazando el comando por:

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

### Bandera root :)

<figure><img src="https://754079710-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>

Para conectarse como root, copie la clave SSH de root `id_rsa` y repita el proceso para corregir los permisos:

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

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

<figure><img src="https://754079710-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>

Luego conéctese por SSH con la clave:

```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/es/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.
