> For the complete documentation index, see [llms.txt](https://picoctf2021.haydenhousen.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://picoctf2021.haydenhousen.com/binary-exploitation/whats-your-input.md).

# What's your input?

## Problem

> We'd like to get your input on a couple things. Think you can answer my questions correctly? in.py nc mercury.picoctf.net 39137.

* [in.py](https://github.com/HHousen/PicoCTF-2021/blob/master/Binary%20Exploitation/What%27s%20your%20input?/in.py)

## Solution

1. Look at the [in.py](https://github.com/HHousen/PicoCTF-2021/blob/master/Binary%20Exploitation/What%27s%20your%20input?/in.py) file, which is executed using Python 2.
2. The Python 2 input function is vulnerable. More info on [GeesForGeeks](https://www.geeksforgeeks.org/vulnerability-input-function-python-2-x/).
3. We can enter the variable name `city` as the city input parameter which will essentially set `res = city`.

### Flag

`picoCTF{v4lua4bl3_1npu7_8433797}`


---

# 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:

```
GET https://picoctf2021.haydenhousen.com/binary-exploitation/whats-your-input.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
