This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import requests | |
import threading | |
import base64 | |
from html.parser import HTMLParser | |
from http.server import BaseHTTPRequestHandler, HTTPServer | |
''' | |
Description: Reverse MSSQL shell through xp_cmdshell + certutil for exfiltration | |
Author: @xassiz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
go func() { | |
for { | |
err = rmq.Stream(cancelCtx) | |
if errors.Is(err, rabbitmq.ErrDisconnected) { | |
continue | |
} | |
break | |
} | |
}() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package rabbitmq | |
import ( | |
"context" | |
"encoding/json" | |
"errors" | |
"fmt" | |
"github.com/rs/zerolog" | |
"github.com/streadway/amqp" | |
"runtime" |