Sometimes you want to get a more recent version of BloodhoundAD than what apt gives you.
Navigate to opt:
~$ cd /opt
Remove outdated version if necessary:
/opt$ rm -rf Bloodhound
Clone Bloodhound with git:
/opt$ git clone https://github.com/BloodHoundAD/BloodHound.git
/opt$ cd Bloodhound
Locate a Windows exe, if you need to use it later:
/opt/Bloodhound$ find . | grep exe$
./Collectors/DebugBuilds/SharpHound.exe
./Collectors/SharpHound.exe
/opt/Bloodhound$ cp ./Collectors/SharpHound.exe ~/machines/windows/transfers
Get the latest version from BloodHound/releases and download the bloodhound x64 for Linux:
/opt/Bloodhound$ wget https://github.com/BloodHoundAD/BloodHound/releases/download/v4.3.1/BloodHound-linux-x64.zip
/opt/Bloodhound$ unzip BloodHound-linux-x64.zip
/opt/Bloodhound$ cd BloodHound-linux-x64
When you want to upgrade everything later to a new version, use git pull
and then download the latest x64 for linux again:
/opt/Bloodhound$ git pull
Install neo4j in a new terminal window, but first you might need to install some dependencies for neo4j. It will need cypher-shell and daemon. If you're not root, you'll need to use sudo for dpkg.
https://neo4j.com/download-center/#cypher-shell (copy the URL from their downloads)
~/Downloads$ wget https://dist.neo4j.org/cypher-shell/cypher-shell_5.5.0_all.deb?_ga=2.212902612.1927537219.1978625738-625982179.147872436
~/Downloads$ dpkg -i cypher-shell_5.5.0_all.deb
~/Downloads$ apt install daemon
neo4j.com/docs/operations-manual/current/installation/linux/debian/#debian-installation
neo4j.com/docs/operations-manual/current/installation/linux/debian/#debian-offline-installation
~/Downloads$ curl -O https://dist.neo4j.org/deb/neo4j_5.5.0_all.deb
~/Downloads$ dpkg -i neo4j_5.5.0_all.deb
Start up neo4j, load the localhost:7474, enter default pw/un (neo4j/neo4j) to log in and create a new password:
~$ neo4j console
After neo4j is up and running, start up Bloodhound:
/opt/Bloodhound/BloodHound-linux-x64$ ./BloodHound --no-sandbox
You should be able to login with the neo4j credentials.
Replace a forgotten password
I don't think too much about the passwords I create for neo4j so sometimes I'll have to reset it.
Before you start neo4j, open up this file and uncomment this line:
dbms.security.auth_enabled=false
~$ vim /etc/neo4j/neo4j.conf
Then start neo4j:
~$ sudo neo4j console
Use cypher-shell
to change the password. Locate it first, if you don't know where it is:
~$ locate cypher-shell
/usr/share/neo4j/bin/cypher-shell
/usr/share/neo4j/bin/cypher-shell -d system
@system> ALTER USER neo4j SET PASSWORD 'Your_New_Password';
@system> :exit;
Then stop neo4j, open up the neo4j.conf
and comment out the same line: dbms.security.auth_enabled=false:
~$ Stop neo4j
~$ vim /etc/neo4j/neo4j.conf
#dbms.security.auth_enabled=false
When you start neo4j again, it should ask you to log in with the new password you just set up.