Advertisement
Guest User

Untitled

a guest
Nov 28th, 2017
168
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.74 KB | None | 0 0
  1. <!-- Hackit Begins -->
  2. &nbsp; Aufgabe:
  3. <br><div class=quote style="width:75%;">
  4. <center><form name=login>
  5. <table border=1 cellpadding=3>
  6. <tr><td colspan=2 align=center>
  7. <font size="+2"><b>Members-Only Area!</b></font><br>
  8. Versuchen Sie sich als Benutzer Zero-Cool einzuloggen
  9. </td></tr>
  10. <tr><td>Username:</td><td><select name=memlist class=inputbox>
  11. <option value='x'>
  12. <option value='Sally|51896|FOVWLOOX'>Sally
  13. <option value='zerocool|21811|HWJJLKQL'>zerocool
  14. </select></td></tr>
  15. <tr><td>Password:</td><td><input type=password size=10 maxlength=8 name=pass class=inputbox></td></tr>
  16. <tr><td colspan=2 align=center><input type=button value="Login" onclick="check(this.form)" class=button></td>
  17. </tr>
  18. </table>
  19. </form>
  20. <SCRIPT LANGUAGE="JavaScript">
  21. <!-- Begin
  22. var params=new Array(4);
  23. var alpha="ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHI";
  24. function check(form) {
  25. which=form.memlist.selectedIndex;
  26. choice = form.memlist.options[which].value+"|";
  27. if (choice=="x|") {
  28. alert("Please Select Your Name From The List");
  29. return;
  30. }
  31. p=0;
  32. for (i=0;i<3;i++) {
  33. a=choice.indexOf("|",p);
  34. params[i]=choice.substring(a,p);
  35. p=a+1;
  36. }
  37. h1=makehash(form.pass.value,3);
  38. h2=makehash(form.pass.value,10)+" ";
  39. if (h1!=params[1]) {
  40. alert("Incorrect Password!"); return; };
  41. var page="";
  42. for (var i=0;i<8;i++) {
  43. letter=params[2].substring(i,i+1)
  44. ul=letter.toUpperCase();
  45. a=alpha.indexOf(ul,0);
  46. a-=(h2.substring(i,i+1)*1);
  47. if (a<0) a+=26;
  48. page+=alpha.substring(a,a+1); };
  49. top.location=page.toLowerCase()+".html";
  50. }
  51. function makehash(pw,mult) {
  52. pass=pw.toUpperCase();
  53. hash=0;
  54. for (i=0;i<8;i++) {
  55. letter=pass.substring(i,i+1);
  56. c=alpha.indexOf(letter,0)+1;
  57. hash=hash*mult+c;
  58. }
  59. return(hash);
  60. }
  61. // End -->
  62. </script>
  63. </center>
  64. </div>
  65. <!-- //Hackit Ends -->
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement