Files
pRs3k 88e3bbf524 HSS Submission
HSS Version 1.0 commit to theSW4n repo
2023-09-28 20:05:15 -06:00

5 lines
529 B
Bash
Executable File

#!/bin/bash -x
# Run this script in the parent directory above the "backup" folder containing files you want to add to a checksums.txt list. Then take the checksums.txt file and place it in .../loot/hss/ to prevent the files from being copied to the .../loot/hss/backups/ directory the next time HSS is run.
find ./backup | while read p; do if cat ./checksums.txt | grep -qw `cksum "$(echo "$p" | tr -d '\')" | cut -d ' ' -f1`; then : ; else echo `cksum "$(echo "$p" | tr -d '\')" | cut -d ' ' -f1` >> ./checksums.txt; fi; done