Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/GoFetchAD/GoFetch

GoFetch is a tool to automatically exercise an attack plan generated by the BloodHound application.
https://github.com/GoFetchAD/GoFetch

active-directory blackhat2017 bloodhound gofetch powershell security

Last synced: 24 days ago
JSON representation

GoFetch is a tool to automatically exercise an attack plan generated by the BloodHound application.

Awesome Lists containing this project

README

        

# GoFetch

GoFetch is a tool to automatically exercise an attack plan generated by the [BloodHound](https://github.com/BloodHoundAD/BloodHound) application.

GoFetch first loads a path of local admin users and computers generated by BloodHound and converts it to its own attack plan format. Once the attack plan is ready, GoFetch advances towards the destination according to plan step by step, by successively applying remote code execution techniques and compromising credentials with Mimikatz.

[Watch Invoke-GoFetch in action](https://youtu.be/5SpDAxUx7Uk)

#### GoFetch has two different versions:

##### Chain reaction:
Invoke-GoFetch (written in PowerShell to avoid Python installation prereq), implements a recursion that reads the full path, dumps the relevant credentials with Invoke-Mimikatz, and then copy and execute itself using Invoke-PsExec on the next relevant machine guided by the network path.

##### One computer to rule them all:
Python based code ([a video of this version demonstrated at BlackHat Europe 2016](https://www.youtube.com/watch?v=dPsLVE0R1Tg)), using a technique where one centralized computer is doing the job of connecting to each computer in the path, in the right order, to steal credentials (using Mimikatz), and use them to connect to the next machine in the path.

## Getting started with Invoke-GoFetch

Place GoFetch folder on the first machine of the attack path, in a session of the first user.

### Parameters

* -PathToGraph -
Path to the BloodHound exported Graph which includes a path between two users.

* -PathToPayload (optional) -
Path to local payload file .exe/.bat/.ps1 to run on next nodes in the path.

### Examples
* Usage to get the credentials along the path:
```
.\Invoke-GoFetch.ps1 -PathToGraph .\pathFromBloodHound.json
```
* Usage to get the credentails along the path and execute additional payload on each:
```
.\Invoke-GoFetch.ps1 -PathToGraph .\graphExample.json -PathToPayload .\payload.exe
```

### Prerequisites

* Invoke-GoFetch is able to run from any version of Windows through Windows 7 that has PowerShell v2 or higher installed and .Net 3.5 or higher.
* Invoke-Mimikatz - is included with a change in the Mimikatz DLL which allows the execution of the PowerShell file with additional arguments.
* Invoke-Psexec - is included without changes.

## Logic

![Alt text](https://cloud.githubusercontent.com/assets/27280621/26783367/770afb40-4a00-11e7-8dc1-d45919d0b551.JPG "Invoke-GoFetch Logic")

## Contributers
* [Itai Grady](https://twitter.com/ItaiGrady) - *Changes in Mimikatz DLL & C.R*
* [Man Nguyen (usrid0)]() - *Testing & Demo Video*
* [Tal Be'ery](https://twitter.com/TalBeerySec) - *Name & Original Idea*
* [Dan Mor](https://twitter.com/danmor84) - *Logo*
* [Tal Maor](https://twitter.com/TaltheMaor) - *Code*

See also the list of [contributors](https://github.com/GoFetchAD/GoFetch/graphs/contributors) who participated in this project.

## Acknowledgments
Thanks for great tools that reminds us every day to secure our machines.
* [BloodHound](https://github.com/BloodHoundAD/BloodHound) - developed by [@_wald0](https://www.twitter.com/_wald0), [@CptJesus](https://twitter.com/CptJesus), and [@harmj0y](https://twitter.com/harmj0y).
* [Invoke-Mimikatz](https://github.com/PowerShellMafia/PowerSploit/blob/master/Exfiltration/Invoke-Mimikatz.ps1) - [@JosephBialek](https://twitter.com/JosephBialek)
* [Mimikatz](https://github.com/gentilkiwi/mimikatz) - [@gentilkiwi](https://twitter.com/gentilkiwi)
* [Invoke-PsExec](https://github.com/EmpireProject/Empire/blob/master/data/module_source/lateral_movement/Invoke-PsExec.ps1) - [@harmj0y](https://twitter.com/harmj0y)

## License

This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details