joyce8/EMBER2024-capa huggingface dataset:
Function at 0x5a35cc
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe84
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x178], ecx
mov dword [ebp - 0x17c], ecx
mov dword [ebp - 0x174], ecx
mov dword [ebp - 0x16c], ecx
mov dword [ebp - 0x170], ecx
mov dword [ebp - 0x168], ecx
mov dword [ebp - 0x164], ecx
mov dword [ebp - 0x160], ecx
mov dword [ebp - 0x15c], ecx
mov edi, edx
mov esi, eax
lea eax, [ebp - 0x158]
mov edx, dword [0x407ca0]
call fcn.00404e2c
xor eax, eax
push ebp
push 0x5a3859
push dword fs:[eax]
mov dword fs:[eax], esp
xor ebx, ebx
lea eax, [ebp - 0x15c]
mov ecx, 0x5a3874
mov edx, esi
call fcn.00404740
mov eax, dword [ebp - 0x15c]
lea ecx, [ebp - 0x158]
mov edx, 0x3f
call fcn.00409634
test eax, eax
jne 0x5a3828
mov eax, dword [ebp - 0x14c]
mov edx, 0x5a3884
call fcn.00404840
je 0x5a380a
mov eax, dword [ebp - 0x14c]
mov edx, 0x5a3890
call fcn.00404840
je 0x5a380a
test byte [ebp - 0x150], 0x10
je 0x5a3784
push esi
push 0x5a389c
push dword [ebp - 0x14c]
lea eax, [ebp - 0x160]
mov edx, 3
call fcn.004047b4
mov eax, dword [ebp - 0x160]
call fcn.00409440
test al, al
je 0x5a3784
push edi
push 0x5a389c
push dword [ebp - 0x14c]
lea eax, [ebp - 0x164]
mov edx, 3
call fcn.004047b4
mov eax, dword [ebp - 0x164]
call fcn.00409440
test al, al
jne 0x5a3727
push edi
push 0x5a389c
push dword [ebp - 0x14c]
lea eax, [ebp - 0x168]
mov edx, 3
call fcn.004047b4
mov eax, dword [ebp - 0x168]
call fcn.00409acc
test al, al
je 0x5a382a
mov eax, dword [ebp + 8]
push eax
push edi
push 0x5a389c
push dword [ebp - 0x14c]
lea eax, [ebp - 0x16c]
mov edx, 3
call fcn.004047b4
mov eax, dword [ebp - 0x16c]
push eax
push esi
push 0x5a389c
push dword [ebp - 0x14c]
lea eax, [ebp - 0x170]
mov edx, 3
call fcn.004047b4
mov eax, dword [ebp - 0x170]
pop edx
call fcn.005a35cc
pop ecx
test al, al
je 0x5a382a
jmp 0x5a380a
push esi
push 0x5a389c
push dword [ebp - 0x14c]
lea eax, [ebp - 0x174]
mov edx, 3
call fcn.004047b4
mov eax, dword [ebp - 0x174]
call fcn.00409430
test al, al
je 0x5a380a
push 0
push edi
push 0x5a389c
push dword [ebp - 0x14c]
lea eax, [ebp - 0x178]
mov edx, 3
call fcn.004047b4
mov eax, dword [ebp - 0x178]
call fcn.004048f4
push eax
push esi
push 0x5a389c
push dword [ebp - 0x14c]
lea eax, [ebp - 0x17c]
mov edx, 3
call fcn.004047b4
mov eax, dword [ebp - 0x17c]
call fcn.004048f4
push eax
call sub.kernel32.dll_CopyFileA
test eax, eax
je 0x5a382a
lea eax, [ebp - 0x158]
call fcn.00409684
test eax, eax
je 0x5a3665
lea eax, [ebp - 0x158]
call fcn.004096a8
mov bl, 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x5a3860
lea eax, [ebp - 0x17c]
mov edx, 9
call fcn.00404458
lea eax, [ebp - 0x158]
mov edx, dword [0x407ca0]
call fcn.00404efc
ret
Function at 0x10001909
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x118
push ebx
push esi
push edi
push str.SOFTWAREMicrosoftInternet_Explorer
lea ecx, [ebp - 0xc]
call fcn.10001cfd
push 0x3f
xor ebx, ebx
pop ecx
xor eax, eax
lea edi, [ebp - 0x117]
mov byte [ebp - 0x118], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 8]
mov dword [ebp - 8], ebx
push eax
push 0x20019
push ebx
mov dword [ebp - 0x18], 1
push dword [ebp - 0xc]
mov dword [ebp - 0x10], 0x100
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x1000196f
or esi, 0xffffffff
jmp 0x100019f2
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x118]
push eax
lea eax, [ebp - 0x18]
push eax
push ebx
push str.Version
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x10001967
mov eax, dword [0x1001f030]
lea ecx, [ebp - 4]
mov dword [ebp - 4], eax
lea eax, [ebp - 0x118]
push eax
call fcn.10001e2a
push ebx
push 0x2e
lea ecx, [ebp - 4]
call fcn.10002131
cmp eax, 0xffffffff
je 0x100019d6
push eax
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebp - 4]
call fcn.10002285
push eax
lea ecx, [ebp - 4]
call fcn.10001d92
lea ecx, [ebp - 0x14]
call fcn.10001cd1
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push dword [ebp - 4]
call fcn.10016789
pop ecx
mov esi, eax
lea ecx, [ebp - 4]
call fcn.10001cd1
lea ecx, [ebp - 0xc]
call fcn.10001cd1
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret

Function at 0x10001b48
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
push str.SoftwareActiveUpdate4
lea ecx, [ebp - 8]
call fcn.10001cfd
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push eax
mov esi, SysReAllocStringLen
push dword [ebp - 8]
push esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
je 0x10001b88
lea eax, [ebp - 4]
push eax
push dword [ebp - 8]
push esi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
jne 0x10001bad
cmp dword [ebp - 4], 0
je 0x10001bad
lea eax, [ebp + 0xc]
push 4
push eax
push 4
push 0
push dword [ebp + 8]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 8]
call fcn.10001cd1
lea ecx, [ebp + 8]
call fcn.10001cd1
pop esi
leave
ret
Function at 0x10001bc0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push esi
or esi, 0xffffffff
push str.SoftwareActiveUpdate4
lea ecx, [ebp - 0xc]
mov dword [ebp - 8], esi
call fcn.10001cfd
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push eax
push dword [ebp - 0xc]
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
jne 0x10001c2c
cmp dword [ebp - 4], eax
je 0x10001c2c
push 4
pop eax
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x14]
push eax
push 0
push dword [ebp + 8]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x10001c23
mov esi, dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0xc]
call fcn.10001cd1
lea ecx, [ebp + 8]
call fcn.10001cd1
mov eax, esi
pop esi
leave
ret

Function at 0x10001c41
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x94
lea eax, [ebp - 0x94]
mov dword [ebp - 0x94], 0x94
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x10001c7c
cmp dword [ebp - 0x84], 2
jne 0x10001c7c
cmp dword [ebp - 0x90], 6
jb 0x10001c7c
push 1
pop eax
leave
ret
xor eax, eax
leave
ret
Function at 0x100029e9
Capabilities:
Get common file path
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
mov ecx, dword [ebp + 0xc]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
push esi
cmp dword [ecx - 0xc], 0
lea eax, [ecx - 0xc]
jl 0x10002a0e
push eax
mov dword [ebp - 4], ecx
call ebx
jmp 0x10002a1f
mov eax, dword [0x1001f030]
push ecx
lea ecx, [ebp - 4]
mov dword [ebp - 4], eax
call fcn.10001e2a
and byte [ebp - 0x114], 0
push edi
push 0x40
xor eax, eax
pop ecx
lea edi, [ebp - 0x113]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov esi, str._SYSTEM_
lea ecx, [ebp - 4]
push esi
stosb byte es:[edi], al
call fcn.10004b8b
cmp eax, 0xffffffff
je 0x10002a61
lea eax, [ebp - 0x114]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
jmp 0x10002aee
mov esi, str._PROGRAM_FILES_
lea ecx, [ebp - 4]
push esi
call fcn.10004b8b
cmp eax, 0xffffffff
je 0x10002ac9
lea eax, [ebp - 8]
xor edi, edi
push eax
push 0x20019
push edi
push str.SOFTWAREMicrosoftWindowsCurrentVersion
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [ebp - 8], edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x10002afe
lea eax, [ebp - 0xc]
mov dword [ebp - 0x10], 1
push eax
lea eax, [ebp - 0x114]
push eax
lea eax, [ebp - 0x10]
push eax
push edi
push str.ProgramFilesDir
mov dword [ebp - 0xc], 0x104
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x10002afe
jmp 0x10002aee
mov esi, 0x1001f1c8
lea ecx, [ebp - 4]
push esi
call fcn.10004b8b
cmp eax, 0xffffffff
je 0x10002afe
lea eax, [ebp - 0x114]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea eax, [ebp - 0x114]
lea ecx, [ebp - 4]
push eax
push esi
call fcn.1000267e
mov eax, dword [ebp - 4]
mov esi, dword [ebp + 8]
pop edi
cmp dword [eax - 0xc], 0
lea ecx, [eax - 0xc]
jl 0x10002b15
push ecx
mov dword [esi], eax
call ebx
jmp 0x10002b25
mov ecx, dword [0x1001f030]
push eax
mov dword [esi], ecx
mov ecx, esi
call fcn.10001e2a
lea ecx, [ebp - 4]
call fcn.10001cd1
lea ecx, [ebp + 0xc]
call fcn.10001cd1
mov eax, esi
pop esi
pop ebx
leave
ret 8
Function at 0x10004a9e
Capabilities:
Inspect section memory permissions

Disassembly:
cmp dword [eax + 4], ebx
jne 0x10004a24
cmp dword [eax + 0xc], ebx
je 0x10004ac7
mov edi, dword [eax + 0xc]
add edi, esi
push edi
call dword [ebp - 0xc0]
mov dword [ebp + 0xc], eax
call fcn.1000447f
pop ss
frstor dword [ecx + ebp*8 + 0x39]
pop ebp
or al, 0x75
adc dl, byte [edi - 1]
xchg ebp, eax
dec eax
invalid
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, ebx
je 0x10004ab5
test eax, 0x80000000
lea ecx, [eax + esi]
je 0x10004a90
and eax, 0xffff
push eax
jmp 0x10004a94
add ecx, 2
push ecx
push dword [ebp + 0xc]
push dword [ebp + 8]
jne 0x10004aa2
call fcn.10004444
add esp, 0xc
inc dword [ebx - 0x4c4f33c]
cmp edi, ebx
mov dword [edi], eax
je 0x10004c6e
add edi, 4
add dword [ebp + 0x10], 4
jmp 0x10004a75
add dword [ebp - 0x44], 0x14
mov edi, dword [ebp - 0x88]
mov eax, dword [ebp - 0x44]
jmp 0x10004a16
call fcn.1000447f
jecxz 0x10004a98
out dx, al
push esi
mov eax, dword [edi + 0xa0]
cmp eax, ebx
je 0x10004b33
add eax, esi
cmp dword [eax], ebx
je 0x10004b33
mov edx, dword [eax + 4]
lea ecx, [eax + 8]
add edx, eax
mov dword [ebp + 8], ecx
cmp ecx, edx
jae 0x10004b2e
mov ecx, dword [ebp + 8]
movzx ecx, word [ecx]
mov edx, ecx
and edx, 0xf000
cmp edx, 0x3000
jne 0x10004b18
and ecx, 0xfff
mov edx, esi
sub edx, dword [edi + 0x34]
add ecx, esi
add ecx, dword [eax]
add dword [ecx], edx
jmp 0x10004b20
cmp edx, ebx
jne 0x10004c6e
mov ecx, dword [eax + 4]
add dword [ebp + 8], 2
add ecx, eax
cmp dword [ebp + 8], ecx
jb 0x10004aef
add eax, dword [eax + 4]
jmp 0x10004adc
mov dword [ebp + 0xc], ebx
jmp 0x10004b3e
Function at 0x10004bb1
Capabilities:
Inspect section memory permissions

Disassembly:
mov edi, dword [ebp - 0x88]
mov eax, dword [ebp + 0xc]
cmp ax, word [edi + 6]
jne 0x10004b56
mov edx, dword [ebp - 0xb4]
xor ecx, ecx
mov edi, 0x60000000
jmp 0x10004b74
movzx eax, ax
lea eax, [eax + eax*4]
mov ecx, dword [edi + eax*8 + 0x104]
mov edx, dword [edi + eax*8 + 0x108]
lea eax, [edi + eax*8 + 0xf8]
mov edi, dword [eax + 0x24]
lea eax, [edx + ecx - 1]
xor edx, edx
div dword [ebp - 0xac]
xor edx, edx
mov dword [ebp - 0x44], eax
mov eax, ecx
div dword [ebp - 0xac]
invalid
invalid
mov ecx, dword [ebp + 0x18]
cmp edx, ebx
je 0x10004bb9
or byte [eax + ecx], 1
cmp dword [ebp + 8], ebx
je 0x10004bc2
or byte [eax + ecx], 2
cmp dword [ebp + 0x10], ebx
je 0x10004bcc
add ecx, eax
or byte [ecx], 4
inc eax
cmp eax, dword [ebp - 0x44]
jbe 0x10004bae
inc dword [ebp + 0xc]
mov eax, dword [ebp - 0x88]
mov cx, word [ebp + 0xc]
cmp cx, word [eax + 6]
jbe 0x10004b38
mov dword [ebp + 8], esi
xor edi, edi
mov eax, dword [ebp + 0x18]
push 2
pop ecx
movzx eax, byte [edi + eax]
mov dh, 4
pop es
sub eax, ecx
je 0x10004c1f
dec eax
je 0x10004c16
sub eax, 3
je 0x10004c0d
mov dword [ebp - 4], 0x40
jmp 0x10004c3c
mov dword [ebp - 4], 4
jmp 0x10004c22
mov dword [ebp - 4], 0x20
jmp 0x10004c22
mov dword [ebp - 4], ecx
lea eax, [ebp - 4]
push eax
push dword [ebp - 4]
push dword [ebp - 0xac]
push dword [ebp + 8]
call dword [ebp - 0xbc]
test eax, eax
je 0x10004c6e
mov eax, dword [ebp - 0xac]
add dword [ebp + 8], eax
inc edi
cmp edi, dword [ebp - 0x8c]
jbe 0x10004bee
mov eax, dword [ebp - 0x88]
mov edi, dword [eax + 0x28]
add edi, esi
call fcn.1000447f
pop esp
mov edx, 0x75ff88a5
adc al, 0x6a
add dword [esi - 1], edx
xlatb
mov eax, esi
jmp 0x10004c7a
push 0x8000
push ebx
push esi
call dword [ebp - 8]
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret

Function at 0x10004ea9
Capabilities:
Contain obfuscated stackstrings

Disassembly:
mov al, dh
test dword [0x82fffffc], esp
mov byte [ebp - 0x3da], 0x8b
mov byte [ebp - 0x3d9], 0xaf
mov byte [ebp - 0x3d8], 0xee
lea eax, [ebp - 0x3ec]
push eax
call fcn.1000448f
pop ecx
push eax
push dword [ebp + 0x18]
push dword [ebp + 0x14]
call fcn.10004444
add esp, 0xc
mov dword [ebp - 0x340], eax
call fcn.1000447f
or dword [ecx + esi*8], eax
rol byte [eax - 0x5335b], cl
inc dword [eax]
and byte [ebp - 0x533], 0
mov byte [ebp - 0x532], 0x68
and byte [ebp - 0x531], 0
mov byte [ebp - 0x530], 0xd4
mov byte [ebp - 0x52f], 0xfb
mov byte [ebp - 0x52e], 0xf8
mov byte [ebp - 0x52d], 0xe4
mov byte [ebp - 0x52c], 0xf2
mov byte [ebp - 0x52b], 0xdf
mov byte [ebp - 0x52a], 0xf6
mov byte [ebp - 0x529], 0xf9
mov byte [ebp - 0x528], 0xf3
Function at 0x10004f4c
Capabilities:
Contain obfuscated stackstrings

Disassembly:
mov byte [ebp - 0x527], 0xfb
mov byte [ebp - 0x526], 0xf2
mov byte [ebp - 0x525], 0x97
lea eax, [ebp - 0x534]
push eax
call fcn.1000448f
pop ecx
push eax
push dword [ebp + 0x18]
push dword [ebp + 0x14]
call fcn.10004444
add esp, 0xc
mov dword [ebp - 0x680], eax
call fcn.1000447f
popfd
outsb dx, byte [esi]
and al, 0x92
and byte [ebp - 0x664], 0
and byte [ebp - 0x663], 0
mov byte [ebp - 0x662], 7
and byte [ebp - 0x661], 0
mov byte [ebp - 0x660], 0xb0
mov byte [ebp - 0x65f], 0x9d
mov byte [ebp - 0x65e], 0x99
mov byte [ebp - 0x65d], 0x88
mov byte [ebp - 0x65c], 0xb9
mov byte [ebp - 0x65b], 0x94
mov byte [ebp - 0x65a], 0x94
mov byte [ebp - 0x659], 0x97
mov byte [ebp - 0x658], 0x9b
mov byte [ebp - 0x657], 0xf8
lea eax, [ebp - 0x664]
push eax
call fcn.1000448f
pop ecx
push eax
push dword [ebp + 0x18]
push dword [ebp + 0x14]
call fcn.10004444
add esp, 0xc
mov dword [ebp - 0x67c], eax
and byte [ebp - 0x524], 0
and byte [ebp - 0x523], 0
mov byte [ebp - 0x522], 0x15
and byte [ebp - 0x521], 0
mov byte [ebp - 0x520], 0xa2
mov byte [ebp - 0x51f], 0x8f
mov byte [ebp - 0x51e], 0x8b
invalid
test ebx, esp
cli
invalid
Function at 0x100091cd
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
push ebx
push esi
xor esi, esi
mov dword [ebp - 0x10], esi
mov dword [ebp - 0xc], esi
mov dword [ebp - 0x14], esi
mov eax, dword [eax - 8]
lea ecx, [ebp - 0x14]
push edi
push ecx
push eax
lea ecx, [ebp + 8]
call fcn.10002617
push eax
call sub.VERSION.dll_GetFileVersionInfoSizeA
push eax
mov dword [ebp - 0x18], eax
call dword [sym.imp.ole32.dll_CoTaskMemAlloc]
or edi, 0xffffffff
lea ecx, [ebp + 8]
push edi
mov ebx, eax
call fcn.100020d7
push 0x2c
push 0x2e
lea ecx, [ebp + 0xc]
call fcn.100095aa
mov eax, dword [ebp + 8]
push esi
push 0x80
push 3
mov eax, dword [eax - 8]
push esi
push 1
push SysReAllocStringLen
push eax
lea ecx, [ebp + 8]
call fcn.10002617
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
push edi
lea ecx, [ebp + 8]
mov dword [ebp - 8], eax
call fcn.100020d7
cmp dword [ebp - 8], edi
jne 0x10009264
push ebx
call dword [sym.imp.ole32.dll_CoTaskMemFree]
push 0xfffffffffffffffe
pop edi
jmp 0x1000930f
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 8]
push ebx
push dword [ebp - 0x18]
lea ecx, [ebp + 8]
mov eax, dword [eax - 8]
push esi
push eax
call fcn.10002617
push eax
call sub.VERSION.dll_GetFileVersionInfoA
push edi
lea ecx, [ebp + 8]
mov dword [ebp - 0x18], eax
call fcn.100020d7
cmp dword [ebp - 0x18], esi
jne 0x100092a1
push ebx
call dword [sym.imp.ole32.dll_CoTaskMemFree]
jmp 0x1000930f
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x10]
push eax
push 0x1001f04c
push ebx
call sub.VERSION.dll_VerQueryValueA
test eax, eax
je 0x10009298
cmp dword [ebp - 0xc], esi
je 0x10009298
mov eax, dword [0x1001f030]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x10]
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
lea eax, [ebp - 4]
push str._d__d__d__d
push eax
call fcn.10002307
add esp, 0x18
push ebx
call dword [sym.imp.ole32.dll_CoTaskMemFree]
push dword [ebp + 0xc]
push dword [ebp - 4]
call section..text
pop ecx
mov edi, eax
pop ecx
lea ecx, [ebp - 4]
call fcn.10001cd1
lea ecx, [ebp + 8]
call fcn.10001cd1
lea ecx, [ebp + 0xc]
call fcn.10001cd1
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x1000993f
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
push esi
push edi
mov dword [ebp - 8], ecx
mov dword [ebp - 0xc], ebx
jne 0x10009959
xor esi, esi
jmp 0x10009987
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea edi, [eax + eax + 2]
mov eax, edi
add eax, 3
and al, 0xfc
call fcn.10016950
mov esi, esp
push ebx
push ebx
push edi
push esi
push 0xffffffffffffffff
push dword [ebp + 8]
mov byte [esi], bl
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push 2
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
mov edi, eax
cmp edi, ebx
mov dword [ebp - 4], edi
jne 0x100099c4
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
test eax, eax
jg 0x100099af
call esi
mov esi, eax
jmp 0x10009a59
call esi
mov esi, eax
and esi, 0xffff
or esi, 0x80070000
jmp 0x10009a59
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
cmp esi, ebx
jne 0x100099f5
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
test eax, eax
jle 0x10009a08
call esi
mov esi, eax
and esi, 0xffff
or esi, 0x80070000
jmp 0x10009a50
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
cmp edi, ebx
mov dword [ebp + 8], edi
jne 0x10009a0c
jmp 0x100099d7
call esi
jmp 0x10009a4e
push esi
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
mov eax, dword [ebp + 8]
cmp byte [esi + eax], bl
je 0x10009a42
lea eax, [esi + 1]
add eax, 3
and al, 0xfc
call fcn.10016950
lea eax, [esi + 1]
mov edi, esp
push eax
push dword [ebp + 8]
push edi
call fcn.10016990
add esp, 0xc
mov byte [edi + esi], bl
push dword [ebp + 0x14]
lea ecx, [ebp - 0xc]
push edi
call fcn.10009ac0
mov esi, eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea esp, [ebp - 0x18]
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x1000a476
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
push ebx
push esi
push edi
push 0x2001f
push dword [ebp + 8]
mov ebx, ecx
xor esi, esi
lea ecx, [ebp - 4]
push dword [ebx]
mov dword [ebp - 4], esi
call fcn.1000a438
mov edi, eax
cmp edi, esi
je 0x1000a4b6
cmp dword [ebp - 4], esi
je 0x1000a4af
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, edi
jmp 0x1000a553
lea eax, [ebp - 0x14]
mov edi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
push eax
push esi
push esi
lea eax, [ebp - 8]
push esi
push eax
lea eax, [ebp - 0x114]
mov dword [ebp - 8], 0x100
push eax
push esi
push dword [ebp - 4]
call edi
test eax, eax
jne 0x1000a527
lea eax, [ebp - 0x114]
lea ecx, [ebp - 4]
push eax
call fcn.1000a476
cmp eax, esi
mov dword [ebp - 0xc], eax
jne 0x1000a514
lea eax, [ebp - 0x14]
mov dword [ebp - 8], 0x100
push eax
push esi
push esi
lea eax, [ebp - 8]
push esi
push eax
lea eax, [ebp - 0x114]
push eax
push esi
push dword [ebp - 4]
jmp 0x1000a4d9
cmp dword [ebp - 4], esi
je 0x1000a522
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp - 0xc]
jmp 0x1000a553
cmp dword [ebp - 4], esi
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
je 0x1000a53a
push dword [ebp - 4]
call edi
mov dword [ebp - 4], esi
push dword [ebp + 8]
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
cmp dword [ebp - 4], esi
mov ebx, eax
je 0x1000a551
push dword [ebp - 4]
call edi
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret 4
Function at 0x1000a55a
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2014
call fcn.10016950
push ebx
push esi
lea eax, [ebp - 0x2014]
push edi
mov esi, ecx
push eax
mov dword [ebp - 0x14], esi
call fcn.10009c19
xor edi, edi
cmp eax, edi
jl 0x1000a712
lea eax, [ebp - 0xa]
push eax
lea eax, [ebp - 0x2014]
push eax
call fcn.1000a71f
pop ecx
test eax, eax
pop ecx
jne 0x1000a5a5
mov eax, 0x80020009
jmp 0x1000a712
mov ecx, esi
call fcn.10009bf1
lea eax, [ebp - 0x1014]
mov ecx, esi
push eax
call fcn.10009c19
cmp eax, edi
jl 0x1000a712
movzx eax, word [ebp - 0xa]
sub eax, 8
je 0x1000a6da
sub eax, 9
je 0x1000a63f
dec eax
dec eax
jne 0x1000a701
lea eax, [ebp - 0x1014]
test eax, eax
jne 0x1000a5ea
xor ebx, ebx
jmp 0x1000a61f
lea eax, [ebp - 0x1014]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov esi, eax
inc esi
lea eax, [esi + esi]
add eax, 3
and al, 0xfc
call fcn.10016950
mov ebx, esp
push esi
push ebx
lea eax, [ebp - 0x1014]
push 0xffffffffffffffff
push eax
push edi
push edi
mov word [ebx], di
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
lea eax, [ebp - 0x10]
push eax
push edi
push edi
push ebx
call dword [sym.imp.OLEAUT32.dll_VarUI4FromDisp]
mov eax, dword [ebp - 0x10]
push 4
mov dword [ebp - 8], eax
lea eax, [ebp - 8]
push eax
push 4
jmp 0x1000a6f2
lea eax, [ebp - 0x1014]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test al, 1
mov dword [ebp - 8], eax
jne 0x1000a67b
cdq
sub eax, edx
mov ebx, eax
sar ebx, 1
mov eax, ebx
add eax, 3
and al, 0xfc
call fcn.10016950
mov dword [ebp - 4], esp
push ebx
push edi
push dword [ebp - 4]
call fcn.100167a0
add esp, 0xc
cmp dword [ebp - 4], edi
jne 0x1000a685
mov eax, 0x80004005
jmp 0x1000a712
cmp dword [ebp - 8], 0
jle 0x1000a6bf
mov ecx, dword [ebp - 4]
mov eax, edi
cdq
sub eax, edx
sar eax, 1
lea esi, [eax + ecx]
mov al, byte [ebp + edi - 0x1014]
push eax
call fcn.1000a7a6
pop ecx
mov ecx, edi
push 4
and ecx, 1
shl ecx, 2
mov edx, ecx
pop ecx
sub ecx, edx
shl al, cl
or byte [esi], al
inc edi
cmp edi, dword [ebp - 8]
jl 0x1000a68b
mov eax, dword [ebp + 8]
push ebx
push dword [ebp - 4]
mov eax, dword [eax]
push 3
push 0
push dword [ebp + 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
xor edi, edi
jmp 0x1000a701
lea eax, [ebp - 0x1014]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
inc eax
push eax
lea eax, [ebp - 0x1014]
push eax
push 1
mov eax, dword [ebp + 8]
push edi
push dword [ebp + 0xc]
push dword [eax]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push dword [ebp + 0x10]
mov ecx, dword [ebp - 0x14]
call fcn.10009c19
cmp eax, edi
jl 0x1000a712
xor eax, eax
lea esp, [ebp - 0x2020]
pop edi
pop esi
pop ebx
leave
ret 0xc

Function at 0x1000d61b
Capabilities:
Hide graphical window

Disassembly:
push esi
mov esi, ecx
add ecx, 0xffffff80
neg esi
sbb esi, esi
and esi, ecx
mov ecx, dword [esi + 0x84]
lea eax, [esi + 0x84]
push eax
call dword [ecx + 0x18]
mov esi, dword [esi + 0x60]
test esi, esi
je 0x1000d647
push 0
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
xor eax, eax
pop esi
ret 8
Function at 0x1000facc
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
push esi
push 0x10026c00
lea ecx, [ebp - 4]
call fcn.10001cfd
lea eax, [ebp - 8]
push eax
push 0x20019
push 0
push dword [ebp + 0x14]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x1000fb69
lea eax, [ebp + 0xc]
mov esi, 0x104
push eax
lea eax, [ebp - 0x114]
push eax
lea eax, [ebp - 0xc]
push eax
push 0
push dword [ebp + 0x10]
mov dword [ebp + 0xc], esi
mov dword [ebp - 0xc], 1
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x1000fb4e
lea eax, [ebp - 0x114]
lea ecx, [ebp - 0x10]
push eax
call fcn.10001cfd
push eax
lea ecx, [ebp - 4]
call fcn.10001d92
lea ecx, [ebp - 0x10]
call fcn.10001cd1
push esi
lea eax, [ebp - 0x114]
push 0
push eax
call fcn.100167a0
add esp, 0xc
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 4]
mov esi, dword [ebp + 8]
cmp dword [ecx - 0xc], 0
lea eax, [ecx - 0xc]
jl 0x1000fb83
push eax
mov dword [esi], ecx
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
jmp 0x1000fb92
mov eax, dword [0x1001f030]
push ecx
mov ecx, esi
mov dword [esi], eax
call fcn.10001e2a
lea ecx, [ebp - 4]
call fcn.10001cd1
lea ecx, [ebp + 0x10]
call fcn.10001cd1
lea ecx, [ebp + 0x14]
call fcn.10001cd1
mov eax, esi
pop esi
leave
ret 0x10