js_reverse/zy-方法栈/方法栈.md
2021-09-22 18:09:05 +08:00

1.6 KiB
Raw Blame History

方法栈 CALL Stack

  • 内存里面加载的fun方法

跟值

  • 加密函数一般情况下会是自定义js代码不会是jQuery或者Vue包内置的js方法。
  • 打断点时候会出现智能提示,智能提示出现的位置就是方法栈开始的位置
  • 智能提示不出现按ctrl按键

逆向理论

  • 短板效应:木桶效应

js请求 XMLHttpRequest

  • Ajax XMLHttpRequest对象的三个属性以及open和send方法js

  • AJAX-向服务器发送一个请求,要想把请求发送到服务器,我们就需要使用 open() 方法和 send() 方法

  • open()方法需要三个参数:第一个参数定义发送请求所使用的方法GET 还是 POST

  • 同步方式

      var xmlhttp=newXMLHttpRequestObj ();
    
      xmlhttp.open('post','xxx.asp?s=dc',false);
    
      xmlhttp.setRequestHeader('Content-type','application/x-www-form-urlencoded');
      xmlhttp.send(true);
    
      alert('do something.....')
    
  • 异步方式

      var sendStr='?a=1&b=2'; //url 的参数
    
      var xmlhttp=newXMLHttpRequestObj ();
      xmlhttp.onreadystatechange=function(){
          if (xmlhttp.readyState==4){    
              if(xmlhttp.status==200){
                 alert(xmlhttp.responseText);
                  //other.......
              }
          }
      }
      xmlhttp.open('post','xxx.asp',true);
      xmlhttp.setRequestHeader('Content-type','application/x-www-form-urlencoded');
      xmlhttp.send(sendStr);
    

需要注意的函数名称

  • Encrypt
  • data
  • key
  • des
  • toJSONString
  • ......