PDA

View Full Version : Encrypted Password



yoshi555
01-08-2007, 01:26 AM
1) Script Title: Encrypted Password

2) Script URL (on DD): http://dynamicdrive.com/dynamicindex9/emailscrambler.htm

3) Describe problem: When i login its not taking me to the right page just at the bottom it says done but with errors

djr33
01-08-2007, 01:37 AM
Please link to your page so we can see what's going on.

Feel free to change the password for this example so you don't need to give us the real one.

yoshi555
01-08-2007, 01:39 AM
I am using this code i cant link to the page because its on my computer:
<script>
//Encrypted Password script- By Rob Heslop
//Script featured on Dynamic Drive
//Visit http://www.dynamicdrive.com

function submitentry(){
password = document.password1.password2.value.toLowerCase()
username = document.password1.username2.value.toLowerCase()
passcode = 1
usercode = 1
for(i = 0; i < password.length; i++) {
passcode *= password.charCodeAt(i);
}
for(x = 0; x < username.length; x++) {
usercode *= username.charCodeAt(x);
}
//CHANGE THE NUMBERS BELOW TO REFLECT YOUR USERNAME/PASSWORD
if(usercode==134603040&&passcode==126906300)
//CHANGE THE NUMBERS ABOVE TO REFLECT YOUR USERNAME/PASSWORD
{
window.location=password+".htm"}
else{
alert("password/username combination wrong")}
}
</script>

<form name="password1">
<strong>Enter username: </strong>
<input type="text" name="username2" size="15">
<br>
<strong>Enter password: </strong>
<input type="password" name="password2" size="15">

<input type="button" value="Submit" onClick="submitentry()">
</form>

djr33
01-08-2007, 01:44 AM
That might be part of it. Some browsers disable javascript when on a local computer. You need the 'mark of the web' (which is easiest to get by just putting it on the web).

Hmm.... seems like it should work from the code. But note that your password is right there. Heh. Easy to hack, anyway.

Twey
01-08-2007, 04:56 AM
I revamped (http://www.twey.co.uk/?q=encpass) this script quite a while ago.