summarylogtreecommitdiffstats
path: root/havoc_runner.sh
blob: 6a2dd435808a5154142b2678c35beb5fd4649503 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/env bash

# check if the havoc binary exists in the specified directory
if [[ -x /opt/Havoc/havoc ]]; then
  # save the current directory to return later
  original_dir=$(pwd)

  # change directory to /opt/Havoc and execute havoc binary with all the arguments
  pushd /opt/Havoc > /dev/null
  ./havoc "$@"

  # return to the original directory
  popd > /dev/null
else
  echo "havoc binary not found in /opt/Havoc"
  exit 1
fi