# Setting Up Caldera & Atomic Red-Team

## Installation <a href="#installation" id="installation"></a>

Start by cloning this repository recursively. This will pull all available plugins.

```
git clone https://github.com/mitre/caldera.git --recursive
```

From the root of this project, install the PIP requirements.

```
pip3 install -r requirements.txt
```

Before you can start the server we need to change some environment variables:

Edit the /caldera/conf/local.yml and change the following values:

* host: 192.168.1.5 - - Make this the IP you wish to hav the caldera agents connect to
* port: 8888 - - you should leave this but it can be edited
* exfil\_dir: /tmp
* memory: True
* plugins:
  * stockpile
  * sandcat
  * gui
  * chain

## Building Advanced Adversaries <a href="#building-advanced-adversaries" id="building-advanced-adversaries"></a>

In the caldera/plugins/stockpile/abilities folder you will find various skills grouped by the MITRE ATTACK Framework ( Defense Evasion, Lateral Movement, Credential Access, Etc). You can use the Caldera Workbook to quickly build custom adversaries to test controls:

Adding the Atomic Red Team to Caldera&#x20;

`git clone https://github.com/redcanaryco/atomic-red-team.git`

`git clone https://github.com/mitre/cti.git`

`git clone https://github.com/xenoscr/Atomic-Caldera.git`

Requirements

* Python 3.6.8+ with the following libraries installed
  * PyYAML
    * <https://pyyaml.org/wiki/PyYAML&#x20>;
  * STIX2
    * <https://github.com/oasis-open/cti-python-stix2&#x20>;
* Atomic-Caldera requires the following repositories be stored locally somewhere:
  * <https://github.com/redcanaryco/atomic-red-team> <https://github.com/mitre/cti&#x20>;

Install Requirements:

`pip install -r requirements.txt`&#x20;

Clone the Red Canary Atomic Red Team repository:

`git clone https://github.com/redcanaryco/atomic-red-team.git`&#x20;

Clone the MITRE CTI repository:

`git clone https://github.com/mitre/cti.git Usage Atomic-Caldera.py`&#x20;

Atomic-Caldera requires only two parameters to run. The input directory where the Red Canary Atomic Red Team “atomics” folder is located and the path to the MITRE CTI repository. The output folder option and CSV file options are optional, if they are not supplied, Atomic-Caldera will save these files in the current working directory.

Example

`./Atomic-Caldera.py -i ~/repos/atomic-red-team/atomics -c ~/repos/cti Update-AtomicVariables.py`&#x20;

Update-AtomicVariables requires only two parameters to run. The input directory containing the abilities YAML files that were generated by the Atomic-Caldera.py script and the path to the CSV file containing the variable values that will be used to populate the abilities YAML files. If the output option is not populated a new “abilities-updated” folder will be created in the same directory where the input source abilities are located.

Example

`./Update-AtomicVariables.py -i ~/working/abilities -c ~/working/atomic-variables.csv`

## References

{% embed url="<https://github.com/xenoscr/atomiccaldera>" %}


---

# Agent Instructions: 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://blog.dev4cloud.net/pentesting-and-red-teaming/setting-up-caldera-and-atomic-red-team.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.
