joyce8/EMBER2024-capa huggingface dataset:
Function at 0x100386c0
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [ebp + 0xc]
sub eax, 0x10000
push eax
call fcn.10038890
add esp, 4
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
cmp ecx, dword [ebp + 8]
jbe 0x1003879d
mov edx, dword [ebp - 4]
cmp edx, dword [0x10095064]
jb 0x1003870a
mov eax, dword [ebp - 4]
cmp eax, dword [0x10095068]
ja 0x1003870a
mov ecx, dword [ebp - 4]
sub ecx, 0x8000000
mov dword [ebp - 4], ecx
jmp 0x100386da
push 0x1c
push 0
lea edx, [ebp - 0x24]
push edx
call fcn.100539e0
add esp, 0xc
push 0x1c
lea eax, [ebp - 0x24]
push eax
mov ecx, dword [ebp - 4]
push ecx
call sub.KERNEL32.dll_VirtualQuery
test eax, eax
jne 0x1003872f
jmp 0x1003879d
cmp dword [ebp - 0x14], 0x10000
jne 0x10038783
cmp dword [ebp - 0x18], 0x10000
jb 0x10038783
push 0x40
push 0x3000
push 0x10000
mov edx, dword [ebp - 4]
push edx
call sub.KERNEL32.dll_VirtualAlloc
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x10038766
mov eax, dword [ebp - 8]
jmp 0x1003879f
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x677
jne 0x10038776
xor eax, eax
jmp 0x1003879f
mov eax, dword [ebp - 4]
sub eax, 0x10000
mov dword [ebp - 4], eax
jmp 0x10038798
mov ecx, dword [ebp - 0x20]
sub ecx, 0x10000
push ecx
call fcn.10038890
add esp, 4
mov dword [ebp - 4], eax
jmp 0x100386da
xor eax, eax
mov esp, ebp
pop ebp
ret

Function at 0x100387b0
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [ebp + 8]
push eax
call fcn.100388c0
add esp, 4
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
cmp ecx, dword [ebp + 0xc]
jae 0x10038885
mov edx, dword [ebp - 4]
cmp edx, dword [0x10095064]
jb 0x100387f5
mov eax, dword [ebp - 4]
cmp eax, dword [0x10095068]
ja 0x100387f5
mov ecx, dword [ebp - 4]
add ecx, 0x8000000
mov dword [ebp - 4], ecx
jmp 0x100387c5
push 0x1c
push 0
lea edx, [ebp - 0x24]
push edx
call fcn.100539e0
add esp, 0xc
push 0x1c
lea eax, [ebp - 0x24]
push eax
mov ecx, dword [ebp - 4]
push ecx
call sub.KERNEL32.dll_VirtualQuery
test eax, eax
jne 0x1003881a
jmp 0x10038885
cmp dword [ebp - 0x14], 0x10000
jne 0x1003886e
cmp dword [ebp - 0x18], 0x10000
jb 0x1003886e
push 0x40
push 0x3000
push 0x10000
mov edx, dword [ebp - 4]
push edx
call sub.KERNEL32.dll_VirtualAlloc
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x10038851
mov eax, dword [ebp - 8]
jmp 0x10038887
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x677
jne 0x10038861
xor eax, eax
jmp 0x10038887
mov eax, dword [ebp - 4]
add eax, 0x10000
mov dword [ebp - 4], eax
jmp 0x10038880
mov ecx, dword [ebp - 0x24]
add ecx, dword [ebp - 0x18]
push ecx
call fcn.100388c0
add esp, 4
mov dword [ebp - 4], eax
jmp 0x100387c5
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x100388f0
Capabilities:
Hook routines via microsoft detours

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
lea eax, [ebp - 0xc]
push eax
lea ecx, [ebp - 0x10]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.10038ce0
add esp, 0xc
mov dword [ebp - 4], 0
cmp dword [0x10098ad8], 0
jne 0x1003892d
cmp dword [0x10098ad4], 0
je 0x1003892d
mov eax, dword [0x10098ad4]
mov dword [0x10098ad8], eax
cmp dword [0x10098ad8], 0
je 0x100389aa
mov ecx, dword [0x10098ad8]
cmp dword [ecx + 8], 0
je 0x100389aa
mov edx, dword [0x10098ad8]
mov eax, dword [edx + 8]
cmp eax, dword [ebp - 0x10]
jb 0x100389aa
mov ecx, dword [0x10098ad8]
mov edx, dword [ecx + 8]
cmp edx, dword [ebp - 0xc]
ja 0x100389aa
mov eax, dword [0x10098ad8]
mov ecx, dword [eax + 8]
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 4]
cmp edx, dword [ebp - 0x10]
jb 0x10038979
mov eax, dword [ebp - 4]
cmp eax, dword [ebp - 0xc]
jbe 0x10038980
xor eax, eax
jmp 0x10038ac9
mov ecx, dword [0x10098ad8]
mov edx, dword [ebp - 4]
mov eax, dword [edx + 0x40]
mov dword [ecx + 8], eax
push 0x48
push 0xcc
mov ecx, dword [ebp - 4]
push ecx
call fcn.100539e0
add esp, 0xc
mov eax, dword [ebp - 4]
jmp 0x10038ac9
mov edx, dword [0x10098ad4]
mov dword [0x10098ad8], edx
jmp 0x100389c6
mov eax, dword [0x10098ad8]
mov ecx, dword [eax + 4]
mov dword [0x10098ad8], ecx
cmp dword [0x10098ad8], 0
je 0x10038a06
cmp dword [0x10098ad8], 0
je 0x10038a04
mov edx, dword [0x10098ad8]
cmp dword [edx + 8], 0
je 0x10038a04
mov eax, dword [0x10098ad8]
mov ecx, dword [eax + 8]
cmp ecx, dword [ebp - 0x10]
jb 0x10038a04
mov edx, dword [0x10098ad8]
mov eax, dword [edx + 8]
cmp eax, dword [ebp - 0xc]
ja 0x10038a04
jmp 0x1003895e
jmp 0x100389b8
mov ecx, dword [ebp + 8]
and ecx, 0xffff
mov edx, dword [ebp + 8]
sub edx, ecx
mov dword [ebp + 8], edx
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.10038ad0
add esp, 0xc
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
je 0x10038ac7
mov eax, dword [ebp - 0x18]
mov dword [0x10098ad8], eax
mov ecx, dword [0x10098ad8]
mov dword [ecx], 0x52727464
mov edx, dword [0x10098ad8]
mov dword [edx + 8], 0
mov eax, dword [0x10098ad8]
mov ecx, dword [0x10098ad4]
mov dword [eax + 4], ecx
mov edx, dword [0x10098ad8]
mov dword [0x10098ad4], edx
mov dword [ebp - 0x14], 0
mov eax, dword [0x10098ad8]
add eax, 0x48
mov dword [ebp - 4], eax
mov dword [ebp - 8], 0x38c
jmp 0x10038a97
mov ecx, dword [ebp - 8]
sub ecx, 1
mov dword [ebp - 8], ecx
cmp dword [ebp - 8], 1
jle 0x10038ab7
imul edx, dword [ebp - 8], 0x48
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 0x14]
mov dword [eax + edx + 0x40], ecx
imul edx, dword [ebp - 8], 0x48
add edx, dword [ebp - 4]
mov dword [ebp - 0x14], edx
jmp 0x10038a8e
mov eax, dword [0x10098ad8]
mov ecx, dword [ebp - 0x14]
mov dword [eax + 8], ecx
jmp 0x1003895e
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x10039810
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x10098ad4]
mov dword [ebp - 4], eax
jmp 0x10039829
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 4]
mov dword [ebp - 4], edx
cmp dword [ebp - 4], 0
je 0x10039850
lea eax, [ebp - 8]
push eax
push 0x40
push 0x10000
mov ecx, dword [ebp - 4]
push ecx
call sub.KERNEL32.dll_VirtualProtect
test eax, eax
jne 0x1003984e
call sub.KERNEL32.dll_GetLastError
jmp 0x10039852
jmp 0x10039820
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x10039cf0
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov dword [ebp - 8], 0
call sub.KERNEL32.dll_GetCurrentThreadId
cmp dword [0x10098ae4], eax
je 0x10039d14
mov eax, 0x10dd
jmp 0x10039ebc
cmp dword [0x10098ae8], 0
je 0x10039d27
mov eax, dword [0x10098ae8]
jmp 0x10039ebc
cmp dword [ebp + 0xc], 0
jne 0x10039d37
mov eax, 0x57
jmp 0x10039ebc
cmp dword [ebp + 8], 0
jne 0x10039d47
mov eax, 6
jmp 0x10039ebc
mov eax, dword [ebp + 8]
cmp dword [eax], 0
jne 0x10039d70
mov dword [ebp - 8], 6
mov ecx, dword [ebp - 8]
mov dword [0x10098ae8], ecx
mov edx, dword [ebp + 8]
mov dword [0x10098aec], edx
mov eax, dword [ebp - 8]
jmp 0x10039ebc
push 0x18
call fcn.1003b3a6
add esp, 4
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x10039dcb
mov dword [ebp - 8], 8
mov ecx, dword [ebp - 8]
mov dword [0x10098ae8], ecx
cmp dword [ebp - 4], 0
je 0x10039dba
mov edx, dword [ebp - 4]
mov dword [ebp - 0x20], edx
push 0x18
mov eax, dword [ebp - 0x20]
push eax
call fcn.1003b3fc
add esp, 8
mov dword [ebp - 4], 0
mov ecx, dword [ebp + 8]
mov dword [0x10098aec], ecx
mov eax, dword [ebp - 8]
jmp 0x10039ebc
push 0
mov edx, dword [ebp + 8]
mov eax, dword [edx]
push eax
call fcn.10039cd0
mov dword [ebp - 0x10], eax
push 0
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.10039cd0
mov dword [ebp + 0xc], eax
mov edx, dword [ebp - 0x10]
movzx eax, byte [edx + 0x36]
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 0x10]
mov edx, dword [ecx + 0x40]
sub edx, dword [ebp - 0xc]
mov dword [ebp - 0x14], edx
cmp dword [ebp - 0xc], 0
je 0x10039e0b
cmp dword [ebp - 0xc], 0x1e
jbe 0x10039e27
mov dword [ebp - 8], 9
cmp dword [0x10098adc], 0
je 0x10039e22
jmp 0x10039d99
jmp 0x10039d90
mov eax, dword [ebp - 0x10]
mov ecx, dword [eax + 0x44]
cmp ecx, dword [ebp + 0xc]
je 0x10039e4e
mov dword [ebp - 8], 9
cmp dword [0x10098adc], 0
je 0x10039e49
jmp 0x10039d99
jmp 0x10039d90
mov dword [ebp - 0x18], 0
lea edx, [ebp - 0x18]
push edx
push 0x40
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
call sub.KERNEL32.dll_VirtualProtect
test eax, eax
jne 0x10039e79
call sub.KERNEL32.dll_GetLastError
mov dword [ebp - 8], eax
jmp 0x10039d90
mov edx, dword [ebp - 4]
mov dword [edx + 4], 1
mov eax, dword [ebp - 4]
mov ecx, dword [ebp + 8]
mov dword [eax + 8], ecx
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0x10]
mov dword [edx + 0x10], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 0x14]
mov dword [ecx + 0xc], edx
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 0x18]
mov dword [eax + 0x14], ecx
mov edx, dword [ebp - 4]
mov eax, dword [0x10098af4]
mov dword [edx], eax
mov ecx, dword [ebp - 4]
mov dword [0x10098af4], ecx
xor eax, eax
mov esp, ebp
pop ebp
ret 8
Function at 0x10039ed0
Capabilities:
Resume thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
call sub.KERNEL32.dll_GetCurrentThreadId
cmp dword [0x10098ae4], eax
je 0x10039eed
mov eax, 0x10dd
jmp 0x10039fd0
mov eax, dword [0x10098af4]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x10039f6c
lea ecx, [ebp - 0x1c]
push ecx
mov edx, dword [ebp - 4]
mov eax, dword [edx + 0x14]
push eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 0x10]
movzx eax, byte [edx + 0x36]
push eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 0xc]
push edx
call sub.KERNEL32.dll_VirtualProtect
mov eax, dword [ebp - 4]
cmp dword [eax + 4], 0
jne 0x10039f48
mov ecx, dword [ebp - 4]
cmp dword [ecx + 0x10], 0
je 0x10039f48
mov edx, dword [ebp - 4]
mov eax, dword [edx + 0x10]
push eax
call fcn.10038d70
add esp, 4
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x10], 0
mov edx, dword [ebp - 4]
mov eax, dword [edx]
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 4]
mov dword [ebp - 0xc], ecx
push 0x18
mov edx, dword [ebp - 0xc]
push edx
call fcn.1003b3fc
add esp, 8
mov eax, dword [ebp - 0x10]
mov dword [ebp - 4], eax
jmp 0x10039ef5
mov dword [0x10098af4], 0
call fcn.10039650
mov ecx, dword [0x10098af0]
mov dword [ebp - 8], ecx
cmp dword [ebp - 8], 0
je 0x10039fba
mov edx, dword [ebp - 8]
mov eax, dword [edx + 4]
push eax
call sub.KERNEL32.dll_ResumeThread
mov ecx, dword [ebp - 8]
mov edx, dword [ecx]
mov dword [ebp - 0x18], edx
mov eax, dword [ebp - 8]
mov dword [ebp - 0x14], eax
push 8
mov ecx, dword [ebp - 0x14]
push ecx
call fcn.1003b3fc
add esp, 8
mov edx, dword [ebp - 0x18]
mov dword [ebp - 8], edx
jmp 0x10039f84
mov dword [0x10098af0], 0
mov dword [0x10098ae4], 0
xor eax, eax
mov esp, ebp
pop ebp
ret

Function at 0x1003a4b0
Capabilities:
Suspend thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
cmp dword [0x10098ae8], 0
je 0x1003a4c9
mov eax, dword [0x10098ae8]
jmp 0x1003a568
call sub.KERNEL32.dll_GetCurrentThread
cmp dword [ebp + 8], eax
jne 0x1003a4da
xor eax, eax
jmp 0x1003a568
push 8
call fcn.1003b3a6
add esp, 4
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x1003a532
mov dword [ebp - 8], 8
cmp dword [ebp - 4], 0
je 0x1003a51b
mov ecx, dword [ebp - 4]
mov dword [ebp - 0x10], ecx
push 8
mov edx, dword [ebp - 0x10]
push edx
call fcn.1003b3fc
add esp, 8
mov dword [ebp - 4], 0
mov eax, dword [ebp - 8]
mov dword [0x10098ae8], eax
mov dword [0x10098aec], 0
mov eax, dword [ebp - 8]
jmp 0x1003a568
mov ecx, dword [ebp + 8]
push ecx
call sub.KERNEL32.dll_SuspendThread
cmp eax, 0xffffffff
jne 0x1003a54a
call sub.KERNEL32.dll_GetLastError
mov dword [ebp - 8], eax
jmp 0x1003a4fa
mov edx, dword [ebp - 4]
mov eax, dword [ebp + 8]
mov dword [edx + 4], eax
mov ecx, dword [ebp - 4]
mov edx, dword [0x10098af0]
mov dword [ecx], edx
mov eax, dword [ebp - 4]
mov dword [0x10098af0], eax
xor eax, eax
mov esp, ebp
pop ebp
ret 4

Function at 0x1003e1b7
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateThread]
pop ebp
ret
Function at 0x1006086b
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.100606ea

Function at 0x100689e5
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.100686a5
Function at 0x401cd0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
sub esp, 0x10
mov esi, dword [ebp + 8]
mov dword [esp], esi
call dword [sym.imp.ucrtbase.dll_strlen]
mov ebx, eax
xor eax, eax
test ebx, ebx
je 0x401d28
cmp byte [esi + ebx - 1], 0xa
je 0x401cfc
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x24]
xchg dword [0x4030f8], eax
mov dword [esp], 2
call dword [sym.imp.ucrtbase.dll___acrt_iob_func]
mov dword [esp + 8], ebx
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], esi
call dword [sym.imp.ucrtbase.dll_fwrite]
add esp, 0x10
pop ebx
pop esi
pop ebp
ret

Function at 0x402300
Capabilities:
Get process heap flags
Terminate process

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0xc
mov dword [esp], 1
call sym.__configure_wide_argv
call sym.__initialize_wide_environment
call sym.___p___argc
mov esi, dword [eax]
call sym.___p___wargv
mov edi, dword [eax]
call sym.__get_initial_wide_environment
mov ebx, eax
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 8]
mov edx, dword [eax + 0x3c]
cmp word [eax + edx + 0x5c], 2
sete al
movzx eax, al
inc eax
mov dword [esp], eax
call sym.__set_app_type
mov dword [esp + 8], ebx
mov dword [esp + 4], edi
mov dword [esp], esi
call sym._wmain
mov dword [esp], eax
call sym._exit
nop
nop
nop
nop
nop

Function at 0x416ead
Capabilities:
Decompress data using aplib

Disassembly:
push ebp
mov ebp, esp
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
cld
mov dl, 0x80
movsb byte es:[edi], byte [esi]
call fcn.00416f2c
jae 0x416eb9
xor ecx, ecx
call fcn.00416f2c
jae 0x416ee3
xor eax, eax
call fcn.00416f2c
jae 0x416ef4
mov al, 0x10
call fcn.00416f2c
adc al, al
jae 0x416ed5
jne 0x416f21
stosb byte es:[edi], al
jmp 0x416eba
call fcn.00416f38
dec ecx
loop 0x416f00
mov eax, ebp
call fcn.00416f36
jmp 0x416f22
lodsb al, byte [esi]
shr eax, 1
je 0x416f48
adc ecx, 2
mov ebp, eax
jmp 0x416f22
xchg ecx, eax
dec eax
shl eax, 8
lodsb al, byte [esi]
mov ebp, eax
call fcn.00416f36
cmp eax, 0x7d00
jae 0x416f20
cmp eax, 0x500
jae 0x416f21
cmp eax, 0x7f
ja 0x416f22
inc ecx
inc ecx
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x416eba
pop ebp
ret 8
Function at 0x4067e0
Capabilities:
Get common file path

Disassembly:
push ecx
push ebp
push esi
push 0x549c88
xor ebp, ebp
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov esi, eax
test esi, esi
jne 0x4067fa
pop esi
pop ebp
pop ecx
ret
push ebx
push edi
push str.LoadLibraryExA
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ebx, dword [esp + 0x18]
mov edi, eax
push 0x549c74
push ebx
mov dword [esp + 0x18], edi
call fcn.0050d370
add esp, 8
test eax, eax
je 0x406846
test edi, edi
je 0x406837
push 8
push 0
push ebx
call edi
pop edi
pop ebx
pop esi
mov ebp, eax
pop ebp
pop ecx
ret
push ebx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
pop edi
pop ebx
pop esi
mov ebp, eax
pop ebp
pop ecx
ret
test edi, edi
je 0x40686c
push str.AddDllDirectory
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x40686c
push 0x800
push 0
push ebx
call edi
pop edi
pop ebx
pop esi
mov ebp, eax
pop ebp
pop ecx
ret
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov edi, eax
test edi, edi
je 0x406920
mov eax, ebx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x406885
sub eax, edx
lea eax, [eax + edi + 1]
push eax
call dword [0x5900bc]
mov esi, eax
add esp, 4
test esi, esi
je 0x406916
push edi
push esi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x406916
mov eax, esi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4068b3
sub eax, edx
mov ecx, 0x5c
mov word [eax + esi], cx
mov eax, esi
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4068d0
sub eax, edx
lea edx, [eax + esi]
mov ecx, ebx
sub edx, ebx
mov al, byte [ecx]
mov byte [edx + ecx], al
inc ecx
test al, al
jne 0x4068e0
mov eax, dword [esp + 0x10]
test eax, eax
je 0x40690d
push 8
push 0
push esi
call eax
push esi
mov ebp, eax
call dword [0x5900c0]
add esp, 4
pop edi
pop ebx
pop esi
mov eax, ebp
pop ebp
pop ecx
ret
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov ebp, eax
push esi
call dword [0x5900c0]
add esp, 4
pop edi
pop ebx
pop esi
mov eax, ebp
pop ebp
pop ecx
ret

Function at 0x406930
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x190
test byte [esp + 0x194], 2
je 0x406973
lea eax, [esp]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x406967
mov eax, dword [esp]
cmp al, 2
jne 0x406961
shr eax, 8
cmp al, 2
je 0x406973
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov eax, 2
add esp, 0x190
ret
call fcn.0041afd0
test eax, eax
jne 0x4069cf
push str.iphlpapi.dll
call fcn.004067e0
add esp, 4
mov dword [0x595cd0], eax
test eax, eax
je 0x4069a7
push str.if_nametoindex
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x4069a7
mov dword [0x595cd4], eax
push 3
push 2
push 0
push 6
call fcn.0041b1a0
add esp, 0x10
neg eax
sbb eax, eax
neg eax
push 0x5988a0
mov dword [0x5988a8], eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
xor eax, eax
add esp, 0x190
ret
Function at 0x40d960
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x20
push ebx
push ebp
push esi
mov esi, dword [esp + 0x30]
mov eax, dword [esi + 0x78]
push edi
mov dword [esp + 0x34], eax
test eax, eax
je 0x40db35
lea eax, [esp + 0x20]
push eax
call fcn.0041adc0
mov ecx, dword [eax + 4]
mov edx, dword [eax + 0xc]
mov ebp, dword [eax]
mov ebx, dword [eax + 8]
mov eax, dword [esp + 0x40]
mov edi, dword [esp + 0x3c]
add esp, 4
push 0
push 0x3e8
push eax
push edi
mov dword [esp + 0x24], ecx
mov dword [esp + 0x2c], edx
call fcn.0050c810
add ebp, eax
adc dword [esp + 0x14], edx
imul eax, eax, 0x3e8
sub edi, eax
imul edi, edi, 0x3e8
add ebx, edi
mov dword [esp + 0x10], ebp
mov dword [esp + 0x18], ebx
cmp ebx, 0xf4240
jl 0x40d9ec
add ebp, 1
adc dword [esp + 0x14], 0
sub ebx, 0xf4240
mov dword [esp + 0x10], ebp
mov dword [esp + 0x18], ebx
mov eax, dword [esi + 0xf60]
mov edi, dword [esp + 0x40]
lea ecx, [esi + 0xf60]
test eax, eax
je 0x40da1c
mov edx, dword [eax]
cmp dword [edx + 0x20], edi
je 0x40da10
mov eax, dword [eax + 8]
test eax, eax
jne 0x40da00
jmp 0x40da1c
push 0
push eax
push ecx
call fcn.004372c0
add esp, 0xc
mov ecx, edi
lea eax, [esp + 0x10]
mov edx, esi
call fcn.0040d8b0
mov eax, dword [esi + 0xf28]
or eax, dword [esi + 0xf2c]
jne 0x40da43
cmp dword [esi + 0xf30], eax
je 0x40dacd
mov ecx, dword [esi + 0xf28]
mov edx, dword [esi + 0xf2c]
sub esp, 0x10
mov eax, esp
mov dword [eax], ecx
mov ecx, dword [esi + 0xf30]
mov dword [eax + 4], edx
mov edx, dword [esi + 0xf34]
mov dword [eax + 8], ecx
mov ecx, dword [esp + 0x24]
mov dword [eax + 0xc], edx
mov edx, dword [esp + 0x2c]
sub esp, 0x10
mov eax, esp
mov dword [eax], ebp
mov dword [eax + 4], ecx
mov dword [eax + 8], ebx
mov dword [eax + 0xc], edx
call fcn.0041ae60
add esp, 0x20
test edx, edx
jg 0x40db35
jl 0x40da9d
test eax, eax
jne 0x40db35
mov edi, dword [esp + 0x34]
mov edx, dword [edi + 0x5c]
lea eax, [edi + 0x5c]
push eax
lea ecx, [esi + 0xf38]
push ecx
push edx
call fcn.0043dc70
add esp, 0xc
test eax, eax
je 0x40dad1
push eax
push str.Internal_error_removing_splay_node___d_n
push esi
call fcn.0040ffc0
add esp, 0xc
jmp 0x40dad1
mov edi, dword [esp + 0x34]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x1c]
mov dword [esi + 0xf28], ebp
mov dword [esi + 0xf2c], eax
mov dword [esi + 0xf30], ebx
mov dword [esi + 0xf34], ecx
mov dword [esi + 0xf58], esi
mov eax, dword [edi + 0x5c]
mov ecx, dword [esi + 0xf28]
lea edx, [esi + 0xf38]
push edx
mov edx, dword [esi + 0xf2c]
push eax
sub esp, 0x10
mov eax, esp
mov dword [eax], ecx
mov ecx, dword [esi + 0xf30]
mov dword [eax + 4], edx
mov edx, dword [esi + 0xf34]
mov dword [eax + 8], ecx
mov dword [eax + 0xc], edx
call fcn.0043da50
add esp, 0x18
mov dword [edi + 0x5c], eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret
Function at 0x40fe60
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
push 0
push eax
push ecx
push edx
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
jne 0x40fea3
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, dword [esp + 0x10]
xor ecx, ecx
cmp eax, 0x2733
sete cl
mov dword [edx], 0
mov eax, ecx
neg eax
sbb eax, eax
and eax, 0x19
add eax, 0x38
ret
mov ecx, dword [esp + 0x10]
mov dword [ecx], eax
xor eax, eax
ret

Function at 0x40ff20
Capabilities:
Write file on windows

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
xor edi, edi
cmp dword [esi + 0xbfc], edi
je 0x40ffb5
cmp dword [esi + 0x620], edi
je 0x40ff75
push 1
push esi
call fcn.0040dc60
mov eax, dword [esi + 0x5b4]
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x1c]
push eax
mov eax, dword [esp + 0x1c]
push ecx
mov ecx, dword [esi + 0x620]
push edx
push eax
push esi
call ecx
push 0
push esi
mov edi, eax
call fcn.0040dc60
add esp, 0x24
mov eax, edi
pop edi
pop esi
ret
mov eax, dword [esp + 0x10]
test eax, eax
js 0x40ffb5
cmp eax, 2
jg 0x40ffb5
mov edx, dword [esi + 0x5b0]
push edx
push 1
lea eax, [eax + eax*2 + 0x54a814]
push 2
push eax
call fcn.0050613e
mov ecx, dword [esi + 0x5b0]
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x24]
push ecx
push 1
push edx
push eax
call fcn.0050613e
add esp, 0x20
mov eax, edi
pop edi
pop esi
ret

Function at 0x410090
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x104
push esi
mov esi, dword [esp + 0x10c]
cmp dword [esi + 0xbfc], 0
jne 0x4100b4
cmp dword [esi + 0x5b8], 0
je 0x410190
mov ecx, dword [esp + 0x110]
lea eax, [esp + 0x114]
push eax
push ecx
lea edx, [esp + 0xc]
push 0x100
push edx
call fcn.00419960
lea eax, [esp + 0x14]
add esp, 0x10
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4100e0
sub eax, edx
mov edx, dword [esi + 0x5b8]
push edi
mov edi, eax
test edx, edx
je 0x410117
cmp dword [esi + 0x1230], 0
jne 0x410117
lea ecx, [esp + 8]
mov al, byte [ecx]
mov byte [edx], al
inc ecx
inc edx
test al, al
jne 0x410103
mov dword [esi + 0x1230], 1
mov byte [esp + edi + 8], 0xa
inc edi
cmp dword [esi + 0xbfc], 0
je 0x41018f
cmp dword [esi + 0x620], 0
je 0x410163
push 1
push esi
call fcn.0040dc60
mov eax, dword [esi + 0x5b4]
mov edx, dword [esi + 0x620]
push eax
push edi
lea ecx, [esp + 0x18]
push ecx
push 0
push esi
call edx
push 0
push esi
call fcn.0040dc60
add esp, 0x24
pop edi
pop esi
add esp, 0x104
ret
mov eax, dword [esi + 0x5b0]
push eax
push 1
push 2
push 0x54a814
call fcn.0050613e
mov ecx, dword [esi + 0x5b0]
push ecx
push 1
lea edx, [esp + 0x20]
push edi
push edx
call fcn.0050613e
add esp, 0x20
pop edi
pop esi
add esp, 0x104
ret