BloodHound for Beginners: How to Find Active Directory Attack Paths

Every Active Directory attack post eventually says "BloodHound showed a GenericWrite edge" as if that's obvious. If you're new to AD, it isn't. This post is the beginner's guide: what BloodHound does, how to collect data in a lab, which queries to run first, and how to read the edges that actually lead somewhere.

Collect only from environments you own or are authorized to test. BloodHound data is a map of the client's identity infrastructure. Handle it like sensitive data.

What BloodHound is

BloodHound is a graph tool. A collector pulls users, groups, computers, sessions, ACLs, GPOs and trusts from Active Directory. BloodHound loads them into a graph database and lets you ask questions like "what's the shortest path from this user to Domain Admins?".

The point isn't the pretty graph. Active Directory permissions are layered and inherited, and no human reads thousands of ACLs. BloodHound turns that into paths you can follow, and defenders can use the same paths to fix things.

There are two main versions: legacy BloodHound and BloodHound Community Edition (CE), which runs in Docker and is the one being actively developed. Use a collector version that matches the BloodHound you run.

Collecting data

From Linux with a domain account, use the Python collector (bloodhound.py / its CE version):

bloodhound-python -u lowpriv -p 'Password1' -d corp.local -ns 10.10.10.10 -c All --zip

NetExec can also collect over LDAP:

netexec ldap 10.10.10.10 -u lowpriv -p 'Password1' --bloodhound -c All --dns-server 10.10.10.10

From a domain-joined Windows host, SharpHound is the official collector:

SharpHound.exe -c All --zipfilename corp.zip

-c All is noisy because it touches every computer for sessions and local groups. On a real engagement, start with DCOnly (LDAP only, talks only to the DC) and add session collection later if it's in scope.

Upload the zip in the BloodHound UI.

First things to do after importing

  1. Mark what you own. Search your user and mark it as Owned. Everything else is relative to that.
  2. Shortest paths from owned principals to Domain Admins or other high-value targets.
  3. Kerberoastable users, especially ones with paths to admin. That leads straight to Kerberoasting.
  4. AS-REP roastable users (pre-auth disabled). See AS-REP Roasting explained.
  5. Principals with DCSync rights. Anything other than DCs and the default admin groups is a finding. See DCSync explained.

Reading the edges

An edge is a relationship you can abuse. The ones you'll see most:

  • MemberOf: group membership. Not an attack by itself, but rights flow through it.
  • GenericAll: full control over the object. On a user you can reset the password, set an SPN for targeted Kerberoasting, or add Shadow Credentials. On a group you can add members.
  • GenericWrite: write most attributes. On a user, enough for targeted Kerberoasting (set an SPN), targeted AS-REP Roasting, or Shadow Credentials.
  • AddKeyCredentialLink: write msDS-KeyCredentialLink, which is exactly Shadow Credentials.
  • ForceChangePassword: reset the user's password without knowing the old one. Works, but it's loud and locks the real user out. Agree with the client before using it.
  • WriteDacl / WriteOwner: change the object's permissions or owner, then grant yourself GenericAll.
  • AdminTo: local admin on a computer. Combined with HasSession from an admin, that's a credential-theft path.
  • CanRDP / CanPSRemote / ExecuteDCOM: ways to run code on a host, not necessarily as admin.

Right-click an edge in BloodHound and open the help. It explains the abuse with commands for Windows and Linux, plus OPSEC notes.

Avoid rabbit holes

BloodHound will show you a lot of paths. Prefer the short ones that don't need a password reset or a reboot. Check that the path still works before building on it: sessions go stale, and group memberships change. And write down every change you make, so you can undo it and put it in the report.

BloodHound for defenders

Run it on your own domain. The same queries show you who can reach Tier 0. Fix the paths with the most users behind them first: one bad ACL on a group that Domain Users belongs to can matter more than ten exotic paths.

Detection

  • SharpHound session collection connects to many hosts over SMB and calls NetSessionEnum and NetWkstaUserEnum. Lots of connections from one workstation in a short time stand out.
  • LDAP collection shows up as many large LDAP queries from a single account. Identity protection tools often alert on known collector query patterns.
  • Honey users with attractive names and an alert on any logon are cheap and effective.

FAQ

Do I need admin rights to run BloodHound?

No. Any authenticated domain user can read most of what BloodHound collects through LDAP. Session and local admin collection gives more data with more rights.

What is the difference between BloodHound and BloodHound CE?

BloodHound CE is the current, actively developed version. It runs in Docker with a web UI. Collectors and data formats differ between the two, so match the collector version to the one you use.

What does GenericWrite mean in BloodHound?

You can write most attributes on the target object. On a user that's usually enough for targeted Kerberoasting, targeted AS-REP Roasting or Shadow Credentials.

Get new AD attack write-ups

Kerberos, ADCS and HTB write-ups by email, with the detection side included. No spam. Unsubscribe in one click.