Create crowdstrike.sh

This commit is contained in:
SOCFortress
2022-08-20 09:55:05 -05:00
committed by GitHub
parent 7d9955ea30
commit f007a9f8dd

View File

@@ -0,0 +1,11 @@
#!/bin/bash
results_file=/tmp/crowdstrike.json
current_file=/tmp/crowdstrike_run.json
output_file=/tmp/crowdstrike_results.json
compare_file=/tmp/crowdstrike_compare.json
/usr/bin/cat /var/log/crowdstrike/falconhoseclient/output | /usr/bin/jq -c '.' > $current_file
/usr/bin/diff -u $compare_file $current_file > /tmp/results.patch
/usr/bin/patch $results_file /tmp/results.patch
/usr/bin/mv $current_file $compare_file