-
-
Save mkvtvseries/9f89ca6b940b9980febcf70ac227e09d to your computer and use it in GitHub Desktop.
warpwallet cracker
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
function getRandomPassword(length) { | |
var charset = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; | |
var result = ""; | |
if (window.crypto && window.crypto.getRandomValues) { | |
values = new Uint32Array(length); | |
window.crypto.getRandomValues(values); | |
for(var i=0; i<length; i++) { | |
result += charset[values[i] % charset.length]; | |
} | |
return result; | |
} else throw new Error("Your browsercan't generate secure random numbers"); | |
} | |
function crack() { | |
var start = new Date().getTime(); | |
var candidate = getRandomPassword(8); | |
warpwallet.run({ | |
passphrase: candidate, | |
salt: 'a@b.c', | |
progress_hook: null, | |
params: window.params}, | |
function(res) { | |
if(res['public'] == '1MkupVKiCik9iyfnLrJoZLx9RH4rkF3hnA'){ | |
console.log("Found private key " + res['private'] + " and password " + candidate); | |
} else { | |
var end = (new Date().getTime() - start) / 1000; | |
console.log(res['public'] + " / " + candidate + " in " + end + "s"); | |
crack(); | |
} | |
}); | |
} | |
crack(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment