SHARE
TWEET

Untitled

a guest Jun 15th, 2017 203 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var fs = require("fs"),
  2.     Steam = require("steam"),
  3.     SteamID = require("steamid"),
  4.     IntervalIntArray = {},
  5.     readlineSync = require("readline-sync"),
  6.     Protos = require("./protos/protos.js"),
  7.     CountReports = 0,
  8.     Long = require("long"),
  9.     SteamClients = {},
  10.     SteamUsers = {},
  11.     SteamGCs = {},
  12.     SteamFriends = {},
  13.     process = require("process"),
  14.     steamID = process.argv[2],
  15.     accounts_list_id = process.argv[3],
  16.     prefix = process.argv[4],
  17.     report_matchid = process.argv[5],
  18.  
  19.     ClientHello = 4006,
  20.     ClientWelcome = 4004;
  21.  
  22. var accounts = [];
  23.  
  24. var arrayAccountsTxt = fs.readFileSync("accounts_report/accounts_" + accounts_list_id +".txt").toString().split("\n");
  25. for (i in arrayAccountsTxt) {
  26.     var accInfo = arrayAccountsTxt[i].toString().trim().split(":");
  27.     var username = accInfo[0];
  28.     var password = accInfo[1];
  29.     accounts[i] = [];
  30.     accounts[i].push({
  31.         username: username,
  32.         password: password
  33.     });
  34. }
  35.  
  36. var size = 0;
  37. size = arrayAccountsTxt.length;
  38.  
  39. arrayAccountsTxt.forEach(processSteamReport);
  40.  
  41. function processSteamReport(element, indexElement, array) {
  42.     if (element != "") {
  43.         var account = element.toString().trim().split(":");
  44.         var account_name = account[0];
  45.         var password = account[1];
  46.         SteamClients[indexElement] = new Steam.SteamClient();
  47.         SteamUsers[indexElement] = new Steam.SteamUser(SteamClients[indexElement]);
  48.         SteamGCs[indexElement] = new Steam.SteamGameCoordinator(SteamClients[indexElement], 730);
  49.         SteamFriends[indexElement] = new Steam.SteamFriends(SteamClients[indexElement]);
  50.  
  51.         SteamClients[indexElement].connect();
  52.        
  53.         var sentryfile;
  54.         if(fs.existsSync(account_name + '.sentry')) {
  55.             sentryfile = fs.readFileSync(account_name + '.sentry');
  56.         }
  57.        
  58.         SteamClients[indexElement].on("connected", function() {
  59.             if(fs.existsSync(account_name + '.sentry')) {
  60.                 SteamUsers[indexElement].logOn({
  61.                     account_name: account_name,
  62.                     password: password,
  63.                     sha_sentryfile: sentryfile
  64.                 });
  65.             } else {
  66.                 SteamUsers[indexElement].logOn({
  67.                     account_name: account_name,
  68.                     password: password
  69.                 });
  70.             }
  71.         });
  72.  
  73.         SteamClients[indexElement].on("logOnResponse", function(res) {
  74.             if (res.eresult !== Steam.EResult.OK) {
  75.                 if (res.eresult == Steam.EResult.ServiceUnavailable) {
  76.                     console.log("\n[STEAM CLIENT - Login failed - STEAM IS DOWN!");
  77.                     SteamClients[indexElement].disconnect();
  78.                     process.exit();
  79.                 } else {
  80.                     CountReports++;
  81.                     if (CountReports == size)
  82.                     {
  83.                         console.log("\n\n"+ CountReports + " Reports for this faggot.\nThanks for using this Service!\nCredits for the Script to askwrite & TROLOLO");
  84.                         process.exit();
  85.                     }
  86.                     console.log("\n[STEAM CLIENT (" + account_name.substring(0, 4) + "**) - Login failed!" + res.eresult);
  87.                     SteamClients[indexElement].disconnect();
  88.                     SteamClients.splice(indexElement, 1);
  89.                     SteamFriends.splice(indexElement, 1);
  90.                     SteamGCs.splice(indexElement, 1);
  91.                     SteamUsers.splice(indexElement, 1);
  92.                     IntervalIntArray.splice(indexElement, 1);
  93.                 }
  94.             } else {
  95.                 SteamFriends[indexElement].setPersonaState(Steam.EPersonaState.Offline);
  96.  
  97.                 SteamUsers[indexElement].gamesPlayed({
  98.                     games_played: [{
  99.                         game_id: 730
  100.                     }]
  101.                 });
  102.  
  103.                 if (SteamGCs[indexElement]) {
  104.                     IntervalIntArray[indexElement] = setInterval(function() {
  105.                         SteamGCs[indexElement].send({
  106.                             msg: ClientHello,
  107.                             proto: {}
  108.                         }, new Protos.CMsgClientHello({}).toBuffer());
  109.                     }, 2000);
  110.                 } else {
  111.                     SteamClients[indexElement].disconnect();
  112.                     SteamClients.splice(indexElement, 1);
  113.                     SteamFriends.splice(indexElement, 1);
  114.                     SteamGCs.splice(indexElement, 1);
  115.                     SteamUsers.splice(indexElement, 1);
  116.                     IntervalIntArray.splice(indexElement, 1);
  117.                 }
  118.             }
  119.         });
  120.  
  121.         SteamClients[indexElement].on("error", function(err) {
  122.             console.log("[STEAM CLIENT - " + indexElement + "] Account is probably ingame! Logged out!\n" + err);
  123.             size = size - 1;
  124.             if (CountReports == size)
  125.             {
  126.                 console.log("\n\n"+ CountReports + " Reports for this faggot.\nThanks for using this Service!\nCredits for the Script to askwrite & TROLOLO");
  127.                 process.exit();
  128.             }
  129.             SteamClients[indexElement].disconnect();
  130.             SteamClients.splice(indexElement, 1);
  131.             SteamFriends.splice(indexElement, 1);
  132.             SteamGCs.splice(indexElement, 1);
  133.             SteamUsers.splice(indexElement, 1);
  134.             IntervalIntArray.splice(indexElement, 1);
  135.         });
  136.  
  137.         SteamGCs[indexElement].on("message", function(header, buffer, callback) {
  138.             switch (header.msg) {
  139.                 case ClientWelcome:
  140.                     clearInterval(IntervalIntArray[indexElement]);
  141.                     IntervalIntArray[indexElement] = setInterval(function() {
  142.                         sendReport(SteamGCs[indexElement], SteamClients[indexElement], account_name, steamID);
  143.                     }, 2000);
  144.                     break;
  145.                 case Protos.ECsgoGCMsg.k_EMsgGCCStrike15_v2_MatchmakingGC2ClientHello:
  146.                     break;
  147.                 case Protos.ECsgoGCMsg.k_EMsgGCCStrike15_v2_ClientReportResponse:
  148.                     CountReports++;
  149.                     console.log("[" + prefix + " - (" + CountReports + ")] Report with confirmation ID: " + Protos.CMsgGCCStrike15_v2_ClientReportResponse.decode(buffer).confirmationId.toString() + " sent!");
  150.                     if (CountReports == size)
  151.                     {
  152.                     console.log("\n\n"+ CountReports + " Reports for this faggot.\nThanks for using this Service!\nCredits for the Script to askwrite & TROLOLO");
  153.                     }
  154.                     clearInterval(IntervalIntArray[indexElement]);
  155.                     SteamClients[indexElement].disconnect();
  156.                     SteamClients.splice(indexElement, 1);
  157.                     SteamFriends.splice(indexElement, 1);
  158.                     SteamGCs.splice(indexElement, 1);
  159.                     SteamUsers.splice(indexElement, 1);
  160.                     IntervalIntArray.splice(indexElement, 1);
  161.                     break;
  162.                 default:
  163.                     console.log(header);
  164.                     break;
  165.             }
  166.         });
  167.     }
  168. }
  169.  
  170. function sendReport(GC, Client, account_name) {
  171.     var account_id = new SteamID(steamID).accountid;
  172.     GC.send({
  173.         msg: Protos.ECsgoGCMsg.k_EMsgGCCStrike15_v2_ClientReportPlayer,
  174.         proto: {}
  175.     }, new Protos.CMsgGCCStrike15_v2_ClientReportPlayer({
  176.         accountId: account_id,
  177.         matchId: report_matchid,
  178.         rptAimbot: 2,
  179.         rptWallhack: 3,
  180.         rptSpeedhack: 4,
  181.         rptTeamharm: 5,
  182.         rptTextabuse: 6,
  183.         rptVoiceabuse: 7
  184.     }).toBuffer());
  185. }
  186.  
  187. process.on("uncaughtException", function(err) {
  188. fs.writeFile('error_logs/' + steamID + '.txt', err);
  189. });
  190.  
  191.  
  192. console.log("Reporting SteamID: " + steamID + "\nStarting Accounts...\nUsing Reportbot #" + accounts_list_id);
  193. if ( report_matchid != 8){
  194.     console.log("Using MatchID: " + report_matchid + "\n");
  195. } else {
  196.     console.log("No MatchID provided \n");
  197. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top