Last active
August 3, 2019 01:43
-
-
Save jankcat/fa81f78c18e4fd882fae3a0aaeb185f0 to your computer and use it in GitHub Desktop.
Match user+hash file with pass+hash file
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 | |
grep . users.txt | while read user; do | |
echo "$(echo $user | grep -o '^\S*' | grep -v '^$') $(cat pass.txt | grep "$(echo $user | grep -o '\s\S*' | grep -o '\S.*')" | grep -o '^\S*' | grep -v '^$' || echo -e "\033[2K\033[1A")" | |
done |
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
password1 a1a1a1a1 | |
password4 d2d2d2d2 | |
password2 b1b1b1b1 | |
password3 c1c1c1c1 | |
password5 a1b1c1d2 |
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
timwatkins a1a1a1a1 | |
taherazab b1b1b1b1 | |
greg d1d1d1d1 | |
mattdamon c1c1c1c1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment