joyce8/EMBER2024-capa huggingface dataset:
Function at 0x402510
Capabilities:
Connect pipe
Create pipe

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x128
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
movdqu xmm0, xmmword [str..pipePragmaIPC_]
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
mov esi, edx
mov dword [ebp - 0x128], eax
mov ebx, ecx
mov eax, dword [0x44eab0]
push 0xf0
mov dword [ebp - 0xf8], eax
lea eax, [ebp - 0xf4]
push 0
push eax
mov dword [ebp - 0x124], edi
movdqu xmmword [ebp - 0x108], xmm0
call fcn.0042bf20
push ebx
lea eax, [ebp - 0x108]
push 0x104
push eax
call fcn.00427b8d
add esp, 0x18
lea eax, [ebp - 0x108]
push edi
push 0
push 0
push 0
push 0xff
push 0
push 0x40000001
push eax
call dword [sym.imp.KERNEL32.dll_CreateNamedPipeA]
mov dword [esi], eax
cmp eax, 0xffffffff
jne 0x4025e4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
push str._s_Pipe_Creation_Failure.
mov esi, eax
push esi
push 1
push 1
push 0xe0000003
push str.TelnetServer
call fcn.00419930
add esp, 0x1c
mov dword [0x45a81c], esi
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
push 0
push 0
push 1
xorps xmm0, xmm0
mov dword [ebp - 0x110], 0
push 0
movdqu xmmword [ebp - 0x120], xmm0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov dword [ebp - 0x110], eax
lea eax, [ebp - 0x120]
push eax
push dword [esi]
call dword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x40266e
call edi
cmp eax, 0x3e5
je 0x40266e
cmp eax, 0x217
je 0x40266e
push ebx
push str._s_Pipe_Connect_Failure.
push eax
push 1
push 1
push 0xe0000003
push str.TelnetServer
call fcn.00419930
add esp, 0x1c
push dword [esi]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
push 0
push 0x40000080
push 3
push dword [ebp - 0x124]
lea eax, [ebp - 0x108]
push 2
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ecx, dword [ebp - 0x128]
mov dword [ecx], eax
cmp eax, 0xffffffff
jne 0x4026d8
push dword [esi]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call edi
push ebx
push str._s_Pipe_Connect_Failure.
push eax
push 1
push 1
push 0xe0000003
push str.TelnetServer
call fcn.00419930
add esp, 0x1c
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
push 1
lea eax, [ebp - 0x10c]
push eax
lea eax, [ebp - 0x120]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetOverlappedResult]
test eax, eax
jne 0x402708
call edi
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004265fb
mov esp, ebp
pop ebp
ret
Function at 0x404560
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push edi
mov edi, dword [ebp + 8]
mov eax, ecx
mov dword [ebp - 4], eax
mov ebx, edx
test edi, edi
je 0x40458d
push 0
push edi
push ebx
push eax
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
je 0x404598
add ebx, eax
sub edi, eax
mov eax, dword [ebp - 4]
jne 0x404574
pop edi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret
push esi
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push 0
mov esi, eax
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp esi, 0x2733
jne 0x4045dc
mov esi, dword [sym.imp.WS2_32.dll_send]
push 0
push edi
push ebx
push dword [ebp - 4]
call esi
cmp eax, 0xffffffff
jne 0x4045dc
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x4045dc
push 5
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x4045b7
pop esi
pop edi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4045f0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
cmp byte [0x45a54d], 0
mov eax, dword [0x45a96c]
push ebx
push edi
mov edi, dword [ebp + 0xc]
mov ebx, eax
mov dword [ebp - 8], 0
je 0x40462e
pop edi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 8]
mov edx, dword [0x45a938]
push esi
cmp ecx, edx
je 0x404671
cmp ecx, eax
je 0x404673
cmp ecx, dword [0x45aa7c]
je 0x404673
test ecx, ecx
je 0x404673
mov esi, dword [ebp + 0x10]
test esi, esi
je 0x4046cf
push esi
mov edx, edi
call fcn.00404560
add esp, 4
mov eax, esi
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
mov ebx, edx
cmp dword [0x45aa80], 0
mov esi, dword [ebp + 0x10]
je 0x404692
cmp ebx, eax
jne 0x404692
push esi
push edi
push 0x45a828
call fcn.0041c5b0
add esp, 0xc
push 0
push dword [0x45af78]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x4046cf
push 0
lea eax, [ebp - 8]
push eax
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [0x45a958]
test ecx, ecx
je 0x4046cc
test esi, esi
je 0x4046cc
push esi
mov edx, edi
call fcn.00404560
add esp, 4
mov esi, dword [ebp - 8]
mov ecx, dword [ebp - 4]
mov eax, esi
pop esi
pop edi
xor ecx, ebp
pop ebx
call fcn.004265fb
mov esp, ebp
pop ebp
ret
Function at 0x4046f0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x408
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 8]
lea eax, [ebp - 0x404]
push 0x400
push eax
call fcn.00427a37
add esp, 0x10
mov dword [ebp - 0x408], eax
cmp eax, 0xffffffff
je 0x404782
push 0
lea ecx, [ebp - 0x408]
push ecx
push eax
lea eax, [ebp - 0x404]
push eax
push dword [0x45a96c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [0x45a958]
mov eax, dword [ebp - 0x408]
test ecx, ecx
je 0x404782
test eax, eax
je 0x404782
push eax
lea edx, [ebp - 0x404]
call fcn.00404560
mov ecx, dword [0x45a958]
xor edx, edx
add esp, 4
test eax, eax
mov eax, dword [ebp - 0x408]
cmove ecx, edx
mov dword [0x45a958], ecx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret

Function at 0x4067d0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push edi
push 0
push 0x80
push 2
push 0
push 3
push 0x40000000
push 0x45ad58
mov edi, ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x406917
push 0
lea eax, [ebp - 0xc]
mov word [ebp - 8], 0xfeff
push eax
push 2
lea eax, [ebp - 8]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
xor ecx, ecx
xor eax, eax
mov dword [ebp - 0x14], ecx
cmp ax, word [edi + 2]
jge 0x406910
push esi
movzx eax, word [edi]
xor edx, edx
xor esi, esi
cmp dx, ax
jge 0x4068ea
movsx edx, cx
mov dword [ebp - 0x18], edx
lea ecx, [ecx]
movsx ecx, ax
imul ecx, edx
movsx eax, si
push 0
add ecx, eax
lea eax, [ebp - 0xc]
push eax
mov eax, dword [edi + 0x18]
shl ecx, 2
push 2
add eax, ecx
mov dword [ebp - 0x10], ecx
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [edi + 0x18]
mov edx, 0x300
mov ecx, dword [ebp - 0x10]
movzx eax, word [ecx + eax]
cmp ax, dx
jb 0x4068ab
mov edx, 0x36f
cmp ax, dx
ja 0x4068ab
push 0
lea eax, [ebp - 0xc]
push eax
push 2
push 0x44f8bc
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [ebp - 0x10]
mov eax, dword [edi + 0x18]
movzx eax, word [ecx + eax]
mov ecx, 0xdc00
cmp ax, cx
jb 0x4068da
mov ecx, 0xdfff
cmp ax, cx
ja 0x4068da
push 0
lea eax, [ebp - 0xc]
push eax
push 2
push 0x44f8bc
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
movzx eax, word [edi]
inc esi
mov edx, dword [ebp - 0x18]
cmp si, ax
jl 0x406850
push 0
lea eax, [ebp - 0xc]
push eax
push 4
push 0x44f8c0
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [ebp - 0x14]
inc ecx
mov dword [ebp - 0x14], ecx
cmp cx, word [edi + 2]
jl 0x406837
pop esi
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.004265fb
mov esp, ebp
pop ebp
ret 4
Function at 0x406930
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push 0
push 0x80
push 4
push 0
push 3
push 4
mov esi, ecx
push 0x45ad58
mov dword [ebp - 0x10], esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0xc], eax
cmp eax, 0xffffffff
je 0x4069de
movsx ecx, word [esi + 2]
push ebx
push edi
movsx edi, word [esi]
imul edi, ecx
xor ecx, ecx
shl edi, 2
mov eax, edi
add eax, 0x18
setb cl
lea ebx, [edi + 0x18]
neg ecx
or ecx, eax
push ecx
call fcn.00427138
mov esi, eax
mov eax, dword [ebp - 0x10]
push edi
mov dword [esi], ebx
mov ecx, dword [eax + 4]
mov dword [esi + 4], ecx
movzx ecx, word [eax]
mov word [esi + 8], cx
movzx ecx, word [eax + 2]
mov word [esi + 0xa], cx
mov dword [esi + 0x10], edi
mov ecx, dword [eax + 0x20]
mov dword [esi + 0xc], ecx
push dword [eax + 0x18]
lea eax, [esi + 0x14]
push eax
call fcn.0042a7d0
add esp, 0x10
lea eax, [ebp - 8]
push 0
push eax
push ebx
push esi
mov esi, dword [ebp - 0xc]
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.004265fb
mov esp, ebp
pop ebp
ret 4

Function at 0x406c40
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create thread
Create udp socket
Get local ipv4 addresses
Get socket information
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1b0
mov eax, dword [0x456d10]
xor eax, esp
mov dword [esp + 0x1ac], eax
lea eax, [esp + 0x18]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x406d38
mov eax, 2
push str.127.0.0.1
mov word [esp + 0xc], ax
call dword [sym.imp.WS2_32.dll_inet_addr]
push 6
mov dword [esp + 0x10], eax
xor eax, eax
push 1
push 2
mov word [esp + 0x16], ax
call dword [sym.imp.WS2_32.dll_socket]
mov dword [0x457a34], eax
cmp eax, 0xffffffff
je 0x406d38
push 0x10
lea ecx, [esp + 0xc]
push ecx
push eax
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
je 0x406d38
lea eax, [esp]
mov dword [esp], 0x10
push eax
push 0x45a700
push dword [0x457a34]
call dword [sym.imp.WS2_32.dll_getsockname]
push 1
push dword [0x457a34]
call dword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
je 0x406d38
lea eax, [esp + 4]
push eax
push 0
push 0
push 0x406b80
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
push 0x10
push 0x45a700
push eax
mov dword [0x457a3c], eax
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x406d38
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, dword [esp + 0x1ac]
xor ecx, esp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
Function at 0x406d60
Capabilities:
Set console window title

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x130
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
push str.Entering_InitConsoleWindow___n
push 1
call fcn.0041a380
push dword [0x45a964]
call fcn.0041f9d0
mov cl, byte [0x45a950]
add esp, 0xc
cmp cl, 1
jne 0x406d9f
mov eax, str.SoftwarePragmaSystemsSSHD
jmp 0x406daf
cmp cl, 3
mov eax, str.SoftwarePragmaSystemsWSMan
mov edx, str.SoftwarePragmaSystemsTelnetD
cmovne eax, edx
push esi
push eax
lea eax, [ebp - 0x130]
push eax
push str.MonitorSessions
call fcn.0041ac50
mov esi, eax
add esp, 0xc
test esi, esi
je 0x406ddf
push 0x44e928
push esi
call fcn.004266cb
push esi
call fcn.0041b930
add esp, 0xc
push str.PRAGMASYS_REMOTE_ADDR
push 0x23
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x12c]
push eax
call fcn.00427325
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x128]
push str.CmdServer____s
push eax
call fcn.00404cd0
add esp, 0x1c
lea eax, [ebp - 0x128]
push eax
call dword [sym.imp.KERNEL32.dll_SetConsoleTitleA]
mov ecx, dword [ebp - 4]
xor eax, eax
xor ecx, ebp
pop esi
call fcn.004265fb
mov esp, ebp
pop ebp
ret
Function at 0x4086a0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [0x45aa84]
push ebx
push esi
mov dword [ebp - 0x14], eax
mov eax, dword [0x45a944]
push edi
mov edi, dword [0x45aa7c]
mov dword [ebp - 0x10], eax
mov eax, dword [0x45af8c]
push 0xfffffffffffffff5
mov dword [ebp - 0xc], eax
mov dword [ebp - 8], 0
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push str.Entering_ReadScreenMixedMode_n
push 1
call fcn.0041a380
mov esi, dword [sym.imp.KERNEL32.dll_WaitForMultipleObjectsEx]
lea eax, [ebp - 0x14]
add esp, 8
push 1
push 0xffffffffffffffff
push 0
push eax
push 3
call esi
cmp eax, 0x102
ja 0x408851
mov ebx, dword [sym.imp.KERNEL32.dll_ResetEvent]
je 0x408829
cmp eax, 1
jbe 0x40889a
cmp eax, 2
jne 0x408865
push str.Got_hBeepEvent_first_wait_n
push eax
call fcn.0041a380
add esp, 8
cmp dword [0x457ea0], 0
je 0x40881f
cmp byte [0x45a54d], 0
mov eax, dword [0x45a96c]
mov esi, eax
mov dword [ebp - 0x18], 0
jne 0x408819
mov ecx, dword [0x45a938]
cmp edi, ecx
je 0x4087a0
cmp edi, eax
je 0x4087a2
cmp edi, dword [0x45aa7c]
je 0x4087a2
test edi, edi
je 0x4087a2
push 1
mov edx, 0x45005c
mov ecx, edi
call fcn.00404560
mov esi, dword [sym.imp.KERNEL32.dll_WaitForMultipleObjectsEx]
add esp, 4
push dword [0x45af8c]
call ebx
jmp 0x408838
mov esi, ecx
cmp dword [0x45aa80], 0
je 0x4087c3
cmp esi, eax
jne 0x4087c3
push 1
push 0x45005c
push 0x45a828
call fcn.0041c5b0
add esp, 0xc
push 0
push dword [0x45af78]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x408812
push 0
lea eax, [ebp - 0x18]
push eax
push 1
push 0x45005c
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [0x45a958]
test ecx, ecx
je 0x408819
push 1
mov edx, 0x45005c
call fcn.00404560
mov esi, dword [sym.imp.KERNEL32.dll_WaitForMultipleObjectsEx]
add esp, 4
push dword [0x45af8c]
call ebx
jmp 0x408838
mov dword [ebp - 0x18], 1
mov esi, dword [sym.imp.KERNEL32.dll_WaitForMultipleObjectsEx]
push dword [0x45af8c]
call ebx
jmp 0x408838
push str.ReadScreenMixedMode_exit_WAIT_TIMEOUT_n
push 4
call fcn.0041a380
add esp, 8
push 1
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x14]
push eax
push 3
call esi
cmp eax, 0x102
jbe 0x408714
cmp eax, 0xffffffff
jne 0x408865
push str.ReadScreenMixedMode_exit_WAIT_FAILED_n
push 1
call fcn.0041a380
add esp, 8
mov eax, dword [0x45a958]
pop edi
pop esi
pop ebx
test eax, eax
je 0x408878
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
push str.Exit_ReadScreenMixedMode_n
push 1
call fcn.0041a380
mov ecx, dword [ebp - 4]
add esp, 8
xor ecx, ebp
mov eax, 1
call fcn.004265fb
mov esp, ebp
pop ebp
ret
test eax, eax
jne 0x4088a7
push str.ReadScreenMixedMode_exit_command_shell_exit_n
push 4
jmp 0x40885d
push str.ReadScreenMixedMode_exit_TerminateEvent_n
push 4
jmp 0x40885d
Function at 0x4088b0
Capabilities:
Read file on windows
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
mov dword [ebp - 0x1c], ecx
lea esp, [esp]
push 0
push 0x46b324
push 0x14
lea eax, [ebp - 0x18]
push eax
push dword [0x45a824]
call edi
test eax, eax
je 0x408963
cmp byte [ebp - 0x18], 3
je 0x40895c
mov esi, dword [0x46b324]
lea eax, [ebp - 0x18]
push esi
push eax
push 0x45b040
call fcn.0042a7d0
add esp, 0xc
mov dword [0x45afa0], 0x45b040
test esi, esi
jle 0x40891a
call fcn.00410c90
mov eax, dword [0x47b500]
mov ecx, dword [0x46b218]
sub eax, ecx
test eax, eax
jle 0x4088d0
mov bl, byte [ebp - 0x18]
add ecx, eax
mov dword [0x46b218], ecx
movsx ecx, bl
push ecx
push dword [ebp - 0x1c]
call fcn.00427670
add esp, 8
test eax, eax
je 0x4088d0
mov ecx, dword [ebp - 4]
mov al, bl
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004265fb
mov esp, ebp
pop ebp
ret
push str.ProtocolGetChar_cmdserver_exit_with_CTRL_C_r_n
jmp 0x408968
push str.ProtocolGetChar_cmdserver_exit_with_ReadFile_failure_r_n
push 1
call fcn.0041a380
add esp, 8
mov byte [0x45a54d], 1
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]

Function at 0x408990
Capabilities:
Read file on windows
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
lea eax, [edx - 1]
mov dword [ebp - 0x1c], ecx
push edi
xor edi, edi
mov dword [ebp - 0x20], eax
test eax, eax
je 0x408a55
push 0
push 0x46b324
push 0x14
lea eax, [ebp - 0x18]
push eax
push dword [0x45a824]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x408a85
mov bl, byte [ebp - 0x18]
cmp bl, 3
je 0x408a7e
mov esi, dword [0x46b324]
lea eax, [ebp - 0x18]
push esi
push eax
push 0x45b040
call fcn.0042a7d0
add esp, 0xc
mov dword [0x45afa0], 0x45b040
test esi, esi
jle 0x408a11
call fcn.00410c90
mov bl, byte [ebp - 0x18]
mov eax, dword [0x47b500]
mov ecx, dword [0x46b218]
sub eax, ecx
test eax, eax
jle 0x4089b6
add ecx, eax
mov dword [0x46b218], ecx
cmp bl, 0xa
je 0x408a6f
cmp bl, 0xd
je 0x408a6f
movsx eax, bl
push eax
push 0x44f664
call fcn.004046f0
mov eax, dword [ebp - 0x1c]
add esp, 8
mov byte [eax + edi], bl
inc edi
cmp edi, dword [ebp - 0x20]
jb 0x4089b6
mov ebx, dword [ebp - 0x1c]
mov eax, edi
mov ecx, dword [ebp - 4]
xor ecx, ebp
mov byte [ebx + edi], 0
pop edi
pop esi
pop ebx
call fcn.004265fb
mov esp, ebp
pop ebp
ret
push 0x44f000
call fcn.004046f0
add esp, 4
jmp 0x408a55
push str.ProtocolGetChar_cmdserver_exit_with_CTRL_C_r_n
jmp 0x408a8a
push str.ProtocolGetChar_cmdserver_exit_with_ReadFile_failure_r_n
push 1
call fcn.0041a380
add esp, 8
mov byte [0x45a54d], 1
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
Function at 0x4095e0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push 0
push 0x46b324
push 4
lea eax, [ebp - 8]
mov ebx, ecx
push eax
push dword [0x45a824]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x409672
mov eax, dword [ebp - 8]
push esi
inc eax
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ecx, dword [ebp - 8]
mov esi, eax
inc ecx
push ecx
push 0
push esi
call fcn.0042bf20
add esp, 0xc
push 0
push 0x46b324
push dword [ebp - 8]
push esi
push dword [0x45a824]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x40965b
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 8]
mov dword [ebx], eax
mov eax, esi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor eax, eax
xor ecx, ebp
pop ebx
call fcn.004265fb
mov esp, ebp
pop ebp
ret
Function at 0x409690
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x40c
mov eax, dword [0x456d10]
xor eax, esp
mov dword [esp + 0x408], eax
push ebx
push esi
push edi
push 0
push 1
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
push 1
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
push dword [0x45a960]
mov edi, dword [sym.imp.KERNEL32.dll_SetEvent]
call edi
push str.In_ReadFile_r_n
push 6
call fcn.0041a380
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
lea eax, [esp + 0x18]
add esp, 8
push 0
push 0x46b324
push 0x400
push eax
push dword [0x45a824]
call ebx
mov esi, dword [0x46b324]
test esi, esi
jle 0x4097c2
test eax, eax
je 0x4097c6
push esi
lea eax, [esp + 0x14]
push eax
push 0x45b040
call fcn.0042a7d0
mov eax, dword [0x45af98]
add esp, 0xc
sub eax, dword [0x47b74c]
mov dword [0x45afa0], 0x45b040
test eax, eax
jle 0x409753
call fcn.00414fb0
mov esi, dword [0x46b324]
test esi, esi
jle 0x40975c
call fcn.00410c90
mov eax, dword [0x47b500]
sub eax, dword [0x46b218]
test eax, eax
jle 0x409770
call fcn.00414ea0
mov eax, dword [0x45af98]
sub eax, dword [0x47b74c]
test eax, eax
jle 0x409784
call fcn.00414fb0
push dword [0x45a960]
call edi
push str.In_ReadFile_r_n
push 6
call fcn.0041a380
add esp, 8
lea eax, [esp + 0x10]
push 0
push 0x46b324
push 0x400
push eax
push dword [0x45a824]
call ebx
mov esi, dword [0x46b324]
test esi, esi
jg 0x409714
test eax, eax
jne 0x4097f2
cmp byte [0x45a950], 1
je 0x4097e4
push str.CmdSErver_exit_with_ReadFile_failure_r_n
push 1
mov byte [0x45a54d], 1
call fcn.0041a380
jmp 0x409805
push str.CmdSErver_got_end_of_input_from_sshd_r_n
push 1
call fcn.0041a380
jmp 0x409805
push str.CmdSErver_exit_with_empty_buffer_r_n
push 1
call fcn.0041a380
mov byte [0x45a54d], 1
add esp, 8
push dword [0x45a974]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
cmp byte [0x45a54d], 0
je 0x409832
push 0
push 0
push 0x464
push dword [0x45a534]
call dword [sym.imp.USER32.dll_PostThreadMessageA]
mov ecx, dword [esp + 0x414]
xor eax, eax
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004265fb
mov esp, ebp
pop ebp
ret
Function at 0x409850
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40c
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, dword [0x45a958]
push 1
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
push dword [0x45a960]
mov ebx, dword [sym.imp.KERNEL32.dll_SetEvent]
call ebx
push str.In_ReadFile_r_n
push 6
call fcn.0041a380
add esp, 8
lea eax, [ebp - 0x408]
push 0
push 0x400
push eax
push edi
call dword [sym.imp.WS2_32.dll_recv]
mov esi, eax
mov dword [0x46b324], esi
test esi, esi
jle 0x409966
lea ecx, [ecx]
push esi
lea eax, [ebp - 0x408]
push eax
push 0x45b040
call fcn.0042a7d0
mov eax, dword [0x45af98]
add esp, 0xc
sub eax, dword [0x47b74c]
mov dword [0x45afa0], 0x45b040
test eax, eax
jle 0x4098f9
call fcn.00414fb0
mov esi, dword [0x46b324]
test esi, esi
jle 0x409902
call fcn.00410c90
mov eax, dword [0x47b500]
sub eax, dword [0x46b218]
test eax, eax
jle 0x409916
call fcn.00414ea0
mov eax, dword [0x45af98]
sub eax, dword [0x47b74c]
test eax, eax
jle 0x40992a
call fcn.00414fb0
push dword [0x45a960]
call ebx
push str.In_ReadFile_r_n
push 6
call fcn.0041a380
add esp, 8
lea eax, [ebp - 0x408]
push 0
push 0x400
push eax
push edi
call dword [sym.imp.WS2_32.dll_recv]
mov esi, eax
mov dword [0x46b324], esi
test esi, esi
jg 0x4098c0
push str.CmdSErver_exit_with_empty_buffer_r_n
push 1
call fcn.0041a380
add esp, 8
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004265fb
mov esp, ebp
pop ebp
ret

Function at 0x409ae0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x44492a
mov eax, dword fs:[0]
push eax
sub esp, 0x18
mov eax, dword [0x456d10]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov edi, dword [ebp + 8]
push 0
mov dword [ebp - 0x18], esi
call fcn.00422d33
mov dword [ebp - 4], 0
mov dword [esi + 4], 0
mov byte [esi + 8], 0
mov dword [esi + 0xc], 0
mov byte [esi + 0x10], 0
xor eax, eax
mov dword [esi + 0x14], 0
mov word [esi + 0x18], ax
mov dword [esi + 0x1c], eax
mov word [esi + 0x20], ax
mov dword [esi + 0x24], eax
mov byte [esi + 0x28], al
mov dword [esi + 0x2c], eax
mov byte [esi + 0x30], al
mov byte [ebp - 4], 6
test edi, edi
jne 0x409b86
lea eax, [ebp - 0x14]
mov dword [ebp - 0x14], str.bad_locale_name
push eax
lea ecx, [ebp - 0x24]
call fcn.00428d72
push 0x4533fc
lea eax, [ebp - 0x24]
mov dword [ebp - 0x24], vtable.std::runtime_error.0
push eax
call fcn.0042c5fc
push edi
push esi
call fcn.00422b62
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004265fb
mov esp, ebp
pop ebp
ret 4