> 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/ru/cms/magento-cms-exploitation.md).

# Magento

{% hint style="info" %}
**Magento** — это платформа электронной коммерции с открытым исходным кодом, используемая для создания собственных интернет-магазинов. Она поддерживает управление товарами, заказами и платежами, и обычно расширяется с помощью модулей и тем.
{% endhint %}

## Сканер веб-сайтов Magento (magescan)

Скачать [magescan (magescan.phar)](https://github.com/steverobbins/magescan/releases).

```bash
php magescan.phar scan:all http://site-web.com
```

## пример SQL-инъекции для кражи cookie сеанса

* Используйте `wget` для загрузки исходного [скрипт Python](https://github.com/ambionics/magento-exploits/blob/master/magento-sqli.py) цикл **перехват cookie**.

1. Практический пример использования:

```bash
python3 magento-sqli.py http://localhost:8080/
```

<figure><img src="/files/dab67071d49f3fb267d21b917bd924c48a5de2f9" alt=""><figcaption></figcaption></figure>

2. С помощью [редактор cookie](https://chrome.google.com/webstore/detail/cookie-editor/hlkenndednhfkekhgcdicdfddnkalmdm) расширение, замените текущую cookie на cookie администратора:

<figure><img src="/files/1ce6782619a7bad2fc2a60cb058970a79f266457" alt=""><figcaption></figcaption></figure>

3. Взломано :)

<figure><img src="/files/88df8fc66c69f05b30e7566b3ad300b323a77270" alt=""><figcaption></figcaption></figure>


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://hacking-notes.jord4n.pro/ru/cms/magento-cms-exploitation.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
