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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov eax, dword [0x45e640]
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
xor ebx, ebx
push str.kernel32.dll
mov dword [ebp - 4], eax
mov dword [ebp - 0x18], ebx
xor esi, esi
call edi
push str.GetUserDefaultUILanguage
push eax
mov dword [ebp - 0x20], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x446118
call eax
mov esi, dword [sym.imp.KERNEL32.dll_ConvertDefaultLocale]
mov ebx, 0x3ff
mov edi, 0xfc00
mov dword [ebp - 0x18], eax
movzx eax, ax
mov ecx, eax
and ecx, ebx
movzx ecx, cx
and eax, edi
or eax, ecx
push eax
mov dword [ebp - 0x1c], ecx
call esi
push dword [ebp - 0x1c]
mov dword [ebp - 0x3c], eax
call esi
push str.GetSystemDefaultUILanguage
push dword [ebp - 0x20]
mov dword [ebp - 0x38], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
call eax
mov dword [ebp - 0x18], eax
movzx eax, ax
mov ecx, eax
and ecx, ebx
movzx ebx, cx
and eax, edi
or eax, ebx
push eax
call esi
push ebx
mov dword [ebp - 0x34], eax
call esi
mov dword [ebp - 0x30], eax
push 4
xor ebx, ebx
jmp 0x44621a
call dword [sym.imp.KERNEL32.dll_GetVersion]
test eax, eax
jns 0x4461c8
lea eax, [ebp - 0x1c]
push eax
push 0x20019
push ebx
push str.Control_PanelDesktopResourceLocale
push SysReAllocStringLen
mov dword [ebp - 0x1c], ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x44621b
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x24]
push eax
push ebx
push ebx
push dword [ebp - 0x1c]
mov dword [ebp - 0x20], 0x10
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4461bd
cmp dword [ebp - 0x24], 1
jne 0x4461bd
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x14]
push 0x44df74
push eax
call fcn.00430fc7
add esp, 0xc
cmp eax, 1
jne 0x4461bd
mov eax, dword [ebp - 0x28]
mov esi, dword [sym.imp.KERNEL32.dll_ConvertDefaultLocale]
mov dword [ebp - 0x18], eax
movzx eax, ax
mov ecx, eax
and ecx, 0x3ff
movzx edi, cx
and eax, 0xfc00
or eax, edi
push eax
call esi
push edi
mov dword [ebp - 0x3c], eax
call esi
push 2
mov dword [ebp - 0x38], eax
pop esi
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x44621b
push str.ntdll.dll
call edi
cmp eax, ebx
je 0x44621b
lea ecx, [ebp - 0x18]
push ecx
push 0x446060
push 1
push 0x10
push eax
mov dword [ebp - 0x18], ebx
call dword [sym.imp.KERNEL32.dll_EnumResourceLanguagesA]
cmp word [ebp - 0x18], bx
je 0x44621b
movzx eax, word [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_ConvertDefaultLocale]
mov ecx, eax
and ecx, 0x3ff
movzx edi, cx
and eax, 0xfc00
or eax, edi
push eax
call esi
push edi
mov dword [ebp - 0x3c], eax
call esi
mov dword [ebp - 0x38], eax
push 2
pop esi
mov dword [ebp + esi*4 - 0x3c], 0x800
inc esi
xor edi, edi
cmp esi, ebx
jle 0x446241
push dword [ebp + edi*4 - 0x3c]
push dword [ebp + 8]
call fcn.00445fe1
cmp eax, ebx
pop ecx
pop ecx
jne 0x446243
inc edi
cmp edi, esi
jl 0x44622a
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.0042fa01
leave
ret 4
Function at 0x446252
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push edi
xor edi, edi
mov dword [ecx + 0x9c], edi
cmp dword [str.SoftwareMicrosoftWindowsCurrentVersionPoliciesExplorer], edi
mov dword [ebp - 0x10], ecx
mov dword [ebp - 4], edi
mov dword [ebp - 8], edi
mov dword [ebp - 0x14], 4
mov dword [ebp - 0xc], edi
mov ebx, 0x45d694
je 0x44630e
push esi
lea eax, [ebp - 4]
push eax
push 1
push edi
push dword [ebx]
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4462f6
mov esi, dword [ebx + 4]
jmp 0x4462f0
lea ecx, [ebp - 0x14]
push ecx
lea ecx, [ebp - 8]
push ecx
lea ecx, [ebp - 0xc]
push ecx
push edi
push eax
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4462e0
cmp dword [ebp - 0xc], 4
jne 0x4462e0
cmp dword [ebp - 8], edi
mov eax, dword [ebp - 0x10]
mov ecx, dword [esi + 4]
je 0x4462d8
or dword [eax + 0x9c], ecx
jmp 0x4462e0
not ecx
and dword [eax + 0x9c], ecx
mov dword [ebp - 8], edi
mov dword [ebp - 0x14], 4
mov dword [ebp - 0xc], edi
add esi, 8
mov eax, dword [esi]
cmp eax, edi
jne 0x4462a4
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
add ebx, 8
cmp dword [ebx], edi
mov dword [ebp - 4], edi
jne 0x446287
pop esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop edi
inc eax
pop ebx
leave
ret

Function at 0x4466fc
Capabilities:
Query or enumerate registry key

Disassembly:
mov eax, 0x44a9be
call fcn.00430ffc
sub esp, 0x11c
mov eax, dword [0x45e640]
push ebx
push esi
push edi
mov dword [ebp - 0x14], eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
mov dword [ebp - 0x10], esp
lea ecx, [ebp - 0x124]
push ecx
push eax
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov esi, eax
test esi, esi
jne 0x4467f5
push 0x104
lea eax, [ebp - 0x11c]
push eax
push 0
push dword [ebp - 0x124]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
mov esi, eax
test esi, esi
jne 0x4467c9
and dword [ebp - 4], eax
lea eax, [ebp - 0x11c]
push eax
lea ecx, [ebp - 0x120]
call fcn.00402160
lea eax, [ebp - 0x120]
push eax
push dword [ebp - 0x124]
mov byte [ebp - 4], 1
call fcn.004466fc
mov ecx, dword [ebp - 0x120]
mov esi, eax
test esi, esi
setne bl
add ecx, 0xfffffff0
mov byte [ebp - 4], 0
call fcn.004019a0
test bl, bl
jne 0x4467c9
or dword [ebp - 4], 0xffffffff
jmp 0x44673a
cmp esi, 0x103
je 0x4467d9
cmp esi, 0x3f2
jne 0x4467e9
mov eax, dword [ebp + 0xc]
push dword [eax]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov esi, eax
push dword [ebp - 0x124]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov ecx, dword [ebp - 0x14]
mov eax, esi
call fcn.0042fa01
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x447a25
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
push edi
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov edi, dword [esp + 0x10]
test edi, edi
jle 0x447a5a
cmp edi, dword [esi + 0xc]
jge 0x447a5a
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x447a5a
cmp edi, dword [eax + 8]
jge 0x447a5a
mov eax, dword [eax + 0xc]
mov edi, dword [eax + edi*4]
jmp 0x447a5c
xor edi, edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, edi
pop edi
pop esi
pop ebx
ret 4

Function at 0x447b60
Capabilities:
Allocate thread local storage

Disassembly:
xor eax, eax
push esi
mov esi, ecx
mov dword [esi + 0x14], eax
mov dword [esi + 0x18], eax
mov dword [esi + 0x18], 4
mov dword [esi + 4], eax
mov dword [esi + 8], 1
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
mov dword [esi], eax
jne 0x447b94
jmp fcn.0043cce6
lea eax, [esi + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov eax, esi
pop esi
ret

Function at 0x447c05
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, ecx
lea esi, [edi + 0x1c]
push esi
mov dword [ebp - 4], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebp + 8]
xor ebx, ebx
cmp eax, ebx
jle 0x447cfe
cmp eax, dword [edi + 0xc]
jge 0x447cfe
push dword [edi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
cmp esi, ebx
je 0x447c56
mov ecx, dword [ebp + 8]
cmp ecx, dword [esi + 8]
jl 0x447ce7
cmp dword [ebp + 0xc], ebx
je 0x447ce7
jmp 0x447c80
push 0x10
call fcn.004478f1
cmp eax, ebx
je 0x447c6c
mov ecx, eax
call fcn.00447b57
mov esi, eax
jmp 0x447c6e
xor esi, esi
mov dword [esi + 8], ebx
mov dword [esi + 0xc], ebx
mov ecx, dword [edi + 0x14]
mov eax, dword [edi + 0x18]
mov dword [esi + eax], ecx
mov dword [edi + 0x14], esi
mov eax, dword [esi + 0xc]
cmp eax, ebx
jne 0x447c97
mov eax, dword [edi + 0xc]
shl eax, 2
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
jmp 0x447ca7
mov ecx, dword [edi + 0xc]
push 2
shl ecx, 2
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_LocalReAlloc]
cmp eax, ebx
jne 0x447cb9
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call fcn.0043cce6
mov ecx, dword [esi + 8]
mov dword [esi + 0xc], eax
mov edx, dword [edi + 0xc]
sub edx, ecx
shl edx, 2
push edx
lea eax, [eax + ecx*4]
push ebx
push eax
call fcn.00431420
mov eax, dword [edi + 0xc]
add esp, 0xc
push esi
mov dword [esi + 8], eax
push dword [edi]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov ecx, dword [ebp + 8]
mov eax, dword [esi + 0xc]
cmp eax, ebx
je 0x447cf9
cmp ecx, dword [esi + 8]
jge 0x447cf9
mov edx, dword [ebp + 0xc]
mov dword [eax + ecx*4], edx
push dword [ebp - 4]
jmp 0x447cff
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x447dbd
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x447deb
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x447e09
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.00447d27
jmp 0x447e09
mov eax, dword [esi + 0x14]
test eax, eax
je 0x447e09
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
push eax
mov ecx, esi
call fcn.00447d27
test edi, edi
mov eax, edi
jne 0x447df3
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
mov ecx, dword [0x5727ec]
test ecx, ecx
je 0x447ebc
jmp 0x447dbc
ret 8
Function at 0x402bff
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
push ebx
push esi
lea eax, [ebp - 4]
push edi
push eax
mov eax, dword [0x4292b0]
or al, 8
xor ebx, ebx
push eax
push ebx
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
jne 0x402c93
mov esi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
mov edi, 0x105
jmp 0x402c50
cmp dword [ebp + 0x10], ebx
jne 0x402c87
lea eax, [ebp - 0x210]
push ebx
push eax
push dword [ebp - 4]
call fcn.00402bff
test eax, eax
jne 0x402c62
lea eax, [ebp - 0x210]
push edi
push eax
push ebx
push dword [ebp - 4]
call esi
test eax, eax
je 0x402c37
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 3
call fcn.004063f4
cmp eax, ebx
je 0x402c9a
push ebx
push dword [0x4292b0]
push dword [ebp + 0xc]
push dword [ebp + 8]
call eax
jmp 0x402c93
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret 0xc
cmp dword [0x4292b0], ebx
jne 0x402c90
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
test eax, eax
jne 0x402c90
jmp 0x402c93
Function at 0x403027
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x90
push ebx
push esi
mov esi, dword [ebp + 0x14]
push edi
mov edi, dword [ebp + 0x10]
mov dword [ebp - 8], esi
test edi, edi
jne 0x403047
mov dword [ebp - 8], 0x8000
and dword [ebp - 4], 0
mov ebx, edi
test edi, edi
jne 0x403056
mov ebx, 0x40fea0
mov eax, dword [ebp + 8]
test eax, eax
jl 0x40306b
mov ecx, dword [0x429258]
add ecx, eax
push ecx
call fcn.00403222
lea eax, [ebp + 0x14]
push 4
push eax
call fcn.0040320c
test eax, eax
je 0x4031c3
test byte [ebp + 0x17], 0x80
je 0x4031ac
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x40be10
mov dword [ebp - 0xc], eax
call fcn.00406513
and dword [ebp + 0x14], 0x7fffffff
mov eax, dword [ebp + 0x14]
mov dword [ebp + 8], eax
jle 0x403202
mov esi, 0x4000
cmp dword [ebp + 0x14], esi
jge 0x4030bb
mov esi, dword [ebp + 0x14]
mov edi, 0x40bea0
push esi
push edi
call fcn.0040320c
test eax, eax
je 0x4031c3
sub dword [ebp + 0x14], esi
mov dword [0x40be28], edi
mov dword [0x40be2c], esi
mov eax, dword [ebp - 8]
mov ecx, 0x40be10
mov dword [0x40be30], ebx
mov dword [0x40be34], eax
call fcn.00406533
test eax, eax
mov dword [ebp - 0x10], eax
jl 0x4031a4
mov esi, dword [0x40be30]
sub esi, ebx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
test byte [0x4292b4], 1
mov edi, eax
je 0x403163
sub eax, dword [ebp - 0xc]
cmp eax, 0xc8
ja 0x40312a
cmp dword [ebp + 0x14], 0
jne 0x403163
mov eax, dword [ebp + 8]
push dword [ebp + 8]
sub eax, dword [ebp + 0x14]
push 0x64
push eax
call dword [sym.imp.KERNEL32.dll_MulDiv]
push eax
lea eax, [ebp - 0x90]
push str....__d__
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea eax, [ebp - 0x90]
push eax
push 0
call fcn.00405179
mov dword [ebp - 0xc], edi
test esi, esi
je 0x403198
cmp dword [ebp + 0x10], 0
jne 0x403180
push esi
push ebx
push dword [ebp + 0xc]
call fcn.00405ca1
test eax, eax
je 0x4031a8
add dword [ebp - 4], esi
jmp 0x40318c
add dword [ebp - 4], esi
sub dword [ebp - 8], esi
mov ebx, dword [0x40be30]
cmp dword [ebp - 0x10], 1
jne 0x4030de
jmp 0x403202
cmp dword [ebp + 0x14], 0
jg 0x4030ae
jmp 0x403202
push 0xfffffffffffffffc
jmp 0x4031c5
push 0xfffffffffffffffe
jmp 0x4031c5
test edi, edi
je 0x4031f7
cmp dword [ebp + 0x14], esi
jge 0x4031b8
mov esi, dword [ebp + 0x14]
push esi
push edi
call fcn.0040320c
test eax, eax
jne 0x4031ff
push 0xfffffffffffffffd
pop eax
jmp 0x403205
mov esi, dword [ebp - 8]
cmp dword [ebp + 0x14], esi
jge 0x4031d3
mov esi, dword [ebp + 0x14]
mov edi, 0x40bea0
push esi
push edi
call fcn.0040320c
test eax, eax
je 0x4031c3
push esi
push edi
push dword [ebp + 0xc]
call fcn.00405ca1
test eax, eax
je 0x4031a8
add dword [ebp - 4], esi
sub dword [ebp + 0x14], esi
cmp dword [ebp + 0x14], 0
jg 0x4031c8
jmp 0x403202
mov dword [ebp - 4], esi
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x405648
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, 0x4073f8
and byte [ebp - 0x1f], 0
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x20]
and dword [ebp - 0x14], 0
and dword [ebp - 4], 0
mov dword [ebp - 8], eax
lea eax, [ebp - 0xc]
push esi
push eax
mov byte [ebp - 0x20], 1
push dword [ebp + 8]
mov word [ebp - 0x1e], 4
mov dword [ebp - 0x10], 0x4073e8
mov dword [ebp - 0xc], 0xc
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x405699
xor eax, eax
jmp 0x4056c0
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 0xb7
jne 0x4056c0
lea eax, [ebp - 0x20]
push eax
push 0x80000007
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityW]
test eax, eax
jne 0x405695
call esi
pop esi
leave
ret 4

Function at 0x4056fa
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
lea eax, [ebp - 0x10]
mov dword [0x4256f0], 0x44
push eax
xor eax, eax
push 0x4256f0
push eax
push eax
push 0x4000000
push eax
push eax
push eax
push dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x405739
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
leave
ret 4

Function at 0x4057c3
Capabilities:
Delete directory
Delete file
Set file attributes

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
push esi
call fcn.00405bca
mov edi, eax
cmp edi, 0xffffffff
je 0x405804
test byte [esp + 0x10], 1
push esi
je 0x4057e6
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x4057ec
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x4057f5
xor eax, eax
inc eax
jmp 0x405806
test byte [esp + 0x10], 4
jne 0x405804
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
xor eax, eax
pop edi
pop esi
ret 8
Function at 0x40580b
Capabilities:
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x258
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
mov eax, ebx
and eax, 4
push edi
mov dword [ebp - 4], eax
call fcn.00405ad6
test bl, 8
mov dword [ebp - 8], eax
je 0x40584a
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
neg eax
sbb eax, eax
inc eax
add dword [0x429288], eax
jmp 0x4059c7
mov dword [ebp + 8], ebx
and dword [ebp + 8], 1
je 0x405864
test eax, eax
je 0x405975
test bl, 2
je 0x405975
mov esi, 0x4246f0
push edi
push esi
call fcn.0040601a
cmp dword [ebp + 8], 0
je 0x405883
push str..
push esi
call sub.KERNEL32.dll_lstrcatW
jmp 0x405889
push edi
call fcn.00405a1a
cmp word [edi], 0
jne 0x405899
cmp word [0x4246f0], 0x5c
jne 0x4058a4
push 0x409014
push edi
call sub.KERNEL32.dll_lstrcatW
push edi
call sub.KERNEL32.dll_lstrlenW
lea ebx, [edi + eax*2]
lea eax, [ebp - 0x258]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x40596a
cmp word [ebp - 0x22c], 0x2e
jne 0x4058ee
cmp word [ebp - 0x22a], 0
je 0x40594d
cmp word [ebp - 0x22a], 0x2e
jne 0x4058ee
cmp word [ebp - 0x228], 0
je 0x40594d
lea eax, [ebp - 0x22c]
push eax
push ebx
call fcn.0040601a
test byte [ebp - 0x258], 0x10
je 0x405919
mov eax, dword [ebp + 0xc]
and eax, 3
cmp al, 3
jne 0x40594d
push dword [ebp + 0xc]
push edi
call fcn.0040580b
jmp 0x40594d
push dword [ebp - 4]
push edi
call fcn.004057c3
test eax, eax
jne 0x405945
cmp dword [ebp - 4], eax
je 0x40593d
push edi
push 0xfffffffffffffff1
call fcn.00405179
push 0
push edi
call fcn.00405ebb
jmp 0x40594d
inc dword [0x429288]
jmp 0x40594d
push edi
push 0xfffffffffffffff2
call fcn.00405179
lea eax, [ebp - 0x258]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x4058c6
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [ebp + 8], 0
je 0x405975
and word [ebx - 2], 0
xor esi, esi
cmp dword [ebp + 8], esi
je 0x4059c7
cmp dword [ebp - 8], esi
jne 0x405989
inc dword [0x429288]
jmp 0x4059c7
push edi
call fcn.0040635d
test eax, eax
je 0x4059c7
push edi
call fcn.004059ce
mov eax, dword [ebp - 4]
or al, 1
push eax
push edi
call fcn.004057c3
test eax, eax
jne 0x4059bf
cmp dword [ebp - 4], esi
je 0x405981
push edi
push 0xfffffffffffffff1
call fcn.00405179
push esi
push edi
call fcn.00405ebb
jmp 0x4059c7
push edi
push 0xffffffffffffffe5
call fcn.00405179
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x405ad6
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
push dword [esp + 0xc]
mov esi, 0x424ef0
push esi
call fcn.0040601a
push esi
call fcn.00405a79
mov edi, eax
test edi, edi
jne 0x405af7
xor eax, eax
jmp 0x405b4f
push edi
call fcn.004062ae
test byte [0x429218], 0x80
je 0x405b14
mov ax, word [edi]
test ax, ax
je 0x405af3
cmp ax, 0x5c
je 0x405af3
sub edi, esi
sar edi, 1
jmp 0x405b2e
call fcn.0040635d
test eax, eax
je 0x405b28
test byte [eax], 0x10
je 0x405af3
push esi
call fcn.00405a1a
push esi
call sub.KERNEL32.dll_lstrlenW
cmp eax, edi
push esi
jg 0x405b1a
call fcn.004059ce
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
pop edi
pop esi
ret 4

Function at 0x405bca
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
push esi
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov esi, eax
cmp esi, 0xffffffff
je 0x405be9
and al, 0xfe
push eax
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov eax, esi
pop esi
ret 4

Function at 0x405bef
Capabilities:
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ecx, eax
push 0
inc ecx
neg ecx
sbb ecx, ecx
and ecx, eax
push ecx
push dword [esp + 0x14]
push 0
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
ret 0xc

Function at 0x405c1e
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
mov esi, dword [ebp + 8]
push edi
push 0x64
pop edi
mov eax, dword [0x409550]
dec edi
mov dword [ebp - 8], eax
mov eax, dword [0x409554]
mov dword [ebp - 4], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x1a
xor edx, edx
pop ecx
div ecx
push esi
lea eax, [ebp - 8]
push 0
push eax
push dword [ebp + 0xc]
add word [ebp - 4], dx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x405c6e
test edi, edi
jne 0x405c2b
and word [esi], di
pop edi
pop esi
leave
ret 8
mov eax, esi
jmp 0x405c68
Function at 0x405d49
Capabilities:
Get file size

Disassembly:
push ebx
push ebp
push esi
push edi
mov ebx, 0x425d88
push 0x409574
push ebx
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov esi, dword [esp + 0x18]
mov ebp, dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
test esi, esi
mov edi, 0x400
je 0x405d97
push 1
push 0
push esi
call fcn.00405bef
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebx
push esi
call ebp
test eax, eax
je 0x405eb6
cmp eax, edi
jg 0x405eb6
mov esi, 0x426588
push edi
push esi
push dword [esp + 0x1c]
call ebp
test eax, eax
je 0x405eb6
cmp eax, edi
jg 0x405eb6
push esi
push ebx
push str._ls_ls_r_n
push 0x425988
call dword [sym.imp.USER32.dll_wsprintfA]
mov ebx, eax
mov eax, dword [0x429210]
add esp, 0x10
push dword [eax + 0x128]
push esi
call fcn.0040603c
push 4
push 0xc0000000
push esi
call fcn.00405bef
mov ebp, eax
cmp ebp, 0xffffffff
mov dword [esp + 0x18], ebp
je 0x405eb6
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea eax, [edi + ebx + 0xa]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x405eaf
push edi
push esi
push ebp
call fcn.00405c72
test eax, eax
je 0x405eaf
push str._Rename__r_n
push esi
call fcn.00405b54
test eax, eax
jne 0x405e4d
lea eax, [esi + edi]
push str._Rename__r_n
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
add edi, 0xa
jmp 0x405e82
add eax, 0xa
push 0x409558
push eax
call fcn.00405b54
mov ebp, eax
test ebp, ebp
je 0x405e7e
lea ecx, [esi + edi]
lea eax, [ecx + ebx]
jmp 0x405e6f
mov dl, byte [ecx]
mov byte [eax], dl
dec eax
dec ecx
cmp ecx, ebp
ja 0x405e69
sub ebp, esi
inc ebp
mov eax, ebp
mov ebp, dword [esp + 0x18]
jmp 0x405e84
mov ebp, dword [esp + 0x18]
mov eax, edi
push ebx
add eax, esi
push 0x425988
push eax
call fcn.00405baa
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
add edi, ebx
push edi
push esi
push ebp
call fcn.00405ca1
push esi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x405ebb
Capabilities:
Move file

Disassembly:
push 5
push dword [esp + 0xc]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x405ede
push dword [esp + 8]
push dword [esp + 8]
call fcn.00405d49
pop ecx
pop ecx
inc dword [0x429290]
ret 8
Function at 0x405ee7
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push esi
lea eax, [ebp + 0x18]
push edi
push eax
mov eax, dword [ebp + 0x18]
xor edi, edi
neg eax
sbb eax, eax
mov esi, dword [ebp + 0x14]
and eax, 0x100
or eax, 0x20019
mov word [esi], di
push eax
push edi
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x405f5b
lea eax, [ebp + 0xc]
mov dword [ebp + 0xc], 0x800
push eax
lea eax, [ebp + 0x14]
push esi
push eax
push edi
push dword [ebp + 0x10]
push dword [ebp + 0x18]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x405f48
cmp dword [ebp + 0x14], 1
je 0x405f4b
cmp dword [ebp + 0x14], 2
je 0x405f4b
mov word [esi], di
push dword [ebp + 0x18]
mov word [esi + 0x7fe], di
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
pop ebp
ret 0x14