joyce8/EMBER2024-capa huggingface dataset:
Function at 0x45f6f0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
sub esp, 0xc
push ebx
mov ebx, dword [esp + 0x14]
push ebp
push esi
push edi
push 2
push 0
mov dword [esp + 0x20], ecx
push ebx
mov dword [esp + 0x1c], 0
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
mov ebp, eax
test ebp, ebp
je 0x45f8a0
mov eax, dword [esp + 0x24]
test eax, eax
je 0x45f869
push 0xe
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x45f899
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x45f899
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
test edi, edi
je 0x45f899
xor eax, eax
mov ax, word [edi + 4]
shl eax, 5
add eax, 0x210
push eax
call fcn.00462607
mov esi, eax
add esp, 4
test esi, esi
mov dword [esp + 0x10], esi
je 0x45f899
xor ecx, ecx
lea edx, [esi + 0x108]
mov cx, word [edi + 4]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcpyA]
push edx
mov dword [esi + 0x20c], ecx
call ebx
lea eax, [esi + 4]
push 0x5187f4
push eax
call ebx
mov eax, dword [esi + 0x20c]
mov dword [esp + 0x24], 0
test eax, eax
jbe 0x45f869
mov ecx, esi
add edi, 0x12
mov dword [esp + 0x20], edi
lea ebx, [ecx + 0x21c]
mov eax, dword [esp + 0x20]
xor edx, edx
push 3
mov dx, word [eax]
push edx
push ebp
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
test esi, esi
je 0x45f87e
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
test edi, edi
je 0x45f885
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push eax
mov dword [ebx + 4], eax
call fcn.00462607
add esp, 4
mov dword [ebx], eax
mov esi, dword [ebx + 4]
push edi
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, dword [ebx]
mov ecx, esi
mov esi, eax
mov edx, ecx
lea eax, [ebx - 0xc]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x1c]
call fcn.0045f5b0
test eax, eax
je 0x45f88c
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x24]
mov edi, dword [esp + 0x20]
inc eax
mov edx, dword [ecx + 0x20c]
add edi, 0xe
add ebx, 0x20
cmp eax, edx
mov dword [esp + 0x24], eax
mov dword [esp + 0x20], edi
jb 0x45f7cc
push ebp
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret 8
mov edx, dword [esp + 0x10]
push edx
jmp 0x45f891
mov eax, dword [esp + 0x10]
push eax
jmp 0x45f891
mov ecx, dword [esp + 0x10]
push ecx
call fcn.0046251e
add esp, 4
push ebp
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xc
ret 8
Function at 0x45f8b0
Capabilities:
Write file on windows

Disassembly:
push ecx
push esi
mov esi, dword [esp + 0xc]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
lea eax, [esp + 0x10]
push 0
push eax
lea ecx, [esp + 0x10]
push 2
push ecx
push esi
mov dword [esp + 0x1c], 0
call edi
test eax, eax
jne 0x45f8e0
pop edi
pop esi
pop ecx
ret 8
cmp dword [esp + 0x10], 2
je 0x45f8ef
pop edi
xor eax, eax
pop esi
pop ecx
ret 8
lea edx, [esp + 0x10]
push 0
push edx
lea eax, [esp + 0x10]
push 2
push eax
push esi
mov dword [esp + 0x1c], 1
call edi
test eax, eax
jne 0x45f912
pop edi
pop esi
pop ecx
ret 8
cmp dword [esp + 0x10], 2
je 0x45f921
pop edi
xor eax, eax
pop esi
pop ecx
ret 8
mov ecx, dword [esp + 0x14]
lea edx, [esp + 0x10]
push 0
push edx
lea eax, [esp + 0x10]
push 2
push eax
push esi
mov dword [esp + 0x1c], ecx
call edi
test eax, eax
jne 0x45f944
pop edi
pop esi
pop ecx
ret 8
mov ecx, dword [esp + 0x10]
xor eax, eax
cmp ecx, 2
pop edi
sete al
pop esi
pop ecx
ret 8
Function at 0x45f990
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x18
push ebx
mov eax, dword [esp + 0x24]
push ebp
push esi
push edi
push 0
push 0x80
push 2
push 0
push 0
mov esi, ecx
push 0x40000000
push eax
mov dword [esp + 0x30], esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
mov dword [esp + 0x10], ebx
je 0x45fb07
mov edi, dword [esp + 0x2c]
mov ecx, dword [edi + 0x20c]
push ecx
push ebx
mov ecx, esi
call fcn.0045f8b0
test eax, eax
jne 0x45f9f3
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x18
ret 8
mov eax, dword [edi + 0x20c]
xor ebp, ebp
test eax, eax
jbe 0x45faa2
lea esi, [edi + 0x224]
mov al, byte [esi - 0x10]
mov dl, byte [esi - 0x14]
mov byte [esp + 0x19], al
mov eax, dword [esi]
mov byte [esp + 0x18], dl
mov byte [esp + 0x1b], 0
mov cx, word [eax + 0xc]
mov word [esp + 0x1c], cx
mov dx, word [eax + 0xe]
mov word [esp + 0x1e], dx
mov ecx, dword [esp + 0x1e]
mov eax, dword [esp + 0x1c]
and ecx, 0xffff
and eax, 0xffff
imul ecx, eax
cmp ecx, 8
jl 0x45fa52
mov byte [esp + 0x1a], 0
jmp 0x45fa5a
mov dl, 1
shl dl, cl
mov byte [esp + 0x1a], dl
mov eax, dword [esi - 4]
mov ecx, dword [esp + 0x14]
push ebp
push edi
mov dword [esp + 0x28], eax
call fcn.0045f960
lea ecx, [esp + 0x30]
push 0
push ecx
lea edx, [esp + 0x20]
push 0x10
push edx
push ebx
mov dword [esp + 0x38], eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x45fb07
cmp dword [esp + 0x30], 0x10
jne 0x45fb07
mov eax, dword [edi + 0x20c]
inc ebp
add esi, 0x20
cmp ebp, eax
jb 0x45fa09
mov eax, dword [edi + 0x20c]
xor ebx, ebx
test eax, eax
jbe 0x45fafc
lea esi, [edi + 0x224]
mov eax, dword [esi]
push 0
mov ebp, dword [eax + 0x14]
mov dword [eax + 0x14], 0
mov ecx, dword [esi - 4]
mov edx, dword [esi - 8]
lea eax, [esp + 0x34]
push eax
mov eax, dword [esp + 0x18]
push ecx
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x45fb07
mov ecx, dword [esp + 0x30]
mov eax, dword [esi - 4]
cmp ecx, eax
jne 0x45fb07
mov edx, dword [esi]
inc ebx
add esi, 0x20
mov dword [edx + 0x14], ebp
mov eax, dword [edi + 0x20c]
cmp ebx, eax
jb 0x45fab4
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x18
ret 8
Function at 0x45fb20
Capabilities:
Open clipboard
Write clipboard data

Disassembly:
push esi
push 0
call dword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
je 0x45fb9f
call dword [sym.imp.USER32.dll_EmptyClipboard]
test eax, eax
je 0x45fb9f
mov esi, dword [esp + 8]
mov eax, dword [esi + 0x10]
test eax, eax
je 0x45fb9f
push ebx
push ebp
push edi
push eax
push 0x2002
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebx, eax
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov ecx, dword [esi + 0x10]
mov esi, dword [esi + 0xc]
mov ebp, eax
mov eax, ecx
mov edi, ebp
push ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [ebp + 8]
cdq
sub eax, edx
sar eax, 1
mov dword [ebp + 8], eax
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push ebx
push 8
call dword [sym.imp.USER32.dll_SetClipboardData]
call dword [sym.imp.USER32.dll_CloseClipboard]
pop edi
pop ebp
pop ebx
mov eax, 1
pop esi
ret 4
xor eax, eax
pop esi
ret 4

Function at 0x45fd20
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x10
mov eax, dword [esp + 0x14]
push ebx
push ebp
push esi
xor ebp, ebp
push edi
push ebp
push 0x80
push 2
push ebp
push ebp
push 0x40000000
mov edi, ecx
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x45fe0d
mov esi, dword [esp + 0x28]
mov ecx, edi
push esi
mov word [esp + 0x14], 0x4d42
mov word [esp + 0x1a], bp
mov word [esp + 0x1c], bp
call fcn.0045fce0
and eax, 0xffff
push esi
add eax, 0x36
mov ecx, edi
mov dword [esp + 0x1e], eax
call fcn.0045fcf0
imul eax, dword [esi + 8]
mov edx, dword [esp + 0x1a]
lea ecx, [esp + 0x24]
add eax, edx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_WriteFile]
push ecx
lea edx, [esp + 0x18]
push 0xe
shr eax, 2
push edx
push ebx
mov dword [esp + 0x26], eax
call ebp
test eax, eax
je 0x45fe06
cmp dword [esp + 0x24], 0xe
jne 0x45fe06
mov eax, dword [esi + 8]
push esi
cdq
sub eax, edx
mov ecx, edi
sar eax, 1
mov dword [esi + 8], eax
call fcn.0045fcf0
mov edi, eax
mov ecx, dword [esp + 0x1a]
imul edi, dword [esi + 8]
lea eax, [esp + 0x24]
add edi, ecx
push 0
push eax
push edi
push esi
push ebx
call ebp
test eax, eax
je 0x45fe06
cmp dword [esp + 0x24], edi
jne 0x45fe06
mov ecx, dword [esi + 8]
push ebx
shl ecx, 1
mov dword [esi + 8], ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x10
ret 8
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x10
ret 8

Function at 0x4737b2
Capabilities:
Get graphical window text

Disassembly:
push esi
mov esi, ecx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x4737ea
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [esp + 0xc]
push eax
call fcn.00471871
push eax
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov ecx, dword [esp + 8]
push 0xffffffffffffffff
call fcn.00471849
jmp 0x4737f6
mov eax, dword [ecx]
push dword [esp + 8]
call dword [eax + 0x88]
pop esi
ret 4
Function at 0x474ea3
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x474ee5
call fcn.0047a820
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x474ee5
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x474edc
xor eax, eax
jmp 0x474eed
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.00474ef3
pop edi
pop esi
pop ebx
ret 4

Function at 0x47ad50
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 0x47ad7e
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x47ad9c
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.0047acb6
jmp 0x47ad9c
mov eax, dword [esi + 0x14]
test eax, eax
je 0x47ad9c
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.0047acb6
test edi, edi
mov eax, edi
jne 0x47ad86
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8

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

Disassembly:
pushal
nop
mov eax, section..text
nop
nop
push 4
nop
nop
nop
nop
nop
nop
pop edi
nop
nop
cmp eax, 0
nop
nop
nop
nop
je 0x430072
nop
nop
nop
nop
mov ebx, 0x408e84
nop
nop
nop
mov ecx, ebx
nop
nop
nop
nop
nop
sub ecx, eax
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
push eax
nop
nop
nop
nop
mov eax, ecx
nop
nop
nop
nop
div edi
nop
nop
nop
nop
xchg ecx, eax
nop
nop
nop
nop
pop eax
nop
nop
nop
nop
nop
mov esi, 0x727e53ba
nop
nop
xor dword [eax], esi
nop
nop
nop
nop
add eax, edi
nop
nop
nop
nop
loop 0x430060
nop
nop
mov eax, section..data
nop
nop
nop
cmp eax, 0
nop
nop
nop
nop
nop
je 0x4300d2
nop
mov ebx, 0x42e1d0
mov ecx, ebx
nop
nop
nop
nop
nop
nop
sub ecx, eax
nop
nop
nop
nop
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
push eax
mov eax, ecx
nop
nop
nop
nop
nop
div edi
nop
nop
nop
nop
nop
nop
xchg ecx, eax
nop
nop
nop
nop
nop
pop eax
nop
nop
mov esi, 0x482d6278
nop
nop
nop
xor dword [eax], esi
nop
nop
nop
nop
nop
add eax, edi
nop
nop
nop
loop 0x4300c0
nop
nop
nop
nop
nop
nop
popal
nop
jmp 0x401219
Function at 0x4037ea
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x46a008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 0xc]
lea eax, [ebp - 0x20c]
push esi
push edi
mov edi, dword [ebp + 0x10]
push 0x208
push 0
push eax
call fcn.0042f670
add esp, 0xc
lea eax, [ebp - 0x20c]
mov esi, 0x104
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
jne 0x403852
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x4038bf
mov esi, 0x80004005
jmp 0x4038bf
push 0x5c
pop ecx
cmp cx, word [ebp + eax*2 - 0x20e]
je 0x40387e
push 1
push 0x44b790
push esi
lea eax, [ebp - 0x20c]
push eax
call fcn.00403665
mov esi, eax
test esi, esi
js 0x4038bf
mov esi, 0x104
push dword [ebp + 8]
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.004036b4
mov esi, eax
test esi, esi
js 0x4038bf
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [ebx], eax
test eax, eax
je 0x403833
test edi, edi
je 0x4038bf
push 0x104
lea eax, [ebp - 0x20c]
push eax
push edi
call fcn.004021a5
mov esi, eax
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0042de36
mov esp, ebp
pop ebp
ret 0xc
Function at 0x404013
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push dword [ebp + 0xc]
mov edi, dword [ebp + 8]
xor esi, esi
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x4040da
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x404043
xor esi, esi
jmp 0x4040da
cmp eax, 3
je 0x404054
push 0
push edi
call fcn.004040e2
test eax, eax
jne 0x40403c
movzx eax, word [edi]
mov ecx, edi
push ebx
xor ebx, ebx
test ax, ax
je 0x4040c7
push 0x5c
pop edx
cmp ax, dx
cmove ebx, ecx
add ecx, 2
movzx eax, word [ecx]
test ax, ax
jne 0x404064
test ebx, ebx
je 0x4040c7
push dword [ebp + 0xc]
xor eax, eax
push edi
mov word [ebx], ax
call fcn.00404013
mov esi, eax
push 0x5c
pop eax
mov word [ebx], ax
test esi, esi
js 0x4040d9
push dword [ebp + 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x4040c3
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x4040b3
xor esi, esi
inc esi
jmp 0x4040d9
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
jmp 0x4040d9
xor esi, esi
jmp 0x4040d9
mov esi, 0x80070003
push esi
push 0x72
push str.dirutil.cpp
call fcn.004037d3
pop ebx
pop edi
mov eax, esi
pop esi
pop ebp
ret 8

Function at 0x4040e2
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push esi
push dword [ebp + 8]
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x404106
test al, 0x10
je 0x404106
mov ecx, dword [ebp + 0xc]
test ecx, ecx
je 0x404103
mov dword [ecx], eax
xor esi, esi
inc esi
mov eax, esi
pop esi
pop ebp
ret 8
Function at 0x40999b
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push esi
push edi
mov edi, dword [ebp + 8]
push 0
push eax
push dword [edi + 0x14]
push dword [ebp + 0xc]
call fcn.004071cf
mov esi, eax
test esi, esi
jns 0x4099cb
push str.Failed_to_format_variable_string.
jmp 0x409a53
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x409a26
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
cmp esi, 0x80070002
je 0x4099fd
cmp esi, 0x80070003
jne 0x4099ff
xor esi, esi
xorps xmm0, xmm0
movlpd qword [ebp - 0xc], xmm0
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 8]
test esi, esi
jns 0x409a39
push dword [ebp - 4]
push dword [edi]
push str.Failed_while_searching_directory_search:__ls__for_path:__ls
push esi
call fcn.0044012f
add esp, 0x10
jmp 0x409a5b
xorps xmm0, xmm0
movlpd qword [ebp - 0xc], xmm0
test al, 0x10
je 0x409a07
xor ecx, ecx
inc ecx
xor eax, eax
jmp 0x409a0d
push 0
push eax
push ecx
push dword [edi + 4]
push dword [ebp + 0xc]
call fcn.00408152
mov esi, eax
test esi, esi
jns 0x409a5b
push str.Failed_to_set_variable.
push esi
call fcn.0044012f
pop ecx
pop ecx
push dword [ebp - 4]
call fcn.00402793
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret 8

Function at 0x409a6d
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push esi
push edi
mov edi, dword [ebp + 8]
push 0
push eax
push dword [edi + 0x14]
push dword [ebp + 0xc]
call fcn.004071cf
mov esi, eax
test esi, esi
jns 0x409aa3
push str.Failed_to_format_variable_string.
push esi
call fcn.0044012f
pop ecx
pop ecx
jmp 0x409b2d
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x409ac7
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
jmp 0x409aed
test al, 0x10
je 0x409ae8
push 0
push dword [ebp - 4]
push dword [edi + 4]
push dword [ebp + 0xc]
call fcn.004080f6
mov esi, eax
test esi, esi
jns 0x409aed
push str.Failed_to_set_directory_search_path_variable.
jmp 0x409a96
mov esi, 0x80070003
cmp esi, 0x80070002
je 0x409b16
cmp esi, 0x80070003
je 0x409b16
test esi, esi
jns 0x409b2d
push dword [ebp - 4]
push dword [edi]
push str.Failed_while_searching_directory_search:__ls__for_path:__ls
push esi
call fcn.0044012f
add esp, 0x10
jmp 0x409b2d
push esi
push dword [ebp - 4]
push dword [edi]
push str.Directory_search:__ls__did_not_find_path:__ls__reason:_0x_x
push 2
call fcn.0044061a
add esp, 0x14
xor esi, esi
push dword [ebp - 4]
call fcn.00402793
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret 8
Function at 0x409b3f
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push esi
push edi
mov edi, dword [ebp + 8]
push 0
push eax
push dword [edi + 0x14]
push dword [ebp + 0xc]
call fcn.004071cf
mov esi, eax
test esi, esi
jns 0x409b6f
push str.Failed_to_format_variable_string.
jmp 0x409c0c
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x409c26
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x409bd0
cmp eax, 3
je 0x409bd0
test eax, eax
je 0x409be4
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push 0x28b
push str.search.cpp
call fcn.004037d3
push dword [edi + 0x14]
push str.Failed_get_to_file_attributes.__ls
push esi
call fcn.0044012f
add esp, 0xc
jmp 0x409c14
push dword [ebp - 4]
push dword [edi]
push str.File_search:__ls__did_not_find_path:__ls
push 2
call fcn.0044061a
add esp, 0x10
xorps xmm0, xmm0
movlpd qword [ebp - 0xc], xmm0
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 8]
push 0
push eax
push ecx
push dword [edi + 4]
push dword [ebp + 0xc]
call fcn.00408152
mov esi, eax
test esi, esi
jns 0x409c14
push str.Failed_to_set_variable.
push esi
call fcn.0044012f
pop ecx
pop ecx
push dword [ebp - 4]
call fcn.00402793
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret 8
xorps xmm0, xmm0
movlpd qword [ebp - 0xc], xmm0
test al, 0x10
jne 0x409bec
xor ecx, ecx
inc ecx
xor eax, eax
jmp 0x409bf2

Function at 0x409c39
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push esi
push edi
mov edi, dword [ebp + 8]
push 0
push eax
push dword [edi + 0x14]
push dword [ebp + 0xc]
call fcn.004071cf
mov esi, eax
test esi, esi
jns 0x409c6f
push str.Failed_to_format_variable_string.
push esi
call fcn.0044012f
pop ecx
pop ecx
jmp 0x409cf1
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x409cba
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
cmp esi, 0x80070002
je 0x409cdb
cmp esi, 0x80070003
je 0x409cdb
test esi, esi
jns 0x409cf1
push dword [ebp - 4]
push dword [edi]
push str.Failed_while_searching_file_search:__ls__for_path:__ls
push esi
call fcn.0044012f
add esp, 0x10
jmp 0x409cf1
test al, 0x10
jne 0x409cdb
push 0
push dword [ebp - 4]
push dword [edi + 4]
push dword [ebp + 0xc]
call fcn.004080f6
mov esi, eax
test esi, esi
jns 0x409c91
push str.Failed_to_set_variable_to_file_search_path.
jmp 0x409c62
push dword [ebp - 4]
push dword [edi]
push str.File_search:__ls__did_not_find_path:__ls
push 2
call fcn.0044061a
add esp, 0x10
xor esi, esi
push dword [ebp - 4]
call fcn.00402793
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret 8
Function at 0x40a17d
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
mov ebx, dword [ebp + 8]
xor ecx, ecx
push esi
push edi
push ecx
mov eax, dword [ebx + 0x24]
mov dword [ebp + 8], eax
lea eax, [ebp - 4]
push eax
push dword [ebx + 0x1c]
mov dword [ebp - 4], ecx
push dword [ebp + 0xc]
mov dword [ebp - 8], ecx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x10], ecx
call fcn.004071cf
mov esi, eax
test esi, esi
jns 0x40a1c5
push str.Failed_to_format_key_string.
push esi
call fcn.0044012f
pop ecx
pop ecx
jmp 0x40a2d0
xor edi, edi
lea eax, [ebp - 0xc]
push eax
inc edi
mov eax, 0x101
cmp dword [ebp + 8], 0
cmove eax, edi
push eax
push dword [ebp - 4]
push dword [ebx + 0x18]
call fcn.00440e3f
mov esi, eax
test esi, esi
js 0x40a286
cmp dword [ebx + 0x20], 0
je 0x40a2a2
push 0
lea eax, [ebp - 8]
push eax
push dword [ebx + 0x20]
push dword [ebp + 0xc]
call fcn.004071cf
mov esi, eax
test esi, esi
jns 0x40a216
push str.Failed_to_format_value_string.
jmp 0x40a1b8
push 0
push 0
lea eax, [ebp - 0x10]
push eax
push 0
push dword [ebp - 8]
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov ecx, eax
sub ecx, 0
je 0x40a2a2
dec ecx
sub ecx, 1
je 0x40a26f
test eax, eax
je 0x40a2a2
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push 0x322
push str.search.cpp
call fcn.004037d3
push str.Failed_to_query_registry_key_value.
jmp 0x40a1b8
push dword [ebp - 8]
push dword [ebp - 4]
push str.Registry_value_not_found._Key___ls__Value___ls
push 2
call fcn.0044061a
add esp, 0x10
jmp 0x40a2a0
push dword [ebp - 4]
cmp esi, 0x80070002
jne 0x40a2c2
push str.Registry_key_not_found._Key___ls
push 2
call fcn.0044061a
add esp, 0xc
xor edi, edi
push 0
push 0
push edi
push dword [ebx + 4]
push dword [ebp + 0xc]
call fcn.00408152
mov esi, eax
test esi, esi
jns 0x40a2e7
push str.Failed_to_set_variable.
jmp 0x40a1b8
push str.Failed_to_open_registry_key._Key___ls
push esi
call fcn.0044012f
add esp, 0xc
test esi, esi
jns 0x40a2e7
push esi
push dword [ebp - 4]
push str.RegistrySearchExists_failed:_ID__ls__HRESULT_0x_x
push 2
call fcn.0044061a
add esp, 0x10
push dword [ebp - 4]
call fcn.00402793
push dword [ebp - 8]
call fcn.00402793
cmp dword [ebp - 0xc], 0
je 0x40a306
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8