joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4272dc
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
cmp dword [0x464f50], 0xffffffff
push esi
jne 0x427485
push edi
push 0x44
pop ecx
xor eax, eax
lea edi, [ebp - 0x110]
mov dword [ebp - 0x114], 0x114
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x114]
mov dword [0x464f50], 0xfffffc18
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
pop edi
je 0x427485
push 2
pop ecx
cmp dword [ebp - 0x104], ecx
jne 0x427485
mov eax, dword [ebp - 0x110]
cmp eax, 5
jne 0x4273f5
cmp dword [ebp - 0x10c], 0
jne 0x427361
mov dword [0x464f50], 1
jmp 0x427485
cmp dword [ebp - 0x10c], 1
jne 0x4273da
mov esi, dword [sym.imp.MSVCRT.dll__wcsnicmp]
lea eax, [ebp - 0x100]
push 0x7f
push eax
push str.Service_Pack_1
call esi
add esp, 0xc
test eax, eax
jne 0x427396
mov dword [0x464f50], 3
jmp 0x427485
lea eax, [ebp - 0x100]
push 0x7f
push eax
push str.Service_Pack_2
call esi
add esp, 0xc
test eax, eax
jne 0x4273bc
mov dword [0x464f50], 4
jmp 0x427485
lea eax, [ebp - 0x100]
push 0x7f
push eax
push str.Service_Pack_3
call esi
add esp, 0xc
neg eax
sbb eax, eax
and al, 0xfd
add eax, 5
jmp 0x427447
cmp dword [ebp - 0x10c], ecx
jne 0x427485
mov dword [0x464f50], 6
jmp 0x427485
cmp eax, 6
jne 0x42746f
mov eax, dword [ebp - 0x10c]
test eax, eax
jne 0x42744e
mov esi, dword [sym.imp.MSVCRT.dll__wcsnicmp]
lea eax, [ebp - 0x100]
push 0x7f
push eax
push str.Service_Pack_1
call esi
add esp, 0xc
test eax, eax
jne 0x42742d
mov dword [0x464f50], 8
jmp 0x427485
lea eax, [ebp - 0x100]
push 0x7f
push eax
push str.Service_Pack_2
call esi
add esp, 0xc
neg eax
sbb eax, eax
add eax, 8
mov dword [0x464f50], eax
jmp 0x427485
cmp eax, 1
jne 0x42745f
mov dword [0x464f50], 9
jmp 0x427485
cmp eax, ecx
jne 0x427479
mov dword [0x464f50], 0xa
jmp 0x427485
cmp eax, 7
je 0x427453
cmp eax, 8
jmp 0x427461
jbe 0x427485
mov dword [0x464f50], 0x3e8
mov eax, dword [0x464f50]
pop esi
leave
ret
Function at 0x4275b5
Capabilities:
Enumerate process modules
Terminate process

Disassembly:
mov eax, 0x432b88
call fcn.004323e0
mov eax, 0x122c
call fcn.00432320
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
jne 0x4275d8
xor eax, eax
jmp 0x427735
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x1238]
push 0x1000
push eax
call sub.PSAPI.DLL_EnumProcesses
test eax, eax
jne 0x4275f9
or eax, 0xffffffff
jmp 0x427735
mov eax, dword [ebp - 0x2c]
mov cl, byte [ebp + 0xb]
push esi
push edi
shr eax, 2
mov byte [ebp - 0x28], cl
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x14], ebx
je 0x427725
lea esi, [ebp - 0x1238]
mov dword [ebp - 0x18], eax
push dword [esi]
push ebx
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
cmp eax, ebx
mov dword [ebp - 0x10], eax
je 0x4276b8
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [ebp - 0x14]
push 4
push ecx
push eax
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x4276af
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x236]
mov word [ebp - 0x238], bx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x238]
push 0x104
push eax
push dword [ebp - 0x14]
push dword [ebp - 0x10]
call sub.PSAPI.DLL_GetModuleBaseNameW
test eax, eax
je 0x4276af
push dword [ebp + 8]
lea eax, [ebp - 0x238]
push eax
call dword [sym.imp.MSVCRT.dll__wcsicmp]
pop ecx
test eax, eax
pop ecx
jne 0x4276af
push ebx
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
lea eax, [ebp - 0x10]
lea ecx, [ebp - 0x28]
push eax
call fcn.00428095
jmp 0x4276b8
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
add esi, 4
dec dword [ebp - 0x18]
jne 0x427625
cmp dword [ebp - 0x24], ebx
je 0x427725
mov esi, dword [ebp - 0x20]
sub esi, dword [ebp - 0x24]
sar esi, 2
je 0x427725
mov eax, esi
shl eax, 2
push eax
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov edi, eax
pop ecx
cmp edi, ebx
je 0x42770e
xor eax, eax
cmp esi, ebx
jbe 0x4276fa
mov ecx, dword [ebp - 0x24]
mov ecx, dword [ecx + eax*4]
mov dword [edi + eax*4], ecx
inc eax
cmp eax, esi
jb 0x4276ec
push dword [ebp + 0xc]
push 1
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
push edi
call fcn.00432272
pop ecx
xor edi, edi
cmp esi, ebx
jbe 0x427725
mov eax, dword [ebp - 0x24]
push dword [eax + edi*4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc edi
cmp edi, esi
jb 0x427714
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.00428075
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 0xc]
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x427742
Capabilities:
Check if file exists
Enumerate process modules
Terminate process

Disassembly:
mov eax, 0x432b9c
call fcn.004323e0
mov eax, 0x122c
call fcn.00432320
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
je 0x4278c6
push dword [ebp + 8]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4278c6
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x1238]
push 0x1000
push eax
call sub.PSAPI.DLL_EnumProcesses
test eax, eax
jne 0x427794
or eax, 0xffffffff
jmp 0x4278c8
mov edx, dword [ebp - 0x28]
mov al, byte [ebp + 0xb]
push esi
push edi
shr edx, 2
mov byte [ebp - 0x24], al
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], ebx
push 0
mov ecx, 0x82
pop eax
lea edi, [ebp - 0x236]
mov word [ebp - 0x238], bx
mov dword [ebp - 4], ebx
rep stosd dword es:[edi], eax
mov dword [ebp - 0x14], ebx
je 0x4278b4
lea esi, [ebp - 0x1238]
mov edi, edx
push dword [esi]
push ebx
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
cmp eax, ebx
mov dword [ebp - 0x10], eax
je 0x42784d
lea ecx, [ebp - 0x2c]
push ecx
lea ecx, [ebp - 0x14]
push 4
push ecx
push eax
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x427844
lea eax, [ebp - 0x238]
push 0x104
push eax
push dword [ebp - 0x14]
push dword [ebp - 0x10]
call sub.PSAPI.DLL_GetModuleFileNameExW
push dword [ebp + 8]
lea eax, [ebp - 0x238]
push eax
call dword [sym.imp.MSVCRT.dll__wcsicmp]
pop ecx
test eax, eax
pop ecx
jne 0x427844
push ebx
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
lea eax, [ebp - 0x10]
lea ecx, [ebp - 0x24]
push eax
call fcn.00428095
jmp 0x42784d
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
add esi, 4
dec edi
jne 0x4277d6
cmp dword [ebp - 0x20], ebx
je 0x4278b4
mov esi, dword [ebp - 0x1c]
sub esi, dword [ebp - 0x20]
sar esi, 2
je 0x4278b4
mov eax, esi
shl eax, 2
push eax
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov edi, eax
pop ecx
cmp edi, ebx
je 0x42789d
xor eax, eax
cmp esi, ebx
jbe 0x427889
mov ecx, dword [ebp - 0x20]
mov ecx, dword [ecx + eax*4]
mov dword [edi + eax*4], ecx
inc eax
cmp eax, esi
jb 0x42787b
push dword [ebp + 0xc]
push 1
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
push edi
call fcn.00432272
pop ecx
xor edi, edi
cmp esi, ebx
jbe 0x4278b4
mov eax, dword [ebp - 0x20]
push dword [eax + edi*4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc edi
cmp edi, esi
jb 0x4278a3
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x24]
call fcn.00428075
pop edi
xor eax, eax
pop esi
jmp 0x4278c8
xor eax, eax
mov ecx, dword [ebp - 0xc]
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x427e99
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push esi
push edi
push 0x10
xor eax, eax
pop ecx
lea edi, [ebp - 0x50]
rep stosd dword es:[edi], eax
xor esi, esi
lea edi, [ebp - 0xc]
mov dword [ebp - 0x10], esi
mov dword [ebp - 0x54], 0x44
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov ax, word [ebp + 0xc]
mov dword [ebp - 0x28], 0x81
mov word [ebp - 0x24], ax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x54]
push eax
push esi
push esi
push esi
push 1
push esi
push esi
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x427f28
cmp dword [ebp + 0x10], esi
jbe 0x427efa
push dword [ebp + 0x10]
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edi, dword [ebp + 0x14]
cmp edi, esi
je 0x427f15
push edi
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
jne 0x427f15
mov dword [edi], 1
push dword [ebp - 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0xc]
call esi
push 1
pop esi
mov eax, esi
pop edi
pop esi
leave
ret

Function at 0x427f2e
Capabilities:
Delete registry key
Set registry value

Disassembly:
push esi
push edi
push 2
mov edi, str.CLSID1A893393_71A8_4a50_95A1_2B89DE87B24C
push dword [0x464f54]
mov esi, SysReAllocString
push 4
push 0x466094
push edi
push esi
call dword [sym.imp.SHLWAPI.dll_SHSetValueW]
test eax, eax
jne 0x427f61
push edi
push esi
call dword [sym.imp.SHLWAPI.dll_SHDeleteKeyW]
mov al, 1
jmp 0x427f63
xor al, al
pop edi
pop esi
ret
Function at 0x427f66
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1220
call fcn.00432320
push esi
xor esi, esi
cmp dword [ebp + 0xc], esi
mov dword [ebp - 8], esi
je 0x428070
cmp dword [ebp + 8], esi
je 0x428070
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x1220]
push 0x1000
push eax
call sub.PSAPI.DLL_EnumProcesses
test eax, eax
je 0x428070
push ebx
push edi
mov edi, dword [ebp - 0x14]
mov dword [ebp - 0x10], esi
shr edi, 2
mov dword [ebp - 0xc], edi
mov dword [ebp - 4], esi
je 0x428069
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x1220]
mov dword [ebp + 8], eax
jmp 0x427fd2
xor esi, esi
mov eax, dword [ebp + 8]
push dword [eax]
push esi
push 0x411
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
je 0x428050
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x10]
push 4
push eax
push esi
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x42804d
and word [ebp - 0x220], 0
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x21e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x220]
push 0x104
push eax
push dword [ebp - 0x10]
push esi
call sub.PSAPI.DLL_GetModuleBaseNameW
test eax, eax
je 0x428045
push dword [ebp + 0xc]
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.MSVCRT.dll__wcsicmp]
pop ecx
test eax, eax
pop ecx
je 0x428062
push esi
call ebx
mov edi, dword [ebp - 0xc]
jmp 0x428050
push esi
call ebx
inc dword [ebp - 4]
add dword [ebp + 8], 4
cmp dword [ebp - 4], edi
jb 0x427fd0
jmp 0x428069
mov dword [ebp - 8], 1
mov eax, dword [ebp - 8]
pop edi
pop ebx
jmp 0x428072
xor eax, eax
pop esi
leave
ret
Function at 0x42929a
Capabilities:
Get file attributes
Set file attributes

Disassembly:
mov eax, 0x432c78
call fcn.004323e0
sub esp, 0x260
mov eax, dword [0x464f58]
push esi
push edi
mov dword [ebp - 0x10], eax
and dword [ebp - 4], 0
mov dword [ebp - 0x14], eax
cmp dword [ebp + 8], 0
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenW]
mov byte [ebp - 4], 1
jne 0x4292cf
xor eax, eax
jmp 0x4292d4
push dword [ebp + 8]
call edi
push dword [ebp + 8]
lea ecx, [ebp - 0x14]
push eax
call fcn.00428fd5
mov esi, str..
mov eax, esi
test eax, eax
je 0x4292ee
push esi
call edi
push esi
push eax
lea ecx, [ebp - 0x14]
call fcn.0042900c
lea eax, [ebp - 0x26c]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
mov dword [ebp - 0x18], eax
jne 0x429317
xor esi, esi
jmp 0x429459
mov esi, dword [sym.imp.MSVCRT.dll_wcscmp]
push ebx
mov ebx, dword [sym.imp.MSVCRT.dll__wcsicmp]
lea eax, [ebp - 0x240]
push 0x464d84
push eax
call esi
pop ecx
test eax, eax
pop ecx
je 0x429434
lea eax, [ebp - 0x240]
push 0x43e668
push eax
call esi
pop ecx
test eax, eax
pop ecx
je 0x429434
cmp dword [ebp + 0xc], 0
jne 0x429372
lea eax, [ebp - 0x240]
push str.desktop.ini
push eax
call ebx
pop ecx
test eax, eax
pop ecx
je 0x429434
xor eax, eax
cmp dword [ebp + 8], eax
je 0x42937e
push dword [ebp + 8]
call edi
push dword [ebp + 8]
lea ecx, [ebp - 0x10]
push eax
call fcn.00428fd5
lea eax, [ebp - 0x1c]
lea ecx, [ebp - 0x10]
push eax
push 1
mov dword [ebp - 0x1c], 0x5c
call fcn.0042900c
lea eax, [ebp - 0x240]
test eax, eax
je 0x4293b2
lea eax, [ebp - 0x240]
push eax
call edi
lea ecx, [ebp - 0x240]
push ecx
push eax
lea ecx, [ebp - 0x10]
call fcn.0042900c
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 1
je 0x4293db
and al, 0xfe
push eax
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test byte [ebp - 0x26c], 0x10
je 0x429400
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp - 0x10]
call fcn.0042929a
add esp, 0xc
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x429434
cmp dword [ebp + 0x10], 0
je 0x42942b
lea eax, [ebp - 0x240]
push str.index.dat
push eax
call ebx
pop ecx
test eax, eax
pop ecx
jne 0x42942b
lea eax, [ebp - 0x240]
push eax
push dword [ebp + 8]
call fcn.00429481
pop ecx
pop ecx
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea eax, [ebp - 0x26c]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x429324
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_FindClose]
push 1
pop esi
pop ebx
and byte [ebp - 4], 0
lea ecx, [ebp - 0x14]
call fcn.00428307
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x10]
call fcn.00428307
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop edi
pop esi
mov dword fs:[0], ecx
leave
ret
Function at 0x429481
Capabilities:
Get file size
Write file on windows

Disassembly:
mov eax, 0x432c8c
call fcn.004323e0
mov eax, 0x271c
call fcn.00432320
mov eax, dword [0x464f58]
push ebx
push esi
push edi
mov dword [ebp - 0x10], eax
mov edi, 0x2710
xor ebx, ebx
push edi
lea eax, [ebp - 0x2728]
push ebx
push eax
mov dword [ebp - 4], ebx
call sub.MSVCRT.dll_memset
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
add esp, 0xc
cmp dword [ebp + 8], ebx
jne 0x4294ca
xor eax, eax
jmp 0x4294cf
push dword [ebp + 8]
call esi
push dword [ebp + 8]
lea ecx, [ebp - 0x10]
push eax
call fcn.00428fd5
lea eax, [ebp - 0x14]
lea ecx, [ebp - 0x10]
push eax
push 1
mov dword [ebp - 0x14], 0x5c
call fcn.0042900c
cmp dword [ebp + 0xc], ebx
jne 0x4294f9
xor eax, eax
jmp 0x4294fe
push dword [ebp + 0xc]
call esi
push dword [ebp + 0xc]
lea ecx, [ebp - 0x10]
push eax
call fcn.0042900c
push ebx
push 0x80
push 3
push ebx
push 3
push 0x40000000
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp + 8], eax
je 0x429585
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push ebx
push ebx
push 0x40
mov esi, eax
push dword [ebp + 8]
sub esi, 0x40
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp esi, ebx
jbe 0x429579
mov ebx, dword [sym.imp.KERNEL32.dll_WriteFile]
lea eax, [ebp - 0x18]
cmp esi, edi
push 0
push eax
jbe 0x42956c
lea eax, [ebp - 0x2728]
push edi
push eax
push dword [ebp + 8]
call ebx
sub esi, edi
jne 0x42954f
jmp 0x429579
lea eax, [ebp - 0x2728]
push esi
push eax
push dword [ebp + 8]
call ebx
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 1
pop ebx
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x10]
call fcn.00428307
mov ecx, dword [ebp - 0xc]
pop edi
mov eax, ebx
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x4296d6
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x4008
call fcn.00432320
and word [ebp - 0x4008], 0
push edi
mov ecx, 0xfff
xor eax, eax
lea edi, [ebp - 0x4006]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 8]
push eax
push dword [ebp + 8]
call sub.VERSION.dll_GetFileVersionInfoSizeW
test eax, eax
je 0x429785
cmp eax, 0x3fff
ja 0x429785
lea ecx, [ebp - 0x4008]
push ecx
push eax
push 0
push dword [ebp + 8]
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x429785
lea eax, [ebp - 4]
push eax
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 0x4008]
push 0x43e5b4
push eax
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x429785
mov eax, dword [ebp + 8]
push esi
mov esi, dword [ebp + 0x10]
mov edi, dword [ebp + 0xc]
movzx ecx, word [eax + 0xc]
push ecx
mov ecx, dword [eax + 0xc]
shr ecx, 0x10
push ecx
movzx ecx, word [eax + 8]
mov eax, dword [eax + 8]
push ecx
shr eax, 0x10
push eax
push str._d._d._d._d
push esi
push edi
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x1c
and word [edi + esi*2 - 2], 0
push 1
pop eax
pop esi
jmp 0x429787
xor eax, eax
pop edi
leave
ret
Function at 0x42991b
Capabilities:
Create directory

Disassembly:
push esi
push 0
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov esi, eax
test esi, esi
jne 0x429940
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x429940
push 1
pop eax
pop esi
ret
mov eax, esi
pop esi
ret

Function at 0x429f1b
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x418
and word [ebp - 0x210], 0
push ebx
push esi
push edi
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x20e]
push dword [ebp + 8]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov eax, dword [ebp + 0x10]
push str.CLSID_sInprocServer32
push 0x103
mov dword [ebp - 8], 1
lea edi, [eax + eax]
lea eax, [ebp - 0x210]
push eax
mov dword [ebp - 4], edi
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x10
lea eax, [ebp - 4]
mov esi, dword [sym.imp.SHLWAPI.dll_SHGetValueW]
mov ebx, SysReAllocString
push eax
lea eax, [ebp - 8]
push dword [ebp + 0xc]
push eax
lea eax, [ebp - 0x210]
push str.CodeBase
push eax
push ebx
call esi
test eax, eax
je 0x429fec
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
push dword [ebp + 0xc]
push eax
lea eax, [ebp - 0x210]
push 0
push eax
push ebx
call esi
test eax, eax
je 0x429fec
push dword [ebp + 8]
lea eax, [ebp - 0x210]
push str.CLSID_sLocalServer32
push 0x103
push eax
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x10
lea eax, [ebp - 4]
mov dword [ebp - 4], edi
push eax
lea eax, [ebp - 8]
push dword [ebp + 0xc]
push eax
lea eax, [ebp - 0x210]
push 0
push eax
push ebx
call esi
test eax, eax
jne 0x429ff1
push 1
pop eax
jmp 0x42a06d
and word [ebp - 0x418], 0
push dword [ebp + 8]
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x416]
push str.CLSID_sTreatAs
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x210]
push 0x103
push eax
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x10
lea eax, [ebp - 4]
mov dword [ebp - 4], 0x208
push eax
lea eax, [ebp - 0x418]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x210]
push 0
push eax
push ebx
call esi
test eax, eax
jne 0x42a064
push dword [ebp + 0x10]
lea eax, [ebp - 0x418]
push dword [ebp + 0xc]
push eax
call fcn.00429f1b
add esp, 0xc
jmp 0x42a06d
mov eax, dword [ebp + 0xc]
and word [eax], 0
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x42a851
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
push esi
xor esi, esi
push edi
movzx edi, word [ebp + 0xc]
lea eax, [ebp - 0x1c]
push esi
push eax
lea eax, [ebp - 8]
push eax
mov dword [ebp - 0xc], esi
mov dword [ebp - 4], esi
mov dword [ebp - 8], esi
mov dword [ebp - 0x1c], 1
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x14], esi
mov dword [ebp - 0x10], esi
call fcn.00431db0
push dword [ebp + 0x10]
push edi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov edi, eax
cmp edi, esi
je 0x42a938
push edi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
cmp ebx, esi
je 0x42a938
push edi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
cmp edi, esi
je 0x42a938
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
cmp eax, esi
mov dword [ebp - 4], eax
je 0x42a938
push ebx
push edi
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
lea eax, [ebp + 0xc]
mov dword [ebp + 0xc], esi
push eax
push esi
push dword [ebp - 4]
call dword [sym.imp.ole32.dll_CreateStreamOnHGlobal]
test eax, eax
jne 0x42a938
push esi
push dword [ebp + 0xc]
call fcn.0042aa71
pop ecx
mov edi, eax
mov eax, dword [ebp + 0xc]
pop ecx
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
cmp edi, esi
je 0x42a938
mov eax, dword [edi + 8]
mov dword [edi + 8], esi
cmp eax, esi
jne 0x42a930
lea eax, [ebp - 0xc]
push esi
push eax
push dword [edi + 4]
call fcn.00431dd4
cmp eax, esi
je 0x42a930
mov dword [edi + 8], eax
mov eax, dword [edi]
push 1
mov ecx, edi
call dword [eax]
push dword [ebp - 8]
call fcn.00431dc2
cmp dword [ebp - 4], esi
pop edi
pop esi
pop ebx
je 0x42a951
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [ebp - 0xc]
leave
ret
Function at 0x42b23c
Capabilities:
Get storage device properties

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2d10
call fcn.00432320
push esi
xor esi, esi
cmp dword [ebp + 8], esi
je 0x42b35d
cmp dword [ebp + 0xc], esi
je 0x42b35d
push ebx
push edi
mov dword [ebp - 8], esi
mov dword [ebp - 4], esi
mov edi, 0x2710
push dword [ebp - 4]
lea eax, [ebp - 0x600]
push str..PhysicalDrive_d
push 0x200
push eax
call fcn.0042b007
add esp, 0x10
lea eax, [ebp - 0x600]
push esi
push esi
push 3
push esi
push 3
push esi
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x42b349
push 0xc
lea eax, [ebp - 0x18]
push esi
push eax
mov dword [ebp - 0xc], esi
call sub.MSVCRT.dll_memset
push edi
lea eax, [ebp - 0x2d10]
push esi
push eax
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x14], esi
call sub.MSVCRT.dll_memset
add esp, 0x18
lea eax, [ebp - 0xc]
push esi
push eax
lea eax, [ebp - 0x2d10]
push edi
push eax
lea eax, [ebp - 0x18]
push 0xc
push eax
push 0x2d1400
push ebx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x42b33d
push 0x3e8
lea eax, [ebp - 0x400]
push esi
push eax
call sub.MSVCRT.dll_memset
lea eax, [ebp - 0x400]
push eax
push 1
push dword [ebp - 0x2cf8]
lea eax, [ebp - 0x2d10]
push eax
call fcn.004067fc
add esp, 0x1c
lea eax, [ebp - 0x400]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.0042afd2
test eax, eax
jne 0x42b33d
mov dword [ebp - 8], 1
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 8], esi
jne 0x42b356
inc dword [ebp - 4]
cmp dword [ebp - 4], 0x10
jl 0x42b26b
mov eax, dword [ebp - 8]
pop edi
pop ebx
jmp 0x42b35f
xor eax, eax
pop esi
leave
ret
Function at 0x42b903
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4f0
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
je 0x42ba5b
cmp dword [ebp + 0xc], ebx
je 0x42ba5b
push esi
push 0x64
lea eax, [ebp - 0x7c]
push ebx
push eax
call sub.MSVCRT.dll_memset
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
add esp, 0xc
lea eax, [ebp - 4]
push eax
push 8
push ebx
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionNetworkCards
push reloc.OLEAUT32.dll_SysReAllocString
call esi
test eax, eax
jne 0x42ba3b
mov dword [ebp - 8], ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x14]
push ebx
push eax
lea eax, [ebp - 0x2e8]
mov dword [ebp - 0x14], 0x104
push eax
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
jne 0x42ba32
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 0x2e8]
push ebx
push eax
push dword [ebp - 4]
call esi
test eax, eax
jne 0x42ba2a
lea eax, [ebp - 0x10]
mov dword [ebp - 0x18], 1
push eax
lea eax, [ebp - 0x4f0]
push eax
lea eax, [ebp - 0x18]
push eax
push ebx
push str.ServiceName
mov dword [ebp - 0x10], 0x208
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x42ba21
push 0x64
lea eax, [ebp - 0xe0]
push ebx
push eax
call sub.MSVCRT.dll_memset
lea eax, [ebp - 0xe0]
push 0x64
push eax
lea eax, [ebp - 0x4f0]
push eax
call fcn.0042ba60
add esp, 0x18
test eax, eax
je 0x42ba21
cmp byte [ebp - 0x7c], bl
je 0x42ba0f
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp - 0xe0]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
jge 0x42ba21
lea eax, [ebp - 0xe0]
push eax
lea eax, [ebp - 0x7c]
push 0x64
push eax
call fcn.0042afd2
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
inc dword [ebp - 8]
jmp 0x42b955
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp byte [ebp - 0x7c], bl
pop esi
je 0x42ba5b
lea eax, [ebp - 0x7c]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.0042afd2
xor ecx, ecx
test eax, eax
setge cl
mov eax, ecx
jmp 0x42ba5d
xor eax, eax
pop ebx
leave
ret