[MASM] SOCKS4 Server

  • War zum verbessern meiner ASM-skills gedacht.
    Benutzt viel MASM-spezifischen Lamer code ;)


    socks4.inc:

    Code
    1. .586.MODEL flat, stdcallOPTION CASEMAP:NONE ;Case sensitiveInclude windows.incInclude kernel32.incInclude masm32.incinclude wsock32.incIncludeLib kernel32.libIncludeLib masm32.libincludelib wsock32.libSOCKS4_REQUEST Struct ucVersion byte ? ucCommand byte ? wDestport word ? dwDestIp dword ?SOCKS4_REQUEST EndSMain PROTO;;macrosPrint_Text Macro txt:REQ ;;note txt is not a pointer Invoke StdOut,ADDR txtEndM.DATASOCKS_PORT DWord 8080;;;;;;;;;;;;;;;;;;;;;welcome DB "Welcome to the socks4 server by Hamtaro aka CorVu5: ",13,10, 0endmsg DB "socks4 quitted",0connection DB "SOCKS4 connection attempt!",13,10,"---------------------------",13,10,0senderror DB "Send error occured!",13,10,"---------------------------",13,10,0recverror DB "Recv error occured!",13,10,"---------------------------",13,10,0concon DB "Connection etablished",13,10,"---------------------------",13,10,0conclosed DB "Connection closed",13,10,"---------------------------",13,10,0conrcv1 DB "Data recvd from Client",13,10,"---------------------------",13,10,0conrcv2 DB "Data recvd from Tunnel",13,10,"---------------------------",13,10,0errstr DB 100 DUP (?)

    Socks4.asm


    Läuft in der Konsole, kann aber auch einfach zu einer Art Bouncer umfunktioniert werden
    Kompiliert exakt 4kb groÃ?