Created
October 4, 2020 04:33
-
-
Save bytehow/d7b36a46bb4ece2d95d7bb16bb84915b to your computer and use it in GitHub Desktop.
A bash script to run a python Ghidra script from the command line
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
GHIDRA_DIR=/path/to/Ghidra | |
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" | |
PROJECT_DIR=/path/to/project | |
PROJECT=<project name> | |
FILE=<file within project> | |
SCRIPT=<script path in relation to this script's dir> | |
$GHIDRA_DIR/support/analyzeHeadless $PROJECT_DIR \ | |
$PROJECT \ | |
-noanalysis \ | |
-process $FILE \ | |
-scriptPath $DIR \ | |
-postscript $SCRIPT |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment