Created
January 28, 2015 06:57
-
-
Save lrvick/4b29a465f6aaec737520 to your computer and use it in GitHub Desktop.
PAM NFC screen unlock helper script
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 characters
valid_hash=$( cat /home/lrvick/.nfcauth ) | |
challange_hash=$( printf $1 | shasum -a 256 | sed 's/ .*//' ) | |
echo $valid_hash | |
echo $challange_hash | |
if [ "$valid_hash" == "$challange_hash" ]; then | |
echo "unlocked" | |
killall slock | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment