I have often been frustrated when asked for character 3, 17 and 31 of my password. Perhaps I am victim of my own paranoia in setting passwords of such length. However, it is still somewhat of a chore to work out certain characters of a password. Even my password manager (1Password – which I highly recommend) is not up to this task.
So, I have created a simple script that enumerates passwords making it easy to discover corresponding characters. The script is entirely javascript & HTML, so it can be run as a file stored on your computer. This makes it more secure.
Obviously, even copying a password to your clipboard or typing it in can fall foul of malicious types but, for me, this is a calculated risk.
Click here to try my Password Enumerator Tool
And here is the code. You just need to save it as a .html file and open it in your web browser:
<html></head><title>Character at position</title>
<style>
body {font-size:150%;font-family:sans-serif;}
input {padding:8px;}
li span {display:block;font-size:80%;margin:0;padding:0 10px;text-align:center;background-color:#ccc;color:#555;cursor:s-resize;}
li {padding:0;border:1px solid #999;margin:4px;display:inline-block;text-align:center;color:#fff;font-family:monospace;}
#inst {display:none;}
</style>
<script>
function spanClick() {
this.parentNode.style.color="#444";
}
function enumerate(strInput){
var str=strInput.value;
var inst=document.getElementById("inst");
inst.style.display="none";
if(str.length>0){
inst.style.display="block";
}
var charNoList=document.getElementById("charNo");
while (charNoList.hasChildNodes()) {
charNoList.removeChild(charNoList.firstChild);
}
for(i=1;i<=str.length;i++){
var char=str.charAt(i-1);
var span=document.createElement("span");
span.addEventListener("click",spanClick);
var countNode=document.createTextNode(i);
span.appendChild(countNode);
var node=document.createElement("li");
var textnode=document.createTextNode(char);
node.appendChild(span);
node.appendChild(textnode);
charNoList.appendChild(node);
}
}
</script>
</head><body>
Enter/paste Password: <input type="password" id="str" onkeyup="enumerate(this);" onmouseup="enumerate(this);" onmouseout="enumerate(this);" oninput="enumerate(this);" />
<div id="inst">Click the characters required:
<ol id="charNo"></ol>
</div>
</body></html>