> For the complete documentation index, see [llms.txt](https://blog.diefunction.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://blog.diefunction.io/ctf/technology-control-company/blackhat-mea-2022/ctf-setup-on-kali-linux.md).

# CTF Setup on Kali linux

Simple local CTF environment on Kali Linux.

## Required for the environment

* [VMWare Workstation](https://www.vmware.com/)
* [Kali Linux](https://kali.download/virtual-images/kali-2022.3/kali-linux-2022.3-vmware-amd64.7z)
* [Docker](http://pkg.kali.org/pkg/docker.io)
* [Docker compose](http://pkg.kali.org/pkg/docker-compose)

### Install Kali linux on VMWare Workstation

[Kali linux image](https://kali.download/virtual-images/kali-2022.3/kali-linux-2022.3-vmware-amd64.7z) for VMWare to setup the CTF environment.\
[Default Kali Credentials](https://www.kali.org/docs/introduction/default-credentials/)\
Username: **kali**\
Password: **kali**

### Update the package index

```bash
sudo apt update
```

### [Install Docker](https://www.kali.org/docs/containers/installing-docker-on-kali/)

```bash
sudo apt install -y docker.io
sudo systemctl enable docker --now
sudo usermod -aG docker $USER
```

### Install Docker Compose

```bash
sudo apt install -y docker-compose
```

### Reboot the system

```bash
sudo reboot
```

## Recommended tools

* [Visual Studio Code](https://code.visualstudio.com/docs/?dv=linux64_deb)

### Install Visual Studio Code

[Click to download the debian package](https://code.visualstudio.com/docs/?dv=linux64_deb)

```bash
sudo dpkg -i ~/Downloads/code_1.73.1-1667967334_amd64.deb # current version 1.73.1-1667967334_amd64
```

#### Recommended VSCode Extensions

* [Docker](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-docker)
* [Python](https://marketplace.visualstudio.com/items?itemName=ms-python.python)
* [Dev Containers](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers)
* [ESLint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint)
* [SQLTools](https://marketplace.visualstudio.com/items?itemName=mtxr.sqltools)

## Create, and start containers for the CTF

{% file src="/files/xxKHZ5EXRObGwQunCXpR" %}
Download Challenges
{% endfile %}

Download and unzip the challenges.zip file.

```bash
unzip challenges.zip
cd tcc-blackhat
docker-compose up
```

### Careers

**IPAddress** 172.20.0.3\
**Port** 80\
**URL** <http://172.20.0.3/>

### SOC Complaints

**IPAddress** 172.20.0.4\
**Port** 80\
**URL** <http://172.20.0.4/>


---

# 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://blog.diefunction.io/ctf/technology-control-company/blackhat-mea-2022/ctf-setup-on-kali-linux.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.
