joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1003dde0
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x220
mov eax, dword [0x10090730]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov edi, ecx
mov ecx, dword [edi + 4]
mov edx, dword [edi]
or ecx, 0x2001f
push ecx
xor esi, esi
push eax
push edx
lea ecx, [ebp - 0x210]
mov dword [ebp - 0x218], eax
mov dword [ebp - 0x210], esi
mov dword [ebp - 0x20c], esi
mov dword [ebp - 0x208], esi
call fcn.1003cc80
mov ebx, eax
cmp ebx, esi
je 0x1003de5a
mov eax, dword [ebp - 0x210]
cmp eax, esi
je 0x1003de45
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100444a1
mov esp, ebp
pop ebp
ret 4
lea eax, [ebp - 0x220]
push eax
mov eax, dword [ebp - 0x210]
push esi
push esi
push esi
lea ecx, [ebp - 0x214]
push ecx
lea edx, [ebp - 0x204]
push edx
push esi
push eax
mov dword [ebp - 0x214], 0x100
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
jne 0x1003dedc
mov edi, edi
lea ecx, [ebp - 0x204]
push ecx
lea ecx, [ebp - 0x210]
call fcn.1003dde0
mov ebx, eax
cmp ebx, esi
jne 0x1003de34
lea edx, [ebp - 0x220]
push edx
mov edx, dword [ebp - 0x210]
push esi
push esi
push esi
lea eax, [ebp - 0x214]
push eax
lea ecx, [ebp - 0x204]
push ecx
push esi
push edx
mov dword [ebp - 0x214], 0x100
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
je 0x1003de90
mov eax, dword [ebp - 0x210]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp eax, esi
je 0x1003def5
push eax
call ebx
mov dword [ebp - 0x210], esi
mov eax, dword [ebp - 0x218]
push eax
mov ecx, edi
mov dword [ebp - 0x20c], esi
call fcn.1003cb30
mov edi, eax
mov eax, dword [ebp - 0x210]
cmp eax, esi
je 0x1003df18
push eax
call ebx
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.100444a1
mov esp, ebp
pop ebp
ret 4
Function at 0x10040ff0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10062566
mov eax, dword fs:[0]
push eax
sub esp, 0x424
mov eax, dword [0x10090730]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
mov ebx, dword [ebp + 0x10]
xor edx, edx
mov dword [ebp - 0x430], edx
mov dword [ebp - 4], edx
mov dword [ebp - 0x428], ecx
mov dword [ebp - 0x42c], edx
mov dword [ebp - 0x418], edx
push 2
push edx
push eax
mov byte [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov esi, eax
mov dword [ebp - 0x420], esi
test esi, esi
jne 0x1004106d
call fcn.1003c9b0
mov edi, eax
jmp 0x10041152
push ebx
push edi
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov edi, eax
test edi, edi
jne 0x10041086
call fcn.1003c9b0
jmp 0x10041149
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
mov dword [ebp - 0x424], ebx
test ebx, ebx
jne 0x100410a4
call fcn.1003c9b0
jmp 0x10041149
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
lea eax, [edi + 1]
mov dword [ebp - 0x41c], edi
cmp eax, edi
jae 0x100410c5
mov edi, 0x8007000e
jmp 0x1004114b
push eax
lea ecx, [ebp - 0x418]
mov byte [ebp - 4], 2
call fcn.1003eac0
mov dword [ebp - 4], 1
jmp 0x100410fd
mov eax, dword [ebp - 0x418]
test eax, eax
jne 0x1004110e
mov edi, 0x8007000e
jmp 0x1004114b
push edi
push eax
push edi
push ebx
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jne 0x10041127
call fcn.1003c9b0
jmp 0x10041149
mov edx, dword [ebp - 0x418]
xor ecx, ecx
mov word [edx + eax*2], cx
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x418]
push eax
push ecx
lea ecx, [ebp - 0x42c]
call fcn.10040a80
mov edi, eax
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea edx, [ebp - 0x414]
cmp dword [ebp - 0x418], edx
je 0x10041170
lea ecx, [ebp - 0x418]
call fcn.1003d6d0
jmp 0x10041170
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.100444a1
mov esp, ebp
pop ebp
ret 0x10

Function at 0x10041770
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x194
mov eax, dword [0x10090730]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x194]
push ecx
push 0x202
mov dword [0x100aaf2c], eax
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x100417b6
mov eax, 1
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100444a1
mov esp, ebp
pop ebp
ret 0xc
cmp byte [ebp - 0x194], 2
jne 0x100417cd
mov edx, dword [ebp - 0x192]
shr edx, 8
cmp dl, 2
je 0x100417d3
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov eax, 1
cmp dword [ebp + 0xc], eax
jne 0x100417e8
cmp byte [0x100abfc0], 0
je 0x100417e8
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100444a1
mov esp, ebp
pop ebp
ret 0xc

Function at 0x100444a1
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x10090730]
jne 0x100444ab
repz ret
jmp fcn.1004a50c
Function at 0x10057d75
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x10090730]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x1c], eax
call fcn.10049f9a
and dword [ebp - 0x14], 0
cmp dword [0x100abf28], 0
mov dword [ebp - 0x18], eax
jne 0x10057e28
push 0x1006e7ec
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x10057ed0
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x1006e7e0
push ebx
call edi
test eax, eax
je 0x10057ed0
mov esi, dword [sym.imp.KERNEL32.dll_EncodePointer]
push eax
call esi
push 0x1006e7d0
push ebx
mov dword [0x100abf28], eax
call edi
push eax
call esi
push 0x1006e7bc
push ebx
mov dword [0x100abf2c], eax
call edi
push eax
call esi
push 0x1006e7a0
push ebx
mov dword [0x100abf30], eax
call edi
push eax
call esi
mov dword [0x100abf38], eax
test eax, eax
je 0x10057e28
push 0x1006e788
push ebx
call edi
push eax
call esi
mov dword [0x100abf34], eax
mov eax, dword [0x100abf34]
mov ecx, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, ecx
je 0x10057e81
cmp dword [0x100abf38], ecx
je 0x10057e81
push eax
call esi
push dword [0x100abf38]
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x10057e81
test ebx, ebx
je 0x10057e81
call edi
test eax, eax
je 0x10057e78
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call ebx
test eax, eax
je 0x10057e78
test byte [ebp - 8], 1
jne 0x10057e81
or dword [ebp + 0x10], 0x200000
jmp 0x10057eb4
mov eax, dword [0x100abf2c]
cmp eax, dword [ebp - 0x18]
je 0x10057eb4
push eax
call esi
test eax, eax
je 0x10057eb4
call eax
mov dword [ebp - 0x14], eax
test eax, eax
je 0x10057eb4
mov eax, dword [0x100abf30]
cmp eax, dword [ebp - 0x18]
je 0x10057eb4
push eax
call esi
test eax, eax
je 0x10057eb4
push dword [ebp - 0x14]
call eax
mov dword [ebp - 0x14], eax
push dword [0x100abf28]
call esi
test eax, eax
je 0x10057ed0
push dword [ebp + 0x10]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
call eax
jmp 0x10057ed2
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.100444a1
leave
ret
Function at 0x414de9
Capabilities:
Encode data using xor

Disassembly:
xor dword [edx], edi
add edx, 4
add eax, ebx
cmp edx, ecx
jne fcn.00414de9
ret
Function at 0x40333c
Capabilities:
Accept command line arguments
Parse pe header

Disassembly:
push 0x14
push 0x410aa0
call fcn.00406024
mov eax, 0x5a4d
cmp word [0x400000], ax
jne 0x40323d
mov eax, dword [0x40003c]
cmp dword [eax + 0x400000], 0x4550
jne 0x40323d
mov ecx, 0x10b
cmp word [eax + 0x400018], cx
jne 0x40323d
cmp dword [eax + 0x400074], 0xe
jbe 0x40323d
xor ecx, ecx
cmp dword [eax + 0x4000e8], ecx
setne cl
mov dword [ebp - 0x1c], ecx
jmp 0x403241
and dword [ebp - 0x1c], 0
push 1
call main
pop ecx
test eax, eax
jne 0x403255
push 0x1c
call main
pop ecx
call fcn.00407199
test eax, eax
jne 0x403266
push 0x10
call main
pop ecx
call fcn.00406d3d
and dword [ebp - 4], 0
call fcn.00403bed
test eax, eax
jge 0x403280
push 0x1b
call main
pop ecx
call sub.kernel32.dll_GetCommandLineW
mov dword [0x413d00], eax
call fcn.00406ce0
mov dword [0x412ff8], eax
call main
test eax, eax
jge 0x4032a5
push 8
call main
pop ecx
call fcn.00406a03
test eax, eax
jge 0x4032b6
push 9
call main
pop ecx
push 1
call main
pop ecx
test eax, eax
je 0x4032c9
push eax
call main
pop ecx
mov eax, dword [0x413340]
mov dword [0x413344], eax
push eax
push dword [0x413334]
push dword [0x41332c]
call main
add esp, 0xc
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x1c], 0
jne 0x4032f7
push eax
call main
call fcn.0040428b
jmp 0x40332c
mov dword [ebp - 4], 0xfffffffe
mov eax, dword [ebp - 0x20]
call fcn.00406069
ret
call main
jmp 0x4031eb

Function at 0x40c9b9
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
pushal
call 0x40c9c8
pop dword [ebp - 0x34]
mov eax, 0x40c9c8
sub dword [ebp - 0x34], eax
push 0x40
push 0x1000
push 0x3bf7e
push 0
mov eax, 0xb155fb8b
add eax, 0x4eeae595
add eax, dword [ebp - 0x34]
call dword [eax]
mov ecx, 0xe057eef3
add ecx, 0x1fa863aa
xor edx, edx
add edx, eax
mov ebx, 0x417800
add ebx, dword [ebp - 0x34]
mov esi, 0x2fd9ddc2
xor dword [ebp - 0x1c], 0x738845ff
mov edi, dword [ebx]
xor dword [ebp - 0x1c], eax
xor edi, esi
mov dword [edx], edi
sub dword [ebp - 0x20], edx
add edx, 0x1200a8d
add edx, 0xfedff577
add ebx, 0xb7563100
add ebx, 0x48a9cf04
loop 0x40ca18
add eax, 0x13d47
mov ebx, eax
add eax, 5
mov ecx, 0x400000
add ecx, dword [ebp - 0x34]
call ebx
leave
ret
Function at 0x4097c8
Capabilities:
Allocate or change rwx memory
Get system information on windows

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xffffffbc
mov edi, eax
lea esi, [esp + 0x28]
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetSystemInfo
mov ebx, edi
push 0x1c
push esi
push ebx
call sub.kernel32.dll_VirtualQuery
test eax, eax
je 0x40987c
jmp 0x409871
cmp dword [esi + 0x10], 0x1000
jne 0x40985d
test byte [esi + 0x15], 1
jne 0x40985d
xor ebx, ebx
mov eax, dword [esi + 0x14]
cmp eax, 1
je 0x40981c
cmp eax, 2
je 0x40981c
cmp eax, 0x10
je 0x40981c
cmp eax, 0x20
jne 0x409831
push esp
push 0x40
mov eax, dword [esi + 0xc]
push eax
mov eax, dword [esi]
push eax
call sub.kernel32.dll_VirtualProtect
test eax, eax
je 0x409831
mov bl, 1
xor ebp, ebp
jmp 0x409842
mov eax, dword [esi]
add eax, ebp
call fcn.004097c0
add ebp, dword [esp + 8]
cmp ebp, dword [esi + 0xc]
jb 0x409835
test bl, bl
je 0x40985d
push esp
mov eax, dword [esp + 4]
push eax
mov eax, dword [esi + 0xc]
push eax
mov eax, dword [esi]
push eax
call sub.kernel32.dll_VirtualProtect
mov eax, dword [esi]
add eax, dword [esi + 0xc]
mov ebx, eax
push 0x1c
push esi
push ebx
call sub.kernel32.dll_VirtualQuery
test eax, eax
je 0x40987c
mov eax, dword [esi + 4]
cmp eax, edi
je 0x4097f4
add esp, 0x44
pop ebp
pop edi
pop esi
pop ebx
ret

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

Disassembly:
pushal
nop
nop
nop
mov eax, section..text
nop
nop
mov ebx, 0x408ecc
nop
mov ecx, 0x2a486715
nop
test eax, eax
nop
nop
nop
nop
nop
je 0x43004e
nop
nop
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
inc eax
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
jne 0x430024
nop
mov eax, section..rsrc
mov ebx, 0x42e1d0
nop
mov ecx, 0x4a755d39
nop
nop
test eax, eax
nop
nop
nop
nop
nop
nop
nop
je 0x430084
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
add eax, 4
nop
nop
nop
nop
nop
cmp eax, ebx
nop
jne 0x43006c
nop
nop
nop
nop
nop
nop
popal
nop
nop
jmp 0x401219
Function at 0x401530
Capabilities:
Set registry value

Disassembly:
mov edx, dword [esp + 8]
push esi
mov eax, edx
push edi
mov esi, ecx
lea edi, [eax + 2]
lea ecx, [ecx]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401540
mov ecx, dword [esp + 0xc]
sub eax, edi
sar eax, 1
add eax, eax
push eax
push edx
mov edx, dword [esi]
push 1
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
neg eax
sbb eax, eax
inc eax
je 0x401576
mov dword [esi + 4], eax
pop edi
mov al, 1
pop esi
ret 8
pop edi
xor al, al
pop esi
ret 8

Function at 0x4015b0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x527818
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push esi
push edi
mov eax, dword [0x56fcac]
xor eax, esp
push eax
lea eax, [esp + 0x20]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov edi, dword [eax]
xor esi, esi
mov dword [esp + 0xc], vtable.GameMgr::GMBuffer_unsigned_char_.0
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], esi
mov dword [esp + 0x18], esi
lea ecx, [esp + 0xc]
push ecx
mov dword [esp + 0x2c], esi
call fcn.0043d020
test al, al
jne 0x401613
mov eax, dword [esp + 0x14]
cmp eax, esi
je 0x401667
push eax
jmp 0x40165f
mov edx, dword [esp + 0x18]
mov esi, dword [esp + 0x14]
mov eax, dword [ebp + 8]
mov ecx, dword [ebx]
push edx
push esi
push edi
push 0
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
neg eax
sbb eax, eax
inc eax
je 0x40165a
test esi, esi
mov dword [ebx + 4], eax
je 0x401644
push esi
call fcn.004aaa63
add esp, 4
mov al, 1
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
test esi, esi
je 0x401667
push esi
call fcn.004aaa63
add esp, 4
xor al, al
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8

Function at 0x401680
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 8
push ebx
push esi
push edi
push 0x400
mov edi, ecx
mov dword [esp + 0x14], 1
xor bl, bl
call fcn.004f0b8f
push 0x400
mov esi, eax
push 0
push esi
call fcn.004ec1b0
mov edx, dword [esp + 0x28]
add esp, 0x10
lea eax, [esp + 0xc]
push eax
mov eax, dword [edi]
push esi
lea ecx, [esp + 0x18]
push ecx
push 0
push edx
push eax
mov dword [esp + 0x24], 0x400
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x4016f5
mov dword [edi + 4], eax
mov edi, dword [esp + 0x1c]
call fcn.00401ed0
push esi
call fcn.004ec2bb
add esp, 4
mov al, bl
pop edi
pop esi
pop ebx
add esp, 8
ret 8
mov eax, esi
mov bl, 1
lea edx, [eax + 2]
lea esp, [esp]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401700
mov ecx, dword [esp + 0x1c]
sub eax, edx
sar eax, 1
push eax
push esi
call fcn.00402af0
push esi
call fcn.004ec2bb
add esp, 4
pop edi
pop esi
mov al, bl
pop ebx
add esp, 8
ret 8
Function at 0x401730
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 8
push ebx
mov ecx, 4
mov dword [esp + 8], ecx
mov dword [esp + 4], ecx
lea ecx, [esp + 4]
push ecx
push eax
lea edx, [esp + 0x10]
push edx
mov dword [eax], 0
mov eax, dword [esp + 0x1c]
mov ecx, dword [esi]
push 0
push eax
push ecx
xor bl, bl
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x401774
mov dword [esi + 4], eax
mov al, bl
pop ebx
add esp, 8
ret 4
mov al, 1
pop ebx
add esp, 8
ret 4

Function at 0x4017d0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x52b2a8
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
push esi
push edi
mov eax, dword [0x56fcac]
xor eax, esp
push eax
lea eax, [esp + 0x28]
mov dword fs:[0], eax
mov edx, dword [ebp + 8]
xor esi, esi
lea eax, [esp + 0xc]
push eax
mov eax, dword [ebx]
push esi
lea ecx, [esp + 0x18]
push ecx
push esi
push edx
push eax
mov dword [esp + 0x28], esi
mov dword [esp + 0x24], esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, esi
je 0x401827
mov dword [ebx + 4], eax
jmp 0x401877
mov edi, dword [esp + 0xc]
lea esi, [esp + 0x14]
call fcn.004038c0
mov edi, dword [ebp + 0xc]
mov dword [esp + 0x30], 0
mov esi, dword [esp + 0x1c]
mov ecx, dword [esp + 0x10]
lea edx, [esp + 0xc]
push edx
push esi
lea eax, [esp + 0x18]
push eax
mov dword [edi], ecx
mov ecx, dword [ebp + 8]
mov edx, dword [ebx]
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x40188d
mov dword [ebx + 4], eax
test esi, esi
je 0x401877
push esi
call fcn.004aaa63
add esp, 4
xor al, al
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
mov ecx, dword [esp + 0xc]
push esi
mov edx, edi
call fcn.0043be50
test al, al
je 0x40186a
test esi, esi
je 0x4018aa
push esi
call fcn.004aaa63
add esp, 4
mov al, 1
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
Function at 0x406720
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push 0xffffffffffffffff
push 0x529b10
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x56fcac]
xor eax, esp
mov dword [esp + 0x38], eax
push ebx
push esi
push edi
mov eax, dword [0x56fcac]
xor eax, esp
push eax
lea eax, [esp + 0x4c]
mov dword fs:[0], eax
mov eax, dword [esp + 0x5c]
xor ebx, ebx
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [esp + 0x38]
mov dword [esp + 0x50], 7
mov dword [esp + 0x4c], ebx
mov word [esp + 0x3c], bx
call fcn.00403310
mov dword [esp + 0x54], ebx
mov eax, dword [esp + 0x40]
cmp eax, 2
mov edi, 8
jb 0x4067f2
cmp dword [esp + 0x44], edi
mov ecx, dword [esp + 0x30]
jae 0x406795
lea ecx, [esp + 0x30]
cmp word [ecx], 0x22
jne 0x4067f2
lea esi, [eax - 1]
cmp esi, eax
jbe 0x4067ab
call fcn.004ec14b
mov eax, dword [esp + 0x40]
cmp dword [esp + 0x44], edi
mov ecx, dword [esp + 0x30]
jae 0x4067b9
lea ecx, [esp + 0x30]
cmp word [ecx + esi*2], 0x22
jne 0x4067f2
lea edx, [eax - 2]
mov eax, 1
lea ecx, [esp + 0x2c]
lea esi, [esp + 0x10]
call fcn.00404d80
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [esp + 0x38]
mov byte [esp + 0x60], 1
call fcn.00403310
mov ecx, esi
mov byte [esp + 0x54], bl
call fcn.00401e70
push 0x548004
lea ebx, [esp + 0x30]
call fcn.00404bb0
mov eax, dword [esp + 0x34]
add esp, 4
cmp dword [esp + 0x44], edi
jae 0x406811
lea eax, [esp + 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x406834
cmp dword [esp + 0x44], edi
jb 0x406830
mov eax, dword [esp + 0x30]
push eax
call fcn.004aaa59
add esp, 4
mov al, 1
jmp 0x406849
cmp dword [esp + 0x44], edi
jb 0x406847
mov ecx, dword [esp + 0x30]
push ecx
call fcn.004aaa59
add esp, 4
xor al, al
mov ecx, dword [esp + 0x4c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x38]
xor ecx, esp
call fcn.004ead41
add esp, 0x48
ret
Function at 0x406870
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push 0xffffffffffffffff
push 0x529ad0
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x56fcac]
xor eax, esp
mov dword [esp + 0x38], eax
push ebx
push esi
push edi
mov eax, dword [0x56fcac]
xor eax, esp
push eax
lea eax, [esp + 0x4c]
mov dword fs:[0], eax
mov eax, dword [esp + 0x5c]
xor ebx, ebx
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [esp + 0x38]
mov dword [esp + 0x50], 7
mov dword [esp + 0x4c], ebx
mov word [esp + 0x3c], bx
call fcn.00403310
mov dword [esp + 0x54], ebx
mov eax, dword [esp + 0x40]
cmp eax, 2
mov edi, 8
jb 0x406942
cmp dword [esp + 0x44], edi
mov ecx, dword [esp + 0x30]
jae 0x4068e5
lea ecx, [esp + 0x30]
cmp word [ecx], 0x22
jne 0x406942
lea esi, [eax - 1]
cmp esi, eax
jbe 0x4068fb
call fcn.004ec14b
mov eax, dword [esp + 0x40]
cmp dword [esp + 0x44], edi
mov ecx, dword [esp + 0x30]
jae 0x406909
lea ecx, [esp + 0x30]
cmp word [ecx + esi*2], 0x22
jne 0x406942
lea edx, [eax - 2]
mov eax, 1
lea ecx, [esp + 0x2c]
lea esi, [esp + 0x10]
call fcn.00404d80
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [esp + 0x38]
mov byte [esp + 0x60], 1
call fcn.00403310
mov ecx, esi
mov byte [esp + 0x54], bl
call fcn.00401e70
push 0x548004
lea ebx, [esp + 0x30]
call fcn.00404bb0
mov eax, dword [esp + 0x34]
add esp, 4
cmp dword [esp + 0x44], edi
jae 0x406961
lea eax, [esp + 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x406988
test al, 0x10
jne 0x406988
cmp dword [esp + 0x44], edi
jb 0x406984
mov eax, dword [esp + 0x30]
push eax
call fcn.004aaa59
add esp, 4
mov al, 1
jmp 0x40699d
cmp dword [esp + 0x44], edi
jb 0x40699b
mov ecx, dword [esp + 0x30]
push ecx
call fcn.004aaa59
add esp, 4
xor al, al
mov ecx, dword [esp + 0x4c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x38]
xor ecx, esp
call fcn.004ead41
add esp, 0x48
ret
Function at 0x4069c0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push 0xffffffffffffffff
push 0x529a90
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x56fcac]
xor eax, esp
mov dword [esp + 0x38], eax
push ebx
push esi
push edi
mov eax, dword [0x56fcac]
xor eax, esp
push eax
lea eax, [esp + 0x4c]
mov dword fs:[0], eax
mov eax, dword [esp + 0x5c]
xor ebx, ebx
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [esp + 0x38]
mov dword [esp + 0x50], 7
mov dword [esp + 0x4c], ebx
mov word [esp + 0x3c], bx
call fcn.00403310
mov dword [esp + 0x54], ebx
mov eax, dword [esp + 0x40]
cmp eax, 2
mov edi, 8
jb 0x406a92
cmp dword [esp + 0x44], edi
mov ecx, dword [esp + 0x30]
jae 0x406a35
lea ecx, [esp + 0x30]
cmp word [ecx], 0x22
jne 0x406a92
lea esi, [eax - 1]
cmp esi, eax
jbe 0x406a4b
call fcn.004ec14b
mov eax, dword [esp + 0x40]
cmp dword [esp + 0x44], edi
mov ecx, dword [esp + 0x30]
jae 0x406a59
lea ecx, [esp + 0x30]
cmp word [ecx + esi*2], 0x22
jne 0x406a92
lea edx, [eax - 2]
mov eax, 1
lea ecx, [esp + 0x2c]
lea esi, [esp + 0x10]
call fcn.00404d80
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [esp + 0x38]
mov byte [esp + 0x60], 1
call fcn.00403310
mov ecx, esi
mov byte [esp + 0x54], bl
call fcn.00401e70
push 0x548004
lea ebx, [esp + 0x30]
call fcn.00404bb0
mov eax, dword [esp + 0x34]
add esp, 4
cmp dword [esp + 0x44], edi
jae 0x406ab1
lea eax, [esp + 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x406ad8
test al, 0x10
je 0x406ad8
cmp dword [esp + 0x44], edi
jb 0x406ad4
mov eax, dword [esp + 0x30]
push eax
call fcn.004aaa59
add esp, 4
mov al, 1
jmp 0x406aed
cmp dword [esp + 0x44], edi
jb 0x406aeb
mov ecx, dword [esp + 0x30]
push ecx
call fcn.004aaa59
add esp, 4
xor al, al
mov ecx, dword [esp + 0x4c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x38]
xor ecx, esp
call fcn.004ead41
add esp, 0x48
ret

Function at 0x406e40
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x52d318
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
mov eax, dword [0x56fcac]
xor eax, esp
mov dword [esp + 0x48], eax
push esi
push edi
mov eax, dword [0x56fcac]
xor eax, esp
push eax
lea eax, [esp + 0x58]
mov dword fs:[0], eax
mov eax, dword [esp + 0x68]
xor esi, esi
mov dword [esp + 0xc], esi
mov dword [esp + 0x10], esi
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], esi
mov dword [esp + 0x4c], 7
mov dword [esp + 0x48], esi
mov word [esp + 0x38], si
lea ecx, [esp + 0xc]
push ecx
push eax
mov dword [esp + 0x68], esi
call fcn.00406640
add esp, 8
test al, al
je 0x406eda
mov eax, dword [esp + 0x2c]
and eax, 0x10
or eax, esi
jne 0x406eda
cmp dword [esp + 0x4c], 8
mov esi, dword [esp + 0xc]
mov edi, dword [esp + 0x10]
jb 0x406ed4
mov edx, dword [esp + 0x38]
push edx
call fcn.004aaa59
add esp, 4
mov eax, esi
mov edx, edi
jmp 0x406ef2
cmp dword [esp + 0x4c], 8
jb 0x406eee
mov eax, dword [esp + 0x38]
push eax
call fcn.004aaa59
add esp, 4
xor eax, eax
xor edx, edx
mov ecx, dword [esp + 0x58]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [esp + 0x48]
xor ecx, esp
call fcn.004ead41
add esp, 0x58
ret
Function at 0x406f10
Capabilities:
Delete file
Get file attributes
Set file attributes

Disassembly:
cmp dword [edi + 0x18], 8
push esi
lea esi, [edi + 4]
jb 0x406f1e
mov eax, dword [esi]
jmp 0x406f20
mov eax, esi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
and eax, 0xfffffffe
cmp dword [edi + 0x18], 8
jb 0x406f34
mov ecx, dword [esi]
jmp 0x406f36
mov ecx, esi
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
cmp dword [edi + 0x18], 8
jb 0x406f46
mov esi, dword [esi]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
sub eax, 1
neg eax
sbb eax, eax
add eax, 1
pop esi
ret