Necesito contraseña para proteger mi sitio web.

  • ad
  • Born
  • Born
  • No Avatar
  • Registrado: Jun 19, 2003
  • Mensajes: 1
  • Status: Offline

Nota Junio 19th, 2003, 9:16 pm

¿Puede alguien darme un script de Java que puede insertar en mi página web y sólo hacer que la gente con un cierto nombre de usuario que he hecho y una contraseña, entrar.
  • Anonymous
  • Bot
  • No Avatar
  • Registrado: 25 Feb 2008
  • Mensajes: ?
  • Loc: Ozzuland
  • Status: Online

Nota Junio 19th, 2003, 9:16 pm

  • Bigwebmaster
  • Site Admin
  • Site Admin
  • Avatar de Usuario
  • Registrado: Dic 20, 2002
  • Mensajes: 8925
  • Loc: Seattle, WA & Phoenix, AZ
  • Status: Offline

Nota Junio 19th, 2003, 10:46 pm

Trate de usar el texto siguiente:

Código: [ Select ]
<!-- ONE STEP TO INSTALL LOGIN CODER:

  1. Add the first code into the BODY of your HTML document -->

<!-- STEP ONE: Add the first code into the BODY of your HTML document -->

<BODY>

<center><table border=1>
<tr><form name=members><td rowspan=4>
<select name=memlist size=10 onChange="showmem(this.form)">

<!-- Original: Dion -->
<!-- Web Site: http://www.iinet.net.au/~biab/ -->

<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->

<!-- "member name | password | destination pagename |" -->
<option selected value="John Smith|password|mainpage|">John Smith
<option value="Peter Jones|theirpwd|endpages|">Peter Jones
<option value="Sue Brown|asdfvcxz|nowheres|">Sue Brown
<option value="Sally West|zaqxswde|logintop|">Sally West
</select></td>
<td align=right>User:</td><td><input type=hidden value="0" name=entry>
<input type=text name=memname size=8 value=""></td></tr>
<tr><td align=right>Password:</td><td><input type=text name=password size=8 maxlength=8><font size="-1"><-- Must be exactly 8 characters</font></td></tr>
<tr><td align=right>Page Name:</td><td><input type=text name=pagename size=8 maxlength=8><b>.html</b><font size="-1"><-- Must be exactly 8 characters</font></td></tr>
<tr><td colspan=2 align=center>
<input type=button value="New User" onclick="addnew(this.form);">
<input type=button value="Delete User" onclick="delthis(this.form);">
<input type=button value="Update/Show Coding" onclick="update(this.form); create(this.form);"></td></tr>
<tr><td colspan=3 align=center>
<input type=text size=60 name=message value="Note: Password/Page Name must be exactly 8 letters! (a-z)">
<input type=hidden name=num value=1></td>
</form></tr>
</table>
<hr size=2 width=75%>
<form name=js><textarea cols=75 rows=10 name=scrpt wrap=virtual>
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
var params=new Array(4);
var alpha="ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHI";
function check(form) {
which=form.memlist.selectedIndex;
choice = form.memlist.options[which].value+"|";
if (choice=="x|") {
alert("Please Select Your Name From The List");
return;
}
p=0;
for (i=0;i<3;i++) {
a=choice.indexOf("|",p);
params[i]=choice.substring(a,p);
p=a+1;
}
h1=makehash(form.pass.value,3);
h2=makehash(form.pass.value,10)+" ";
if (h1!=params[1]) {
alert("Incorrect Password!"); return; };
var page="";
for (var i=0;i<8;i++) {
letter=params[2].substring(i,i+1)
ul=letter.toUpperCase();
a=alpha.indexOf(ul,0);
a-=(h2.substring(i,i+1)*1);
if (a<0) a+=26;
page+=alpha.substring(a,a+1); };
top.location=page.toLowerCase()+".html";
}
function makehash(pw,mult) {
pass=pw.toUpperCase();
hash=0;
for (i=0;i<8;i++) {
letter=pass.substring(i,i+1);
c=alpha.indexOf(letter,0)+1;
hash=hash*mult+c;
}
return(hash);
}
// End -->
</script>
</textarea>
</form>
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
var params=new Array(4);
var script=document.js.scrpt.value;
document.js.scrpt.value="Create your users, their passwords, and their destination pages using the form above.\n\nThen, click 'Show Coding' to see the login HTML and JavaScript that you need to put on your page to password-protect your site with that info.\n\nQuestions about this script or how to put it on your site should be directed to it's author via email: dion@mailhub.omen.com.au\n\n*Honestly, we don't even totally understand this JavaScript!*";
var alpha="ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHI";
showmem(document.members);
function showmem(form) {
document.members.num.value=document.members.memlist.length;
var which=form.memlist.selectedIndex;
splt(form.memlist[which].value);
form.entry.value=which+1;
for (i=2;i<5;i++) {
form.elements[i].value=params[i-2]; };
}
function splt(choice) {
p=0;
for (i=0;i<3;i++) {
a=choice.indexOf("|",p);
params[i]=choice.substring(a,p);
p=a+1;
  }
}
function addnew(form) {
newmem=getfields(form);
var who=prompt("New User's Name:","");
form.memlist[form.memlist.length] = new Option(who, newmem, false, true);
if (navigator.appName=="Netscape") {
document.js.scrpt.value=script;
history.go(0);
}
else {
showmem(document.members);
  }
}
function getfields(form) {
newmem="";
for (i=2;i<5;i++) {
newmem+=form.elements[i].value+"|"; };
for (i=3;i<5;i++) {
a=form.elements[i];
for (k=0;k<8;k++) {
  }
}
return(newmem);
}
function delthis(form) {
if (confirm("Delete "+form.memname.value+"?")) {
form.memlist.options[form.entry.value-1]=null;
form.message.value=form.memname.value+" Deleted";
form.memlist.selectedIndex=0;
if (navigator.appName=="Netscape") {
document.js.scrpt.value=script;
history.go(0);
}
else {
showmem(document.members);
   }
  }
}
function update(form) {
msg="no";
a=form.elements[i];
for (k=0;k<8;k++) {
b=a.value.substring(k,k+1);
c=b.toUpperCase();
form.memlist[form.entry.value-1].value=getfields(form);
form.message.value=form.memname.value+"'s record was updated";
  }
}
function create(form) {

var html="<center><form name=login>\n";
html+="<table border=1 cellpadding=3>\n\n";
html+="<!-- Original: Dion -->\n";
html+="<!-- Web Site: http://www.iinet.net.au/~biab/ -->\n";
html+="<!-- This script and many more are available free online at -->\n";
html+="<!-- The JavaScript Source!! http://javascript.internet.com -->\n\n";
html+='<tr><td colspan=2 align=center><font size="+2">';
html+='<b>Members-Only Area!</b></font></td></tr>\n';
html+="<tr><td>Username:</td><td><select name=memlist>\n<option value='x'>";
for (j=0;j<form.memlist.length;j++) {
splt(form.memlist.options[j].value);
h1=makehash(params[1],3);
h2=makehash(params[1],10)+" ";
var page="";
for (var i=0;i<8;i++) {
letter=params[2].substring(i,i+1);
ul=letter.toUpperCase();
a=alpha.indexOf(ul,0);
a+=(h2.substring(i,i+1)*1);
page+=alpha.substring(a,a+1);
}
html+="\n<option value='"+params[0]+"|"+h1+"|"+page+"'>"+params[0];
};
html+="\n</select></td></tr>\n";
html+="<tr><td>Password:</td><td><input type=password size=10 maxlength=8 name=pass></td></tr>\n";
html+='<tr><td colspan=2 align=center><input type=button value="Login" onclick="check(this.form)"></td>\n';
html+="</tr>\n</table>\n</form>\n";
document.js.scrpt.value=html+script+"</center>";
}
function makehash(pw,mult) {
pass=pw.toUpperCase();
hash=0;
for (i=0;i<8;i++) {
letter=pass.substring(i,i+1);
c=alpha.indexOf(letter,0)+1;
hash=hash*mult+c;
}
return(hash);
}
// End -->
</script>
</center>

<p><center>
<font face="arial, helvetica" size="-2">Free JavaScripts provided<br>
by <a href="http://javascriptsource.com">The JavaScript Source</a></font>
</center><p>

<!-- Script Size: 6.50 KB -->
  1. <!-- ONE STEP TO INSTALL LOGIN CODER:
  2.   1. Add the first code into the BODY of your HTML document -->
  3. <!-- STEP ONE: Add the first code into the BODY of your HTML document -->
  4. <BODY>
  5. <center><table border=1>
  6. <tr><form name=members><td rowspan=4>
  7. <select name=memlist size=10 onChange="showmem(this.form)">
  8. <!-- Original: Dion -->
  9. <!-- Web Site: http://www.iinet.net.au/~biab/ -->
  10. <!-- This script and many more are available free online at -->
  11. <!-- The JavaScript Source!! http://javascript.internet.com -->
  12. <!-- "member name | password | destination pagename |" -->
  13. <option selected value="John Smith|password|mainpage|">John Smith
  14. <option value="Peter Jones|theirpwd|endpages|">Peter Jones
  15. <option value="Sue Brown|asdfvcxz|nowheres|">Sue Brown
  16. <option value="Sally West|zaqxswde|logintop|">Sally West
  17. </select></td>
  18. <td align=right>User:</td><td><input type=hidden value="0" name=entry>
  19. <input type=text name=memname size=8 value=""></td></tr>
  20. <tr><td align=right>Password:</td><td><input type=text name=password size=8 maxlength=8><font size="-1"><-- Must be exactly 8 characters</font></td></tr>
  21. <tr><td align=right>Page Name:</td><td><input type=text name=pagename size=8 maxlength=8><b>.html</b><font size="-1"><-- Must be exactly 8 characters</font></td></tr>
  22. <tr><td colspan=2 align=center>
  23. <input type=button value="New User" onclick="addnew(this.form);">
  24. <input type=button value="Delete User" onclick="delthis(this.form);">
  25. <input type=button value="Update/Show Coding" onclick="update(this.form); create(this.form);"></td></tr>
  26. <tr><td colspan=3 align=center>
  27. <input type=text size=60 name=message value="Note: Password/Page Name must be exactly 8 letters! (a-z)">
  28. <input type=hidden name=num value=1></td>
  29. </form></tr>
  30. </table>
  31. <hr size=2 width=75%>
  32. <form name=js><textarea cols=75 rows=10 name=scrpt wrap=virtual>
  33. <SCRIPT LANGUAGE="JavaScript">
  34. <!-- Begin
  35. var params=new Array(4);
  36. var alpha="ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHI";
  37. function check(form) {
  38. which=form.memlist.selectedIndex;
  39. choice = form.memlist.options[which].value+"|";
  40. if (choice=="x|") {
  41. alert("Please Select Your Name From The List");
  42. return;
  43. }
  44. p=0;
  45. for (i=0;i<3;i++) {
  46. a=choice.indexOf("|",p);
  47. params[i]=choice.substring(a,p);
  48. p=a+1;
  49. }
  50. h1=makehash(form.pass.value,3);
  51. h2=makehash(form.pass.value,10)+" ";
  52. if (h1!=params[1]) {
  53. alert("Incorrect Password!"); return; };
  54. var page="";
  55. for (var i=0;i<8;i++) {
  56. letter=params[2].substring(i,i+1)
  57. ul=letter.toUpperCase();
  58. a=alpha.indexOf(ul,0);
  59. a-=(h2.substring(i,i+1)*1);
  60. if (a<0) a+=26;
  61. page+=alpha.substring(a,a+1); };
  62. top.location=page.toLowerCase()+".html";
  63. }
  64. function makehash(pw,mult) {
  65. pass=pw.toUpperCase();
  66. hash=0;
  67. for (i=0;i<8;i++) {
  68. letter=pass.substring(i,i+1);
  69. c=alpha.indexOf(letter,0)+1;
  70. hash=hash*mult+c;
  71. }
  72. return(hash);
  73. }
  74. // End -->
  75. </script>
  76. </textarea>
  77. </form>
  78. <SCRIPT LANGUAGE="JavaScript">
  79. <!-- Begin
  80. var params=new Array(4);
  81. var script=document.js.scrpt.value;
  82. document.js.scrpt.value="Create your users, their passwords, and their destination pages using the form above.\n\nThen, click 'Show Coding' to see the login HTML and JavaScript that you need to put on your page to password-protect your site with that info.\n\nQuestions about this script or how to put it on your site should be directed to it's author via email: dion@mailhub.omen.com.au\n\n*Honestly, we don't even totally understand this JavaScript!*";
  83. var alpha="ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHI";
  84. showmem(document.members);
  85. function showmem(form) {
  86. document.members.num.value=document.members.memlist.length;
  87. var which=form.memlist.selectedIndex;
  88. splt(form.memlist[which].value);
  89. form.entry.value=which+1;
  90. for (i=2;i<5;i++) {
  91. form.elements[i].value=params[i-2]; };
  92. }
  93. function splt(choice) {
  94. p=0;
  95. for (i=0;i<3;i++) {
  96. a=choice.indexOf("|",p);
  97. params[i]=choice.substring(a,p);
  98. p=a+1;
  99.   }
  100. }
  101. function addnew(form) {
  102. newmem=getfields(form);
  103. var who=prompt("New User's Name:","");
  104. form.memlist[form.memlist.length] = new Option(who, newmem, false, true);
  105. if (navigator.appName=="Netscape") {
  106. document.js.scrpt.value=script;
  107. history.go(0);
  108. }
  109. else {
  110. showmem(document.members);
  111.   }
  112. }
  113. function getfields(form) {
  114. newmem="";
  115. for (i=2;i<5;i++) {
  116. newmem+=form.elements[i].value+"|"; };
  117. for (i=3;i<5;i++) {
  118. a=form.elements[i];
  119. for (k=0;k<8;k++) {
  120.   }
  121. }
  122. return(newmem);
  123. }
  124. function delthis(form) {
  125. if (confirm("Delete "+form.memname.value+"?")) {
  126. form.memlist.options[form.entry.value-1]=null;
  127. form.message.value=form.memname.value+" Deleted";
  128. form.memlist.selectedIndex=0;
  129. if (navigator.appName=="Netscape") {
  130. document.js.scrpt.value=script;
  131. history.go(0);
  132. }
  133. else {
  134. showmem(document.members);
  135.    }
  136.   }
  137. }
  138. function update(form) {
  139. msg="no";
  140. a=form.elements[i];
  141. for (k=0;k<8;k++) {
  142. b=a.value.substring(k,k+1);
  143. c=b.toUpperCase();
  144. form.memlist[form.entry.value-1].value=getfields(form);
  145. form.message.value=form.memname.value+"'s record was updated";
  146.   }
  147. }
  148. function create(form) {
  149. var html="<center><form name=login>\n";
  150. html+="<table border=1 cellpadding=3>\n\n";
  151. html+="<!-- Original: Dion -->\n";
  152. html+="<!-- Web Site: http://www.iinet.net.au/~biab/ -->\n";
  153. html+="<!-- This script and many more are available free online at -->\n";
  154. html+="<!-- The JavaScript Source!! http://javascript.internet.com -->\n\n";
  155. html+='<tr><td colspan=2 align=center><font size="+2">';
  156. html+='<b>Members-Only Area!</b></font></td></tr>\n';
  157. html+="<tr><td>Username:</td><td><select name=memlist>\n<option value='x'>";
  158. for (j=0;j<form.memlist.length;j++) {
  159. splt(form.memlist.options[j].value);
  160. h1=makehash(params[1],3);
  161. h2=makehash(params[1],10)+" ";
  162. var page="";
  163. for (var i=0;i<8;i++) {
  164. letter=params[2].substring(i,i+1);
  165. ul=letter.toUpperCase();
  166. a=alpha.indexOf(ul,0);
  167. a+=(h2.substring(i,i+1)*1);
  168. page+=alpha.substring(a,a+1);
  169. }
  170. html+="\n<option value='"+params[0]+"|"+h1+"|"+page+"'>"+params[0];
  171. };
  172. html+="\n</select></td></tr>\n";
  173. html+="<tr><td>Password:</td><td><input type=password size=10 maxlength=8 name=pass></td></tr>\n";
  174. html+='<tr><td colspan=2 align=center><input type=button value="Login" onclick="check(this.form)"></td>\n';
  175. html+="</tr>\n</table>\n</form>\n";
  176. document.js.scrpt.value=html+script+"</center>";
  177. }
  178. function makehash(pw,mult) {
  179. pass=pw.toUpperCase();
  180. hash=0;
  181. for (i=0;i<8;i++) {
  182. letter=pass.substring(i,i+1);
  183. c=alpha.indexOf(letter,0)+1;
  184. hash=hash*mult+c;
  185. }
  186. return(hash);
  187. }
  188. // End -->
  189. </script>
  190. </center>
  191. <p><center>
  192. <font face="arial, helvetica" size="-2">Free JavaScripts provided<br>
  193. by <a href="http://javascriptsource.com">The JavaScript Source</a></font>
  194. </center><p>
  195. <!-- Script Size: 6.50 KB -->



Hay muchos más en esta lista: http://javascript.internet.com/passwords/

Como se dice en esa página, tenga esto en cuenta:

Estas secuencias de comandos tratan todas las secuencias de comandos JavaScript Protección de contraseña. Son un intento de primaria de proteger a un sitio y no debe ser utilizada para proteger la información de alto secreto. Sirven sólo para mantener a los aficionados a cabo. Profesionales de TI pueden infiltrarse en esos sitios con estas formas de protección. Pero, de forma gratuita, lo hacen un buen trabajo.

Cualquier tipo de protección JavaScript puede ser roto o cortado, la mejor manera de proteger a sus páginas sería configurar el servidor para la protección de contraseña. Con los servidores web Apache usted puede hacer esto utilizando el archivo. Htaccess para establecer ciertos directorios de manera que necesitan una contraseña.
Ozzu Hosting - Want your website on a fast server like Ozzu?
  • b_heyer
  • Web Master
  • Web Master
  • Avatar de Usuario
  • Registrado: Jun 15, 2003
  • Mensajes: 4583
  • Loc: Maryland
  • Status: Offline

Nota Junio 20th, 2003, 1:52 pm

si usted tiene un pago de utilizar una cuenta. htaccess y. htpassword archivo, búsqueda de google. htaccess tutoriales, entonces sólo plop en el directorio que desea proteger.
Pixel Acres V2
  • Bigwebmaster
  • Site Admin
  • Site Admin
  • Avatar de Usuario
  • Registrado: Dic 20, 2002
  • Mensajes: 8925
  • Loc: Seattle, WA & Phoenix, AZ
  • Status: Offline

Nota Junio 20th, 2003, 1:59 pm

O visite este puesto para obtener más información acerca de la protección de contraseña de su sitio web con la extensión. Htaccess disposición:

http://www.ozzu.com/viewtopic.php?p=4229
Ozzu Hosting - Want your website on a fast server like Ozzu?
  • MediaDesign
  • Loser
  • Loser
  • Avatar de Usuario
  • Registrado: Jun 05, 2003
  • Mensajes: 129
  • Loc: somewhere
  • Status: Offline

Nota Junio 27th, 2003, 12:22 pm

¿qué medidas de protección de su sitio web

¿quiere área protegida
o proteger un archivo o un repertorio?


con ASP PHP Perl?
Java
  • andy007
  • Born
  • Born
  • No Avatar
  • Registrado: Jul 17, 2003
  • Mensajes: 2
  • Loc: China
  • Status: Offline

Nota Julio 17th, 2003, 7:01 pm

¿Qué tipo de servidores, ¿tienes? Web? FTP? mail? o Samba?
Usted no necesita un script. Sólo utilizar el servicio de configuración.
  • jlbrennan20
  • Born
  • Born
  • No Avatar
  • Registrado: Ago 26, 2003
  • Mensajes: 2
  • Status: Offline

Nota Agosto 26th, 2003, 3:08 am

do u chicos ahora cualquier webhost gratuito que le permite el uso de. htaccess?
  • centix
  • Newbie
  • Newbie
  • No Avatar
  • Registrado: Sep 13, 2003
  • Mensajes: 5
  • Status: Offline

Nota Septiembre 13th, 2003, 8:36 pm

andy007 escribió:
¿Qué tipo de servidores, ¿tienes? Web? FTP? mail? o Samba?
Usted no necesita un script. Sólo utilizar el servicio de configuración.


¿qué entendemos por servicio de configuración?
  • mikeruss
  • Born
  • Born
  • No Avatar
  • Registrado: Ene 23, 2005
  • Mensajes: 2
  • Status: Offline

Nota Enero 23rd, 2005, 3:30 pm

Pruebe esto?

http://www.mikeruss.dircon.co.uk/htaccess/
  • tgurl
  • Born
  • Born
  • No Avatar
  • Registrado: Jul 01, 2005
  • Mensajes: 1
  • Status: Offline

Nota Julio 1st, 2005, 3:04 pm

También estoy tratando de proteger un sitio web y han estado tratando de utilizar el. Htacces archivo para hacer esto. No es de trabajo, así que debe estar haciendo algo mal. Hice los archivos, asegúrese de que todo está en orden ", plopped" en el directorio. El abrir el directorio en un navegador web y nada. ¿Cómo funciona el archivo html leer el archivo. Haccess código? Estoy todavía en una pérdida en cuanto a cómo esto se supone que debe suceder para que si alguien entiende cómo esta obra Le agradecería su ayuda.

tgurl

Publicar Información

  • Total de mensajes en este tema: 10 mensajes
  • Usuarios navegando por este Foro: No hay usuarios registrados visitando el Foro y 317 invitados
  • No puede abrir nuevos temas en este Foro
  • No puede responder a temas en este Foro
  • No puede editar sus mensajes en este Foro
  • No puede borrar sus mensajes en este Foro
  • No puede enviar adjuntos en este Foro
 
 

© 2011 Unmelted, LLC. Ozzu® es una marca registrada de Unmelted, LLC