> For the complete documentation index, see [llms.txt](https://thomasbui.gitbook.io/blog/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://thomasbui.gitbook.io/blog/software-security/ctfs-write-ups/writeups-picoctf-collection/picoctf-2021/web-exploitation/cookies.md).

# Cookies

## Category

Web Exploitation

## Question

Who doesn't love cookies? Try to figure out the best one. <http://mercury.picoctf.net:6418/>

## Hint

No Hint

## Solution

A box search is given to the challenge.

<figure><img src="https://2930324358-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MCVzu45Bb9LVrMqjdY6%2Fuploads%2F0D9Cq746B3H8Nmpm6lI9%2Fcookies.png?alt=media&amp;token=6a0a5da9-33ab-4523-a39c-70f53e06c559" alt=""><figcaption><p>Cookies</p></figcaption></figure>

I tried to type `snickerdoodle`then I got `I love snickerdoodle cookies!`. As the title of the challenge, this is related to cookies, so I opened the dev tool and looked for cookies. It has a value field with the type of number. I tried to change the number and reload the website to see what happened and there are some changes on the web page.

So, I thought that flag might be shown if I can reach a number of the value field. To be faster, I used Burp and using Burp Intruder to the brute force value field.

I tried to brute force with numbers from 1 to 20 and looked for responses -> got the flag

<figure><img src="https://2930324358-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MCVzu45Bb9LVrMqjdY6%2Fuploads%2F0qlVHYDTdVZKBiXWZG05%2Fcookies-flag.png?alt=media&amp;token=e98b23d2-c429-4bda-b691-aef70eabb54e" alt=""><figcaption><p>Flag</p></figcaption></figure>

## Flag

`picoCTF{3v3ry1_l0v3s_c00k135_88acab36}`


---

# 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://thomasbui.gitbook.io/blog/software-security/ctfs-write-ups/writeups-picoctf-collection/picoctf-2021/web-exploitation/cookies.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.
