Created
January 17, 2019 17:39
-
-
Save xenithorb/0114200c02a8bc9952d829b99623f9f7 to your computer and use it in GitHub Desktop.
Revisions
-
xenithorb created this gist
Jan 17, 2019 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1 @@ while read -r line; do hash=$( awk -F'","' '{printf "%s", $4}' <<< "$line" | sha1sum | cut -d' ' -f1 ); hash=${hash^^}; if (curl -s "https://api.pwnedpasswords.com/range/${hash:0:5}" | grep -q "${hash:5}" ); then echo "$line"; fi; sleep 1; done < <( { tr -d '\n' < output.csv | sed -r -e 's|"(xenith_keepass)|\n"\1|g' -e 's|,,|,"",|g'; echo; } | tail -n+2)