Skip to content

Commit

Permalink
Update Psbdmp method
Browse files Browse the repository at this point in the history
Code cleaned
  • Loading branch information
calganaygun committed Nov 26, 2020
1 parent 51bcf44 commit 843e2ac
Showing 1 changed file with 8 additions and 13 deletions.
21 changes: 8 additions & 13 deletions modules/Psbdmp.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,12 @@
def Psbdmp(mail,_verbose=None):
if _verbose != None:
try:
headers = {
"Accept": "application/json"
}
print(f"{bcolors.WARNING} -- Scanning Pastebin Dumps...{bcolors.ENDC}")
print("")
psbdmpurl = "https://psbdmp.ws/api/search/"
u = (psbdmpurl+mail)
response = requests.get(u,headers=headers)
html = response.content
lp = json.loads(html)
for i in lp['data']:
print(f"{bcolors.OKGREEN}|-- {bcolors.ENDC}"+"https://pastebin.com/"+i['id'])
print(f"{bcolors.WARNING} -- Scanning Pastebin Dumps...{bcolors.ENDC}\n")
res = requests.get(f"https://psbdmp.ws/api/search/{mail}",headers={ "Accept": "application/json" }).json().get('data') or []
if len(res):
for i in res:
print(f"{bcolors.OKGREEN}|-- {bcolors.ENDC}"+"https://pastebin.com/"+i['id'])
else:
print(f"{bcolors.FAIL}No psbdump records found!{bcolors.ENDC}")
except:
print(f"{bcolors.FAIL}Dump not found!{bcolors.ENDC}")
print(f"{bcolors.FAIL}Psbdump Error!{bcolors.ENDC}")

0 comments on commit 843e2ac

Please sign in to comment.