joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10024fd0
Capabilities:
Access pe header

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
mov dword [ebp - 4], 0
test eax, eax
je 0x1002508b
push esi
push 0
lea ecx, [ebp - 4]
push ecx
call fcn.10007220
mov esi, eax
test esi, esi
je 0x1002508a
push edi
push esi
call dword [sym.imp.ntdll.dll_RtlImageNtHeader]
mov edi, eax
test edi, edi
je 0x10025067
rdtsc
xor dword [0x1004e210], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
xor dword [0x1004e210], eax
push 0x1004622c
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
test eax, eax
je 0x10025044
push str.RtlUniform
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x10025044
push 0x1004e210
call eax
mov ecx, dword [0x1004e210]
push ebx
xor edx, edx
mov eax, ecx
or ebx, 0xffffffff
div ebx
add eax, ecx
mov dword [edi + 0x58], eax
mov edx, dword [ebp - 4]
mov eax, dword [ebp + 8]
push edx
push esi
call fcn.10007140
pop ebx
mov edi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push esi
push 0
call edi
push eax
call dword [sym.imp.KERNEL32.dll_HeapValidate]
test eax, eax
je 0x10025089
push esi
push 0
call edi
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4

Function at 0x100252d0
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x228
push ebx
push esi
push edi
mov edi, eax
xor eax, eax
push 0x220
push eax
mov dword [ebp - 4], eax
mov dword [ebp - 0x228], eax
lea eax, [ebp - 0x224]
push eax
call sub.MSVCRT.dll_memset
mov ebx, dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
add esp, 0xc
push edi
push 8
call ebx
mov esi, eax
cmp esi, 0xffffffff
jne 0x10025368
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x18
jne 0x100253cb
call dword [sym.imp.KERNEL32.dll_SwitchToThread]
push edi
push 8
call ebx
mov esi, eax
cmp esi, 0xffffffff
je 0x100253cb
mov edi, dword [ebp - 4]
mov dword [ebp - 4], 0
test esi, esi
je 0x1002535f
lea ecx, [ebp - 4]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetHandleInformation]
test eax, eax
je 0x1002535f
test byte [ebp - 4], 2
jne 0x1002535f
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea ecx, [ebp - 0x228]
push ecx
push esi
mov dword [ebp - 0x228], 0x224
call dword [sym.imp.KERNEL32.dll_Module32First]
test eax, eax
je 0x10025335
mov edi, dword [sym.imp.SHLWAPI.dll_StrStrIA]
mov ebx, dword [sym.imp.KERNEL32.dll_Module32Next]
push str.kernel
lea edx, [ebp - 0x208]
push edx
call edi
test eax, eax
je 0x100253ae
push str..dll
push eax
call edi
test eax, eax
jne 0x100253c1
lea eax, [ebp - 0x228]
push eax
push esi
call ebx
test eax, eax
jne 0x10025390
jmp 0x10025335
mov edi, 1
jmp 0x10025338
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x100253e0
Capabilities:
Enumerate processes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x134
push ebx
push esi
push edi
mov edi, dword [0x10059ef8]
xor esi, esi
push 0x124
lea eax, [ebp - 0x12c]
push esi
push eax
mov dword [ebp - 0x130], esi
call sub.MSVCRT.dll_memset
add esp, 0xc
push esi
push 2
mov dword [ebp - 4], esi
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov esi, eax
cmp esi, 0xffffffff
jne 0x1002542b
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea ecx, [ebp - 0x130]
push ecx
push esi
mov dword [ebp - 0x130], 0x128
call dword [sym.imp.KERNEL32.dll_Process32First]
mov ebx, dword [sym.imp.KERNEL32.dll_Process32Next]
lea esp, [esp]
cmp dword [ebp - 0x128], edi
je 0x10025499
lea edx, [ebp - 0x130]
push edx
push esi
call ebx
test eax, eax
jne 0x10025450
mov edi, dword [ebp - 4]
mov dword [ebp - 4], 0
test esi, esi
je 0x10025490
lea eax, [ebp - 4]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetHandleInformation]
test eax, eax
je 0x10025490
test byte [ebp - 4], 2
jne 0x10025490
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edi, 1
jmp 0x10025469
Function at 0x100255c0
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x134
push ebx
push esi
push edi
mov ecx, 9
mov esi, str.1234567890QWERTYUIOPASDFGHJKLZXCVBNM
lea edi, [ebp - 0x30]
rep movsd dword es:[edi], dword [esi]
push 0x104
lea eax, [ebp - 0x134]
push eax
movsb byte es:[edi], byte [esi]
mov dword [ebp - 4], 0xffaaff
call dword [sym.imp.KERNEL32.dll_GetSystemWindowsDirectoryA]
lea eax, [ebp - 0x134]
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x10025600
push 0
push 0
push 0
push 0
mov byte [ebp - 0x131], cl
lea ecx, [ebp - 4]
push ecx
push 0
sub eax, edx
push 0
lea edx, [ebp - 0x134]
push edx
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
mov edi, dword [ebp - 4]
xor edi, esi
mov eax, 0xaaaaaaab
mul edi
shr edx, 1
lea eax, [edx + edx*2]
mov ecx, edi
sub ecx, eax
mov dword [ebp - 4], edi
je 0x1002564d
not edi
mov dword [ebp - 4], edi
lea eax, [ebp - 0x30]
xor ebx, ebx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x10025655
sub eax, edx
mov dword [ebp - 8], eax
mov esi, 0x1005a2e0
jmp 0x1002566b
mov edi, dword [ebp - 4]
xor edx, edx
mov eax, ebx
div dword [ebp - 8]
mov ecx, 0x100457e0
movsx eax, byte [ebp + edx - 0x30]
imul eax, ebx
xor eax, edi
test bl, 1
jne 0x1002568b
mov ecx, 0x1004ab34
push eax
push ecx
push 0x104
push esi
call dword [sym.imp.MSVCRT.dll__snprintf]
add esp, 0x10
lea edi, [esi - 1]
nop
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x100256a0
mov dx, word [0x1004ab38]
add esi, 0x104
inc ebx
mov word [edi], dx
cmp esi, 0x1005c054
jl 0x10025668
xor ebx, ebx
mov edi, 0x1005c058
xor edx, edx
mov eax, ebx
div dword [ebp - 8]
mov ecx, 0x100457e0
movsx eax, byte [ebp + edx - 0x30]
imul eax, ebx
xor eax, dword [ebp - 4]
xor eax, 0xffeeffaa
test bl, 1
jne 0x100256ee
mov ecx, 0x1004ab34
push eax
push ecx
push 0x104
push edi
call dword [sym.imp.MSVCRT.dll__snprintf]
add edi, 0x104
add esp, 0x10
inc ebx
cmp edi, 0x1005d6b0
jl 0x100256c8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x100282e0
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
test ecx, ecx
jne 0x100282f0
xor eax, eax
pop ebp
ret 4
push esi
not eax
cmp edx, 8
jb 0x100283bf
mov esi, edx
shr esi, 3
push edi
movzx edi, byte [ecx]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x10047d50]
movzx edi, byte [ecx + 1]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x10047d50]
movzx edi, byte [ecx + 2]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x10047d50]
movzx edi, byte [ecx + 3]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x10047d50]
movzx edi, byte [ecx + 4]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x10047d50]
movzx edi, byte [ecx + 5]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x10047d50]
movzx edi, byte [ecx + 6]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x10047d50]
movzx edi, byte [ecx + 7]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x10047d50]
add ecx, 8
sub edx, 8
dec esi
jne 0x10028302
pop edi
test edx, edx
je 0x100283dc
movzx esi, byte [ecx]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x10047d50]
inc ecx
dec edx
jne 0x100283c3
not eax
pop esi
pop ebp
ret 4
Function at 0x10028610
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push edi
mov edi, ecx
cmp dword [edi + 0x18], 0
je 0x100286e4
mov eax, dword [edi + 0x1c]
mov ecx, dword [edi + 0x20]
push ebx
push esi
mov esi, dword [ebp + 0xc]
add eax, esi
cmp eax, ecx
jb 0x100286c2
lea ebx, [ecx + ecx]
cmp ebx, eax
jbe 0x10028644
mov dword [ebp - 4], ebx
jmp 0x10028649
mov dword [ebp - 4], eax
mov ebx, eax
push 0
push ebx
push 0
push 4
push 0
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov esi, eax
mov dword [ebp - 8], esi
test esi, esi
je 0x1002867f
push ebx
push 0
push 0
push 0xf001f
push esi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov ebx, eax
test ebx, ebx
jne 0x1002868d
call fcn.10025580
pop esi
pop ebx
mov eax, 0x300
pop edi
mov esp, ebp
pop ebp
ret 8
mov ecx, dword [edi + 0x20]
mov edx, dword [edi + 0x18]
push ecx
push edx
push ebx
call sub.MSVCRT.dll_memcpy
mov eax, dword [edi + 0x18]
add esp, 0xc
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov esi, dword [edi + 4]
call fcn.10025580
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 8]
mov esi, dword [ebp + 0xc]
mov dword [edi + 0x20], ecx
mov dword [edi + 0x18], ebx
mov dword [edi + 4], edx
mov ecx, dword [edi + 0x1c]
mov eax, dword [ebp + 8]
add ecx, dword [edi + 0x18]
push esi
push eax
push ecx
call sub.MSVCRT.dll_memcpy
add esp, 0xc
add dword [edi + 0x1c], esi
mov eax, esi
pop esi
pop ebx
pop edi
mov esp, ebp
pop ebp
ret 8
mov eax, dword [edi]
test eax, eax
je 0x10028710
mov ecx, dword [ebp + 0xc]
push 0
lea edx, [ebp - 4]
push edx
mov edx, dword [ebp + 8]
push ecx
push edx
push eax
mov dword [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 4]
pop edi
mov esp, ebp
pop ebp
ret 8
mov dword [edi + 0xc], 0x1000000
xor eax, eax
pop edi
mov esp, ebp
pop ebp
ret 8

Function at 0x10028a30
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [esi + 0x58]
push ebx
mov ebx, dword [ebp + 8]
push edi
test ecx, ecx
je 0x10028a7c
mov eax, dword [esi + 0x60]
mov edi, dword [esi + 0x5c]
cmp eax, edi
jae 0x10028abb
sub edi, eax
cmp edi, edx
jbe 0x10028a51
mov edi, edx
push edi
add eax, ecx
push eax
push ebx
call sub.MSVCRT.dll_memcpy
mov eax, dword [esi + 0x4c]
add dword [esi + 0x60], edi
add dword [esi + 0x48], edi
add esp, 0xc
push eax
mov edx, edi
mov ecx, ebx
call fcn.100282e0
mov dword [esi + 0x4c], eax
mov eax, edi
pop edi
pop ebx
pop ebp
ret 4
mov eax, dword [esi + 0x50]
test eax, eax
je 0x10028ab4
push 0
lea ecx, [ebp + 8]
push ecx
push edx
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10028abb
mov edx, dword [esi + 0x4c]
mov edi, dword [ebp + 8]
add dword [esi + 0x48], edi
push edx
mov edx, edi
mov ecx, ebx
call fcn.100282e0
mov dword [esi + 0x4c], eax
mov eax, edi
pop edi
pop ebx
pop ebp
ret 4
mov dword [esi + 0xc], 0x1000000
pop edi
xor eax, eax
pop ebx
pop ebp
ret 4
Function at 0x10029460
Capabilities:
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov edx, dword [ebp + 0x10]
sub esp, 0x35c
push ebx
push esi
xor esi, esi
push edi
mov edi, dword [ebp + 0xc]
cmp edx, esi
je 0x10029481
mov dword [esp + 0x10], edx
jmp 0x1002948b
lea eax, [edi + 0x800]
mov dword [esp + 0x10], eax
cmp edi, esi
je 0x100294a3
mov eax, edi
lea ebx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x10029494
sub eax, ebx
mov dword [esp + 0x18], eax
jmp 0x100294a7
mov dword [esp + 0x18], esi
cmp edx, esi
je 0x100294bf
mov eax, edx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x100294b0
sub eax, edx
mov dword [esp + 0x14], eax
jmp 0x100294c3
mov dword [esp + 0x14], esi
cmp edi, esi
je 0x10029672
mov eax, edi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x100294d0
sub eax, edx
add eax, 0x104
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ebx, eax
cmp ebx, esi
je 0x10029672
push edi
push str._s
push 0x104
push ebx
call dword [sym.imp.MSVCRT.dll__snprintf]
add esp, 0x10
lea ecx, [esp + 0x20]
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov esi, eax
push ebx
mov dword [esp + 0x20], esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
test esi, esi
je 0x1002966b
mov ebx, dword [ebp + 8]
cmp byte [esp + 0x4c], 0x2e
je 0x10029657
mov ecx, dword [ebp + 0x10]
mov eax, str._s_s
test ecx, ecx
jne 0x10029546
mov eax, 0x10045f7c
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
lea edx, [esp + 0x4c]
push edx
push ecx
push eax
mov eax, dword [esp + 0x1c]
push eax
call esi
lea ecx, [esp + 0x5c]
push ecx
push edi
push str._s_s
push edi
call esi
add esp, 0x20
test byte [esp + 0x20], 0x10
je 0x100295d6
test ebx, ebx
jne 0x10029591
mov eax, dword [esp + 0x10]
push eax
push edi
push ebx
mov dword [0x1005c054], 0x10000
call fcn.10029460
jmp 0x1002963f
cmp dword [ebx], 2
je 0x100295b1
mov eax, dword [esp + 0x10]
push eax
push edi
push ebx
mov dword [0x1005c054], 0x80000
call fcn.10029460
jmp 0x1002963f
mov edx, dword [esp + 0x10]
mov eax, dword [ebx + 4]
push 4
push 0
push edx
push eax
call fcn.10028cb0
mov dword [0x1005c054], eax
mov eax, dword [esp + 0x10]
push eax
push edi
push ebx
call fcn.10029460
jmp 0x1002963f
test ebx, ebx
jne 0x100295e6
mov dword [0x1005c054], 0x10000
jmp 0x1002963f
cmp dword [ebx], 2
je 0x100295f7
mov dword [0x1005c054], 0x80000
jmp 0x1002963f
mov esi, dword [ebx + 4]
push 0x208
lea ecx, [esp + 0x164]
push 0
push ecx
call sub.MSVCRT.dll_memset
mov edx, dword [esp + 0x1c]
add esp, 0xc
push 0x104
push edx
lea eax, [esp + 0x168]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
push 2
push edi
lea ecx, [esp + 0x168]
push ecx
push esi
call fcn.10028cb0
mov dword [0x1005c054], eax
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov esi, dword [esp + 0x1c]
mov byte [edx + edi], 0
mov byte [eax + ecx], 0
lea edx, [esp + 0x20]
push edx
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x1002952a
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x10029aa0
Capabilities:
Get hostname

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push 0x350
mov dword [ebp - 4], 0xff
call dword [sym.imp.MSVCRT.dll_malloc]
mov esi, eax
xor ebx, ebx
add esp, 4
cmp esi, ebx
jne 0x10029acd
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 0xc
push edi
xor al, al
mov edi, esi
mov ecx, 0x350
rep stosb byte es:[edi], al
mov eax, 1
cmp dword [0x1005d6b0], ebx
jne 0x10029aeb
mov dword [0x1005d6b0], eax
mov edi, dword [ebp + 8]
mov dword [esi + 0x2c4], eax
mov eax, dword [ebp + 0xc]
mov dword [esi + 0x10], eax
mov eax, dword [ebp + 0x10]
add eax, eax
or ecx, 0xffffffff
add eax, eax
add eax, eax
push ebx
mov byte [esi + 0x174], bl
mov dword [esi + 0x2d4], ebx
mov dword [esi + 0x2d8], ebx
mov dword [esi + 0x178], 0x170c
mov dword [esi + 0x28c], ebx
mov byte [esi + 0x294], bl
mov dword [esi + 0x290], ecx
mov byte [esi + 0x14b], bl
mov dword [esi + 0x15c], ecx
mov dword [esi + 0x29c], ecx
mov byte [esi + 0x2a4], bl
mov dword [esi + 0x298], ebx
mov dword [esi + 0x2a0], ebx
mov dword [esi + 0x184], ebx
mov dword [esi + 0x17c], ecx
mov word [esi + 0x2d0], bx
mov byte [esi + 0x2d2], bl
mov dword [esi + 0x2c0], ebx
mov dword [esi + 8], edi
mov dword [esi + 0x14], eax
mov dword [esi + 0x18], eax
mov dword [esi + 0x2bc], 0x10029950
mov byte [esi + 0x32c], cl
mov dword [esi + 0x330], ebx
call dword [sym.imp.WS2_32.dll_htonl]
lea ecx, [ebp - 4]
push ecx
lea edx, [esi + 0x4c]
push edx
mov dword [esi + 0x334], eax
mov dword [esi + 0x2cc], 5
mov dword [esi + 0x2c8], 0x32
mov byte [esi + 0x33c], bl
mov dword [esi + 0x344], 3
mov dword [esi + 0x348], 8
mov byte [esi + 0x34c], bl
call dword [sym.imp.KERNEL32.dll_GetComputerNameA]
imul edi, dword [ebp + 0x10]
mov eax, esi
mov dword [esi + 0xc], edi
call fcn.10029a10
pop edi
mov dword [esi + 0x2e4], ebx
mov dword [esi + 0x2e0], ebx
mov dword [esi + 0x2dc], ebx
mov dword [esi + 0x2e8], ebx
mov byte [esi + 0x2ec], bl
mov dword [esi + 0x324], ebx
mov dword [esi + 0x328], ebx
mov dword [esi + 0x2d4], ebx
mov dword [esi + 0x2f0], 0x1004e0ac
mov dword [esi + 0x2f8], 0x10029880
mov dword [esi + 0x2fc], 0x100299f0
mov dword [esi + 0x300], 0x10029890
mov dword [esi + 0x304], 0x10029880
mov dword [esi + 0x308], 0x10029930
mov dword [esi + 0x30c], 0x10033570
mov dword [esi + 0x320], 0x10029a00
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x1002d330
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x218
push ebx
mov ebx, dword [ebp + 8]
mov eax, dword [ebx]
mov eax, dword [eax + 0x340]
push esi
push edi
test eax, eax
jne 0x1002d350
mov eax, str.unknown
push str.LibVNCServer_0.9.7
push eax
lea ecx, [ebp - 0x214]
push str._s___s_
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x214]
add esp, 0x10
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002d374
mov ecx, dword [ebx + 0x75c4]
sub eax, edx
lea edx, [ecx + eax + 0xd]
cmp edx, 0x7530
jbe 0x1002d3be
push ecx
lea eax, [ebx + 0x94]
push eax
mov eax, ebx
call fcn.10030cd0
test eax, eax
jns 0x1002d3b4
mov esi, ebx
call fcn.10030a00
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov dword [ebx + 0x75c4], 0
mov al, byte [0x1004e05d]
movsx ecx, al
neg ecx
sbb ecx, ecx
and ecx, 0x302fefc
xor edx, edx
add ecx, 0xfffe0003
test al, al
lea eax, [ebp - 0x214]
mov dword [ebp - 0x10], edx
mov dword [ebp - 8], ecx
lea edx, [eax + 1]
je 0x1002d411
jmp 0x1002d3f0
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002d3f0
sub eax, edx
lea edx, [eax + 1]
shr edx, 8
inc eax
and edx, 0xff
shl eax, 8
xor edx, eax
mov word [ebp - 0xc], dx
jmp 0x1002d41f
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002d411
sub eax, edx
inc eax
mov word [ebp - 0xc], ax
mov ecx, dword [ebx + 0x75c4]
xor eax, eax
lea edi, [ecx + ebx + 0x94]
mov word [ebp - 0xa], ax
lea esi, [ebp - 0x10]
mov ecx, 0xc
rep movsb byte es:[edi], byte [esi]
add dword [ebx + 0x75c4], 0xc
mov edx, dword [ebx + 0x75c4]
lea eax, [ebp - 0x214]
lea esi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002d452
sub eax, esi
lea ecx, [eax + 1]
lea edi, [edx + ebx + 0x94]
lea esi, [ebp - 0x214]
lea eax, [ebp - 0x214]
rep movsb byte es:[edi], byte [esi]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002d476
sub eax, edx
inc eax
add dword [ebx + 0x75c4], eax
mov eax, dword [ebx + 0x75c4]
push eax
lea edx, [ebx + 0x94]
push edx
mov eax, ebx
call fcn.10030cd0
test eax, eax
js 0x1002d3a2
pop edi
pop esi
mov dword [ebx + 0x75c4], 0
or al, 0xff
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x1002d9b0
Capabilities:
Get socket status
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x12c
push ebx
push esi
push edi
mov esi, eax
mov eax, dword [esi]
xor edi, edi
mov dword [ebp - 8], edi
cmp byte [eax + 0x34c], 0xff
mov dword [ebp - 0x14], 0x2400
jne 0x1002dbc8
mov eax, dword [eax + 0x318]
cmp eax, edi
je 0x1002d9ef
push esi
call eax
cmp eax, 0xffffffff
jne 0x1002dbc8
cmp dword [esi + 0x7624], 0xffffffff
je 0x1002dbc8
mov ecx, 1
cmp dword [esi + 0x7638], ecx
jne 0x1002dbc8
mov eax, dword [esi + 0x14]
mov dword [ebp - 0x128], ecx
lea ecx, [ebp - 0x1c]
push ecx
push edi
lea edx, [ebp - 0x128]
push edx
mov dword [ebp - 0x124], eax
push edi
inc eax
push eax
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x18], edi
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jle 0x1002dbc8
mov edi, dword [sym.imp.MSVCRT.dll_malloc]
push 0x2000
call edi
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x1002da72
push 0x2400
call edi
mov edi, eax
add esp, 4
mov dword [ebp - 0x10], edi
test edi, edi
jne 0x1002da7b
push ebx
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0xc], 0
mov ecx, dword [esi + 0x7624]
push 0
lea eax, [ebp - 8]
push eax
push 0x2000
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1002db34
mov eax, dword [ebp - 8]
cmp eax, 0xffffffff
je 0x1002db3b
test eax, eax
je 0x1002db5a
cmp dword [esi + 0x7628], 0
jne 0x1002dad7
push ebx
push 0
mov edi, eax
push esi
xor eax, eax
mov cl, 5
call fcn.1002d4c0
movsx edx, al
mov dword [ebp - 4], edx
jmp 0x1002db20
push eax
push ebx
lea eax, [ebp - 0x14]
mov ecx, edi
call fcn.10041080
mov ecx, dword [ebp - 8]
test eax, eax
jne 0x1002db0b
mov eax, dword [ebp - 0x14]
cmp eax, ecx
jae 0x1002db0b
push edi
push 0
mov edi, eax
push esi
mov eax, 1
mov cl, 5
call fcn.1002d4c0
movsx eax, al
mov dword [ebp - 4], eax
jmp 0x1002db20
push ebx
push 0
mov edi, ecx
push esi
xor eax, eax
mov cl, 5
call fcn.1002d4c0
movsx ecx, al
mov dword [ebp - 4], ecx
mov eax, dword [ebp - 0xc]
inc eax
mov dword [ebp - 0xc], eax
cmp eax, 0x20
jge 0x1002dba9
mov edi, dword [ebp - 0x10]
jmp 0x1002da82
mov dword [ebp - 8], 0xffffffff
push 0
push 0
push esi
xor edi, edi
xor eax, eax
mov cl, 7
call fcn.1002d4c0
mov edx, dword [esi + 0x7624]
movsx ecx, al
mov dword [ebp - 4], ecx
push edx
jmp 0x1002db77
push 0
push 0
push esi
xor edi, edi
xor eax, eax
mov cl, 6
call fcn.1002d4c0
movsx edx, al
mov eax, dword [esi + 0x7624]
mov dword [ebp - 4], edx
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
push ebx
mov dword [esi + 0x7624], 0xffffffff
mov dword [esi + 0x7638], eax
mov dword [esi + 0x7634], eax
call dword [sym.imp.MSVCRT.dll_free]
mov al, byte [ebp - 4]
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x10]
mov esi, dword [sym.imp.MSVCRT.dll_free]
push eax
call esi
add esp, 4
push ebx
call esi
mov al, byte [ebp - 4]
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
or al, 0xff
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x1002fee0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push edi
mov edi, dword [esi + 0x2a0]
xor ebx, ebx
cmp edi, ebx
je 0x1002ffcf
cmp byte [edi + 0x29], bl
jne 0x1002ffcf
mov ecx, dword [esi + 0x29c]
push ebx
push 0x14
lea eax, [ebp - 0x14]
push eax
push ecx
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, ebx
jle 0x1002ff25
movzx ecx, byte [ebp - 0x14]
sub ecx, 4
je 0x1002ff87
dec ecx
je 0x1002ff31
pop edi
mov byte [esi + 0x2a4], bl
pop ebx
mov esp, ebp
pop ebp
ret
cmp eax, 6
jne 0x1002ff25
cmp byte [0x1004e05d], bl
je 0x1002ff67
movzx eax, word [ebp - 0x10]
movzx edx, word [ebp - 0x12]
mov ecx, eax
and ecx, 0xff
shr eax, 8
shl ecx, 8
or ecx, eax
mov eax, edx
and eax, 0xff
shl eax, 8
shr edx, 8
or eax, edx
jmp 0x1002ff6f
movzx ecx, word [ebp - 0x10]
movzx eax, word [ebp - 0x12]
mov edx, dword [edi]
push edi
push ecx
mov ecx, dword [edx + 0x300]
push eax
movzx eax, byte [ebp - 0x13]
push eax
call ecx
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
cmp eax, 8
jne 0x1002ff25
cmp byte [0x1004e05d], bl
je 0x1002ffbc
mov ecx, dword [ebp - 0x10]
mov eax, ecx
mov edx, ecx
shr edx, 0x10
and eax, 0xff0000
or eax, edx
mov edx, ecx
and edx, 0xff00
shl ecx, 0x10
or edx, ecx
shr eax, 8
shl edx, 8
or eax, edx
jmp 0x1002ffbf
mov eax, dword [ebp - 0x10]
mov ecx, dword [edi]
mov edx, dword [ebp - 0x13]
push edi
push eax
mov eax, dword [ecx + 0x2f8]
push edx
call eax
pop edi
pop ebx
mov esp, ebp
pop ebp
ret