aboutsummaryrefslogtreecommitdiff
path: root/pwned.sh
diff options
context:
space:
mode:
authorN3V0N <navanchauhan@gmail.com>2017-07-29 15:58:47 +0530
committerGitHub <noreply@github.com>2017-07-29 15:58:47 +0530
commit41a1c70a728537f8bde01b0b94f7b29b8713b5c4 (patch)
tree27d898d5f28745dd9c82544cb125dd66269138f1 /pwned.sh
parentc5499e49d32a774fb73bde66114c84146a1b80d0 (diff)
The Magical Script
Diffstat (limited to 'pwned.sh')
-rw-r--r--pwned.sh28
1 files changed, 28 insertions, 0 deletions
diff --git a/pwned.sh b/pwned.sh
new file mode 100644
index 0000000..16d769f
--- /dev/null
+++ b/pwned.sh
@@ -0,0 +1,28 @@
+#!/bin/bash
+
+#set -x
+account=$1
+if [ "$1" == "-h" ];
+then
+echo Pwned Help
+echo Usage :
+echo -e "pwned -h \t /Shows Help"
+echo -e "pwned title@email.com \t \t /Gives Information "
+exit
+fi
+clear
+echo "Using Email $account"
+echo "If it is not in the format test@mail.com"
+echo "then press Ctrl+C and put it in the correct format"
+echo "Press enter to continue"
+
+read nothing
+echo "Checking if you have been Pwned"
+curl -s -o raw_data.json "https://haveibeenpwned.com/api/v2/breachedaccount/"$account""
+clear
+jq ".[]" raw_data.json > semi.json
+jq .Title semi.json > final.txt
+echo "You Have Been Pwned at/in/by"
+sed 's/\"//g' final.txt
+
+