joyce8/EMBER2024-capa huggingface dataset:
Function at 0x404529
Capabilities:
Allocate thread local storage

Disassembly:
push ebp
mov ebp, esp
push esi
push str.FlsAlloc
push 0x40e2d0
push str.FlsAlloc
push 0
call fcn.004044a2
mov esi, eax
add esp, 0x10
test esi, esi
je 0x40455b
push dword [ebp + 8]
mov ecx, esi
call fcn.0040354f
call esi
pop esi
pop ebp
ret
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsAlloc]

Function at 0x40459d
Capabilities:
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
push esi
push str.FlsSetValue
push 0x40e300
push str.FlsSetValue
push 3
call fcn.004044a2
add esp, 0x10
mov esi, eax
push dword [ebp + 0xc]
push dword [ebp + 8]
test esi, esi
je 0x4045d1
mov ecx, esi
call fcn.0040354f
call esi
jmp 0x4045d7
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
pop esi
pop ebp
ret

Function at 0x4067b1
Capabilities:
Contain obfuscated stackstrings

Disassembly:
inc ebp
test al, 0x50
call fcn.00406518
mov esi, dword [ebp + 0xc]
push eax
push esi
push dword [ebp + 8]
call fcn.004064cd
add esp, 0x10
lea ecx, [ebp - 0xb0]
push ecx
call eax
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0xac]
xor edx, edx
div ecx
xor edx, edx
mov dword [ebp - 0x8c], eax
mov eax, dword [ebp - 8]
div ecx
test edx, edx
je 0x4067f6
inc dword [ebp - 0x8c]
imul ecx, dword [ebp - 0x8c]
mov dword [ebp + 0xc], ecx
mov byte [ebp - 0x40], bl
mov byte [ebp - 0x3f], bl
mov byte [ebp - 0x3e], 0xec
mov byte [ebp - 0x3d], bl
mov byte [ebp - 0x3c], 0x45
mov byte [ebp - 0x3b], 0x7a
mov byte [ebp - 0x3a], 0x61
mov byte [ebp - 0x39], 0x67
mov byte [ebp - 0x38], 0x66
mov byte [ebp - 0x37], 0x72
mov byte [ebp - 0x36], 0x7f
mov byte [ebp - 0x35], 0x52
mov byte [ebp - 0x34], 0x7f
mov byte [ebp - 0x33], 0x7f
mov byte [ebp - 0x32], 0x7c
mov byte [ebp - 0x31], 0x70
mov byte [ebp - 0x30], 0x13
call fcn.00406508
and dl, byte [edx - 0x2c]
retf 0x458d

Function at 0x4068aa
Capabilities:
Contain obfuscated stackstrings

Disassembly:
neg dl
mov byte [ebp - 9], 0xbf
call fcn.00406518
push eax
push esi
push dword [ebp + 8]
call fcn.004064cd
mov dword [ebp - 8], eax
lea eax, [ebp - 0x6c]
push eax
mov byte [ebp - 0x6c], bl
mov byte [ebp - 0x6b], bl
mov byte [ebp - 0x6a], 0xbe
mov byte [ebp - 0x69], bl
mov byte [ebp - 0x68], 0x17

Function at 0x406945
Capabilities:
Contain obfuscated stackstrings

Disassembly:
mov byte [ebp - 0x24], 0x67
mov byte [ebp - 0x23], 0x42
mov byte [ebp - 0x22], 0x49
mov byte [ebp - 0x21], 0x59
mov byte [ebp - 0x20], 0x4a
mov byte [ebp - 0x1f], 0x59
mov byte [ebp - 0x1e], 0x52
mov byte [ebp - 0x1d], 0x6a
mov byte [ebp - 0x1c], 0x2b
call fcn.00406518
push eax
push esi
push dword [ebp + 8]
call fcn.004064cd
add esp, 0x30
mov dword [ebp - 0xb8], eax
call fcn.00406508
cmpsb byte [esi], byte es:[edi]
inc eax
invalid
mov dl, 0x88
popfd
invalid
Function at 0x433004
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
mov eax, section..text
nop
nop
mov ebx, 0x40de38
mov ecx, 0x26d30d99
nop
nop
test eax, eax
nop
nop
nop
nop
nop
nop
nop
je 0x43304e
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
jne 0x433024
nop
nop
nop
mov eax, section..text_1
nop
nop
mov ebx, 0x4304d8
nop
mov ecx, 0x6d857744
nop
nop
nop
nop
test eax, eax
nop
nop
nop
nop
je 0x433084
nop
nop
nop
nop
xor dword [eax], ecx
add eax, 4
nop
nop
nop
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
jne 0x43306c
nop
nop
nop
nop
popal
nop
nop
jmp 0x431219

Function at 0x4020a2
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x403a50
push fcn.00402290
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x68
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
xor ebx, ebx
mov dword [ebp - 4], ebx
push 2
pop edi
push edi
or edx, dword [sym.imp.MSVCRT.dll___set_app_type]
pop ecx
or dword [0x405c8c], 0xffffffff
or dword [0x405c90], 0xffffffff
call dword [sym.imp.MSVCRT.dll___p__fmode]
mov ecx, dword [0x405c80]
mov dword [eax], ecx
call dword [sym.imp.MSVCRT.dll___p__commode]
mov ecx, dword [0x405c7c]
mov dword [eax], ecx
mov eax, dword [sym.imp.MSVCRT.dll__adjust_fdiv]
mov eax, dword [eax]
mov dword [0x405c88], eax
call fcn.004022e1
cmp dword [eax + 0x405ba0], edx
jne 0x402127
push 0x4022de
call dword [sym.imp.MSVCRT.dll___setusermatherr]
pop ecx
call fcn.004022cc
push 0x405014
push 0x405010
call sub.MSVCRT.dll__initterm
mov eax, dword [0x405c78]
mov dword [ebp - 0x6c], eax
lea eax, [ebp - 0x6c]
push eax
push dword [0x405c74]
lea eax, [ebp - 0x64]
push eax
lea eax, [ebp - 0x70]
push eax
lea eax, [ebp - 0x60]
push eax
nop
adc eax, sym.imp.MSVCRT.dll___wgetmainargs
push 0x40500c
push section..data
call sub.MSVCRT.dll__initterm
add esp, 0
mov eax, dword [sym.imp.MSVCRT.dll__wcmdln]
mov esi, dword [eax]
cmp esi, ebx
jne 0x40218f
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
leave
ret
mov dword [ebp - 0x74], esi
cmp word [esi], 0x22
jne 0x4021dd
add esi, edi
mov dword [ebp - 0x74], esi
mov ax, word [esi]
cmp ax, bx
je 0x4021ab
cmp ax, 0x22
jne 0x402198
cmp word [esi], 0x22
jne 0x4021b6
add esi, edi
mov dword [ebp - 0x74], esi
mov ax, word [esi]
cmp ax, bx
je 0x4021c4
cmp ax, 0x20
jbe 0x4021b1
mov dword [ebp - 0x30], ebx
lea eax, [ebp - 0x5c]
push eax
call dword [sym.imp.KERNEL32.dll_Ordinal_52133]
test byte [ebp - 0x30], 1
je 0x4021ea
movzx eax, word [ebp - 0x2c]
jmp 0x4021ed
cmp word [esi], 0x20
jbe 0x4021b6
add esi, edi
mov dword [ebp - 0x74], esi
jmp 0x4021dd
push 0xa
pop eax
push eax
push esi
push ebx
push ebx
call dword [0x403014]
push eax
call main
mov dword [ebp - 0x68], eax
push eax
call dword [sym.imp.MSVCRT.dll_exit]
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax]
mov ecx, dword [ecx]
mov dword [ebp - 0x78], ecx
push eax
push ecx
call sub.MSVCRT.dll__XcptFilter
pop ecx
pop ecx
ret
Function at 0x41a0ec
Capabilities:
Log keystrokes

Disassembly:
push ebp
mov ebp, esp
push ecx
mov byte [ebp - 2], dl
mov byte [ebp - 1], al
mov al, byte [ebp - 1]
and eax, 0xff
bt dword [0x41d260], eax
jae 0x41a125
xor eax, eax
mov al, byte [ebp - 2]
add eax, 1
jno 0x41a116
call fcn.00402f1c
cmp eax, 0xff
jbe 0x41a122
call fcn.00402f14
mov byte [ebp - 2], al
push 0
xor eax, eax
mov al, byte [ebp - 2]
push eax
push 0
xor eax, eax
mov al, byte [ebp - 1]
push eax
call sub.user32.dll_MapVirtualKeyA
cmp eax, 0xff
jbe 0x41a146
call fcn.00402f14
push eax
mov al, byte [ebp - 1]
push eax
call sub.user32.dll_keybd_event
pop ecx
pop ebp
ret

Function at 0x433003
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
call 0x43300c
pop eax
nop
nop
nop
nop
nop
nop
add eax, 0x40a063
sub eax, 0x40a009
nop
nop
mov ebx, dword [eax]
nop
nop
nop
nop
nop
mov ecx, dword [eax + 4]
nop
mov edx, dword [eax + 8]
nop
nop
nop
nop
nop
nop
xor dword [ebx], edx
nop
nop
nop
add ebx, 4
nop
nop
cmp ebx, ecx
nop
nop
nop
nop
nop
nop
jl 0x433030
nop
nop
nop
nop
add eax, 0xc
nop
cmp dword [eax], 0
nop
nop
nop
nop
jne 0x43301e
nop
nop
popal
nop
nop
nop
nop
nop
jmp fcn.00431219
Function at 0x403c31
Capabilities:
Accept command line arguments

Disassembly:
push ecx
push ecx
push ebx
push ebp
push esi
push edi
push dword [0x446648]
call fcn.00405a47
mov ebp, eax
or ebx, 0xffffffff
xor eax, eax
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov edi, dword [esp + 0x1c]
movzx edx, word [eax]
test dx, dx
je 0x403d31
mov ecx, dword [esp + 0x1c]
mov dword [esp + 0x10], 0x20
mov dword [esp + 0x14], 0x22
cmp dx, word [esp + 0x10]
jne 0x403c87
push 0x20
pop edx
add eax, 2
cmp word [eax], dx
je 0x403c7f
movzx edx, word [eax]
mov dword [esp + 0x1c], 1
cmp dx, word [esp + 0x14]
jne 0x403cc7
add eax, 2
mov esi, eax
movzx ecx, word [eax]
test cx, cx
je 0x403d09
push 0x22
pop edx
cmp cx, dx
je 0x403cb9
add eax, 2
movzx ecx, word [eax]
test cx, cx
jne 0x403ca9
xor ecx, ecx
cmp word [eax], cx
je 0x403d09
mov ecx, eax
add eax, 2
jmp 0x403d0b
test dx, dx
je 0x403d11
push 0x20
mov esi, eax
pop ecx
cmp dx, cx
je 0x403cb9
add eax, 2
push 0x22
pop edx
cmp word [eax], dx
jne 0x403cff
add eax, 2
movzx ecx, word [eax]
test cx, cx
je 0x403d09
cmp cx, dx
je 0x403cfc
add eax, 2
movzx ecx, word [eax]
test cx, cx
jne 0x403cec
push 0x20
pop ecx
movzx edx, word [eax]
test dx, dx
jne 0x403cd1
jmp 0x403cb9
mov ecx, eax
mov edx, dword [esp + 0x1c]
jmp 0x403d13
xor edx, edx
cmp dword [ebp], ebx
jne 0x403d1c
test edi, edi
jne 0x403d39
test edx, edx
je 0x403d21
inc ebx
xor edx, edx
mov esi, edx
movzx edx, word [eax]
test dx, dx
jne 0x403c75
test edi, edi
jne 0x403d4a
mov eax, ebx
jmp 0x403d4e
test esi, esi
je 0x403d4a
sub ecx, esi
mov eax, esi
sar ecx, 1
mov dword [edi], ecx
inc dword [ebp]
jmp 0x403d4e
xor ecx, ecx
mov dword [edi], ecx
pop edi
pop esi
pop ebp
pop ebx
pop ecx
pop ecx
ret

Function at 0x403dbc
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push edi
xor edi, edi
cmp dword [ebp + 8], edi
je 0x403e5a
cmp dword [ebp + 0xc], edi
je 0x403e5a
push esi
push 0x58
push 8
push dword [0x44627c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push dword [ebp + 8]
mov esi, eax
or dword [esi + 4], 0xffffffff
mov dword [esi], edi
call sub.MSVCRT.dll__wcsdup
push dword [ebp + 0xc]
mov dword [esi + 8], eax
call sub.MSVCRT.dll__wcsdup
push dword [ebp + 0x14]
mov dword [esi + 0xc], eax
call sub.MSVCRT.dll__wcsdup
mov dword [esi + 0x38], eax
add esp, 0xc
mov eax, dword [ebp + 0x10]
mov dword [esi + 0x24], eax
test al, 1
je 0x403e49
lea eax, [ebp + 8]
push eax
push edi
push esi
push 0x403fd2
push 0x10000
push edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
je 0x403e41
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, esi
jmp 0x403e59
push esi
call fcn.00404023
jmp 0x403e58
push esi
call fcn.00403e73
push esi
mov edi, eax
call fcn.00404023
pop ecx
pop ecx
pop esi
mov eax, edi
pop edi
pop ebp
ret 0x10
Function at 0x403e73
Capabilities:
Delete file

Disassembly:
push ecx
push ecx
push ebx
push ebp
push esi
mov esi, dword [esp + 0x18]
xor ebx, ebx
push edi
mov ebp, dword [esi + 0xc]
push dword [esi + 8]
mov dword [esp + 0x18], ebp
call fcn.0043bcf0
push dword [esi + 0x38]
mov dword [esp + 0x20], eax
call fcn.0043bcf0
mov dword [esp + 0x10], eax
call fcn.004067e0
mov edi, eax
test edi, edi
je 0x403fa8
push ebx
push pe_nt_image_headers32
push 2
push ebx
push 1
push 0xc0000000
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x403f93
test byte [esi + 0x24], 2
mov dword [esi + 0x10], ebp
jne 0x403ee5
push 1
push 0x34
push edi
call fcn.00409730
add esp, 0xc
mov eax, dword [0x446290]
test eax, eax
je 0x403efd
push eax
push 0x2714
push edi
call fcn.00409730
add esp, 0xc
mov eax, dword [0x446294]
test eax, eax
je 0x403f2e
cmp dword [0x446298], ebx
je 0x403f2e
push eax
push 0x27bf
push edi
call fcn.00409730
push dword [0x446298]
push 0x27c0
push edi
call fcn.00409730
add esp, 0x18
push dword [esp + 0x1c]
push 0x2712
push edi
call fcn.00409730
push dword [esp + 0x1c]
push 0x2722
push edi
call fcn.00409730
push 0x403fe1
push 0x4e2b
push edi
call fcn.00409730
push esi
push 0x2711
push edi
call fcn.00409730
push edi
call fcn.00406880
add esp, 0x34
test eax, eax
jne 0x403f7e
cmp dword [esi + 4], 0xfffffffb
je 0x403f7e
xor ebx, ebx
inc ebx
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test ebx, ebx
jne 0x403f93
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push edi
call fcn.004067c0
pop ecx
cmp ebx, 1
jne 0x403fa8
mov dword [esi + 4], 0xfffffffe
jmp 0x403fb7
xor ecx, ecx
cmp dword [esi + 4], 0xfffffffb
setne cl
add ecx, 0xfffffffc
mov dword [esi + 4], ecx
push dword [esp + 0x1c]
call fcn.0043bce0
push dword [esp + 0x10]
call fcn.0043bce0
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
pop ecx
pop ecx
ret

Function at 0x4046f6
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x190
cmp word [0x44629c], 0
jne 0x4047b8
push edi
lea eax, [esp + 4]
push eax
push 0x101
call dword [sym.imp.WS2_32.dll_WSAStartup]
xor edi, edi
inc edi
test eax, eax
jne 0x40472b
mov word [0x44629c], di
jmp 0x404733
xor eax, eax
mov word [0x44629c], ax
push str.ws2_32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [0x4462b8], eax
test eax, eax
je 0x4047b7
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x43c068
push eax
call esi
push 0x43c074
push dword [0x4462b8]
mov dword [0x4462a8], eax
call esi
push str.getnameinfo
push dword [0x4462b8]
mov dword [0x4462ac], eax
call esi
push str.WSAStringToAddressA
push dword [0x4462b8]
mov dword [0x4462b0], eax
call esi
cmp dword [0x4462a8], 0
mov dword [0x4462b4], eax
pop esi
je 0x4047b7
cmp dword [0x4462ac], 0
je 0x4047b7
cmp dword [0x4462b0], 0
je 0x4047b7
test eax, eax
je 0x4047b7
mov dword [0x4462a0], edi
pop edi
movsx eax, word [0x44629c]
add esp, 0x190
ret
Function at 0x404860
Capabilities:
Write file on windows

Disassembly:
push ecx
push esi
mov esi, dword [esp + 0xc]
mov dword [esp + 4], 0
cmp dword [esi + 0x14], 0
jne 0x40489c
push 0
lea eax, [esp + 8]
push eax
mov eax, dword [esi + 8]
sub eax, dword [esi + 0xc]
push eax
push dword [esi + 4]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esi + 8]
mov dword [esi + 0xc], eax
mov eax, dword [esp + 4]
pop esi
pop ecx
ret 4
xor eax, eax
pop esi
pop ecx
ret 4

Function at 0x404b10
Capabilities:
Read file on windows

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push ebx
push dword [0x446674]
mov dword [esp + 0x10], 0
call fcn.00405ab0
mov ebp, eax
test ebp, ebp
je 0x404c6c
push esi
push edi
push ebx
call fcn.00405010
cmp dword [ebp + 4], 0
mov esi, eax
mov edi, edx
je 0x404b5c
push 4
lea eax, [esp + 0x1c]
push eax
push ebp
call fcn.004051f0
mov ecx, eax
mov dword [esp + 0x10], ecx
jmp 0x404b77
push 0
lea eax, [esp + 0x14]
push eax
push 4
lea eax, [esp + 0x24]
push eax
push dword [ebp]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [esp + 0x10]
cmp ecx, 2
jl 0x404ba5
lea edx, [esp + 0x18]
mov eax, 0xfeff
cmp word [edx], ax
jne 0x404ba5
add esi, 2
adc edi, 0
push edi
push esi
push ebx
call fcn.00405080
pop edi
pop esi
pop ebp
mov eax, 0x19
pop ebx
pop ecx
ret 4
cmp ecx, 3
jl 0x404bd6
lea edx, [esp + 0x18]
cmp word [edx], 0xbbef
jne 0x404bd6
cmp byte [edx + 2], 0xbf
jne 0x404bd6
add esi, 3
adc edi, 0
push edi
push esi
push ebx
call fcn.00405080
pop edi
pop esi
pop ebp
mov eax, 2
pop ebx
pop ecx
ret 4
cmp ecx, 2
jl 0x404c04
lea edx, [esp + 0x18]
mov eax, 0xfffe
cmp word [edx], ax
jne 0x404c04
add esi, 2
adc edi, 0
push edi
push esi
push ebx
call fcn.00405080
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
pop ecx
ret 4
cmp ecx, 4
jl 0x404c57
lea eax, [esp + 0x18]
cmp dword [eax], 0xfeff
jne 0x404c30
add esi, 4
adc edi, 0
push edi
push esi
push ebx
call fcn.00405080
pop edi
pop esi
pop ebp
mov eax, 5
pop ebx
pop ecx
ret 4
lea eax, [esp + 0x18]
cmp dword [eax], 0xfffe0000
jne 0x404c57
add esi, 4
adc edi, 0
push edi
push esi
push ebx
call fcn.00405080
pop edi
pop esi
pop ebp
mov eax, 6
pop ebx
pop ecx
ret 4
push edi
push esi
push ebx
call fcn.00405080
pop edi
pop esi
pop ebp
mov eax, 0x18
pop ebx
pop ecx
ret 4
pop ebp
mov eax, 0x18
pop ebx
pop ecx
ret 4

Function at 0x404d90
Capabilities:
Write file on windows

Disassembly:
push ecx
push dword [esp + 8]
mov dword [esp + 4], 0
push dword [0x446674]
call fcn.00405ab0
test eax, eax
je 0x404dd9
cmp dword [eax + 4], 0
je 0x404dc3
push 2
lea ecx, [esp + 0x10]
push ecx
push eax
call fcn.004057c0
pop ecx
ret 8
push 0
lea ecx, [esp + 4]
push ecx
push 2
lea ecx, [esp + 0x18]
push ecx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp]
pop ecx
ret 8
Function at 0x404de0
Capabilities:
Read file on windows

Disassembly:
sub esp, 8
push esi
push dword [esp + 0x10]
mov dword [esp + 8], 0
push dword [0x446674]
call fcn.00405ab0
mov esi, eax
test esi, esi
je 0x404e5f
cmp dword [esi + 4], 0
je 0x404e30
push 1
lea eax, [esp + 8]
push eax
push esi
call fcn.004051f0
test eax, eax
je 0x404e24
inc dword [esi + 0xc]
xor eax, eax
pop esi
add esp, 8
ret 4
mov eax, 1
pop esi
add esp, 8
ret 4
push 0
lea eax, [esp + 0xc]
push eax
push 1
lea eax, [esp + 0x1c]
push eax
push dword [esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x404e6a
cmp dword [esp + 8], 0
je 0x404e6a
push 1
push 0
push 0xffffffffffffffff
push dword [esi]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 4]
pop esi
add esp, 8
ret 4
or eax, 0xffffffff
pop esi
add esp, 8
ret 4

Function at 0x404e80
Capabilities:
Write file on windows

Disassembly:
push ecx
mov edx, dword [esp + 0xc]
mov dword [esp], 0
test edx, edx
je 0x404f88
cmp word [edx], 0
je 0x404f88
mov ecx, dword [esp + 0x10]
push esi
mov esi, dword [esp + 0xc]
test ecx, ecx
jne 0x404eae
mov ecx, dword [esi + 0x18]
push edi
cmp ecx, 0x19
jne 0x404f0d
cmp dword [esi + 4], 0
mov ecx, edx
lea edi, [ecx + 2]
je 0x404ee0
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x404ec0
sub ecx, edi
sar ecx, 1
lea eax, [ecx + ecx]
push eax
push edx
push esi
call fcn.004057c0
pop edi
pop esi
pop ecx
ret 0xc
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x404ee0
sub ecx, edi
lea eax, [esp + 8]
push 0
sar ecx, 1
push eax
lea eax, [ecx + ecx]
push eax
push edx
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 8]
pop edi
pop esi
pop ecx
ret 0xc
xor eax, eax
cmp ecx, 2
lea ecx, [esp + 0x14]
setne al
push ecx
dec eax
and eax, 0xfde9
push edx
push eax
call fcn.004058d0
mov edi, eax
test edi, edi
je 0x404f03
cmp dword [esi + 4], 0
je 0x404f5b
push dword [esp + 0x14]
push edi
push esi
call fcn.004057c0
push edi
push 0
push dword [0x44627c]
mov dword [esp + 0x14], eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [esp + 8]
pop edi
pop esi
pop ecx
ret 0xc
push 0
lea eax, [esp + 0xc]
push eax
push dword [esp + 0x1c]
push edi
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
push 0
push dword [0x44627c]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [esp + 8]
pop edi
pop esi
pop ecx
ret 0xc
xor eax, eax
pop ecx
ret 0xc

Function at 0x404f90
Capabilities:
Write file on windows

Disassembly:
push dword [esp + 4]
push dword [0x446674]
call fcn.00405ab0
test eax, eax
je 0x404fac
mov dword [esp + 4], eax
jmp fcn.00404e80
xor eax, eax
ret 0xc

Function at 0x405130
Capabilities:
Read file on windows

Disassembly:
push ecx
push dword [esp + 8]
mov dword [esp + 4], 0
push dword [0x446674]
call fcn.00405ab0
test eax, eax
je 0x40517d
cmp dword [eax + 4], 0
je 0x405167
push 2
lea ecx, [esp + 4]
push ecx
push eax
call fcn.004051f0
movsx eax, word [esp]
pop ecx
ret 4
push 0
lea ecx, [esp + 0xc]
push ecx
push 2
lea ecx, [esp + 0xc]
push ecx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_ReadFile]
movsx eax, word [esp]
pop ecx
ret 4
Function at 0x405190
Capabilities:
Read file on windows

Disassembly:
push ecx
push dword [esp + 8]
mov dword [esp + 4], 0
push dword [0x446674]
call fcn.00405ab0
test eax, eax
je 0x4051dc
cmp dword [eax + 4], 0
je 0x4051c6
push 4
lea ecx, [esp + 4]
push ecx
push eax
call fcn.004051f0
mov eax, dword [esp]
pop ecx
ret 4
push 0
lea ecx, [esp + 0xc]
push ecx
push 4
lea ecx, [esp + 0xc]
push ecx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp]
pop ecx
ret 4

Function at 0x4051f0
Capabilities:
Read file on windows

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
push edi
cmp dword [esi + 0x14], 0
jne 0x405211
push esi
call fcn.00404860
mov dword [esi + 0x14], 1
mov dword [esi + 0xc], 0
mov ebx, dword [esi + 0xc]
mov edi, dword [esp + 0x18]
mov eax, dword [esi + 0x10]
cmp ebx, edi
jl 0x405285
add eax, dword [esi + 4]
mov ecx, edi
sub eax, ebx
dec ecx
je 0x405272
dec ecx
je 0x40525d
sub ecx, 2
je 0x40524a
push edi
push eax
push dword [esp + 0x1c]
call sub.MSVCRT.dll_memcpy
add esp, 0xc
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
pop ebx
ret 0xc
mov ecx, dword [eax]
mov eax, dword [esp + 0x14]
mov dword [eax], ecx
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
pop ebx
ret 0xc
mov cx, word [eax]
mov eax, dword [esp + 0x14]
mov word [eax], cx
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
pop ebx
ret 0xc
mov ecx, dword [esp + 0x14]
mov dl, byte [eax]
mov eax, edi
mov byte [ecx], dl
sub dword [esi + 0xc], edi
pop edi
pop esi
pop ebx
ret 0xc
push ebp
mov ebp, dword [esp + 0x18]
sub eax, ebx
add eax, dword [esi + 4]
push ebx
push eax
push ebp
call sub.MSVCRT.dll_memcpy
mov eax, dword [esi + 8]
add esp, 0xc
sub edi, ebx
add ebp, ebx
push 0
cmp edi, eax
jl 0x4052ca
lea eax, [esp + 0x18]
push eax
push edi
push ebp
push dword [esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
pop ebp
pop edi
mov dword [esi + 0xc], 0
add eax, ebx
pop esi
pop ebx
ret 0xc
lea ecx, [esp + 0x18]
push ecx
push eax
push dword [esi + 4]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
cmp edi, eax
jle 0x4052eb
mov edi, eax
push edi
push dword [esi + 4]
push ebp
call sub.MSVCRT.dll_memcpy
sub dword [esi + 0xc], edi
lea eax, [ebx + edi]
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
ret 0xc
Function at 0x405310
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x14
push 0x1000
push 0
push dword [0x44627c]
mov dword [esp + 0x14], 0x1000
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, eax
mov dword [esp + 0x10], edx
test edx, edx
je 0x405494
mov cl, byte [esp + 3]
push ebx
mov ebx, dword [esp + 0x1c]
push ebp
mov ebp, dword [esp + 0x28]
push esi
push edi
mov esi, edx
mov edi, edi
cmp ebp, 0xffffffff
je 0x40535e
test ebp, ebp
je 0x405400
dec ebp
cmp dword [ebx + 4], 0
je 0x405377
push 1
lea eax, [esp + 0x17]
push eax
push ebx
call fcn.004051f0
mov dword [esp + 0x14], eax
jmp 0x405391
push 0
lea eax, [esp + 0x18]
push eax
push 1
lea eax, [esp + 0x1f]
push eax
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
mov cl, byte [esp + 0x13]
cmp eax, 1
jne 0x405400
test cl, cl
je 0x4053a5
mov byte [esi], cl
inc esi
mov cl, byte [esp + 0x13]
mov eax, dword [esp + 0x18]
mov edi, esi
mov edx, dword [esp + 0x20]
dec eax
sub edi, edx
cmp edi, eax
jle 0x4053e0
mov eax, dword [esp + 0x18]
add eax, 0x1000
push eax
push edx
push 8
push dword [0x44627c]
mov dword [esp + 0x28], eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov cl, byte [esp + 0x13]
mov edx, eax
mov dword [esp + 0x20], edx
lea esi, [edi + edx]
test cl, cl
je 0x405400
cmp dword [esp + 0x2c], 0
jne 0x405350
cmp cl, 0xd
je 0x405407
cmp cl, 0xa
jne 0x405350
dec esi
jmp 0x405477
cmp dword [esp + 0x2c], 0
jne 0x405477
cmp cl, 0xa
jne 0x40540f
dec esi
jmp 0x405477
cmp cl, 0xd
jne 0x405477
dec esi
cmp dword [ebx + 4], 0
je 0x40542e
push 1
lea eax, [esp + 0x17]
push eax
push ebx
call fcn.004051f0
mov dword [esp + 0x14], eax
jmp 0x405444
push 0
lea eax, [esp + 0x18]
push eax
push 1
lea eax, [esp + 0x1f]
push eax
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp byte [esp + 0x13], 0xa
je 0x405477
cmp dword [ebx + 4], 0
je 0x405456
inc dword [ebx + 0xc]
jmp 0x405477
push 1
lea eax, [esp + 0x20]
mov dword [esp + 0x1c], 0xffffffff
push eax
push 0xffffffffffffffff
push dword [ebx]
mov dword [esp + 0x2c], 0
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 0x34]
mov ecx, esi
sub ecx, dword [esp + 0x20]
pop edi
mov dword [eax], ecx
mov eax, dword [esp + 0x1c]
mov byte [esi], 0
pop esi
pop ebp
pop ebx
add esp, 0x14
ret 0x10
xor eax, eax
add esp, 0x14
ret 0x10