joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4051a0
Capabilities:
Enumerate processes

Disassembly:
push 0xffffffffffffffff
push 0x520323
mov eax, dword fs:[0]
push eax
sub esp, 0x130
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x12c], eax
push ebp
push esi
push edi
mov eax, dword [0x576fe4]
xor eax, esp
push eax
lea eax, [esp + 0x140]
mov dword fs:[0], eax
xor ebp, ebp
push 0x124
lea eax, [esp + 0x1c]
push ebp
push eax
mov dword [esp + 0x154], 0
mov dword [esp + 0x20], ebp
call fcn.00505810
add esp, 0xc
push ebp
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
or edi, 0xffffffff
cmp esi, edi
jne 0x405244
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x150]
add eax, 0xfffffff0
mov dword [esp + 0x148], edi
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edi
dec edi
test edi, edi
jg 0x40523d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
jmp 0x405333
lea ecx, [esp + 0x14]
push ecx
push esi
mov dword [esp + 0x1c], 0x128
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x405303
push 0x530041
lea ecx, [esp + 0x14]
call fcn.00403850
mov byte [esp + 0x148], 1
lea eax, [esp + 0x38]
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x405280
sub eax, edx
push eax
lea edx, [esp + 0x3c]
push edx
lea ecx, [esp + 0x18]
call fcn.00402560
mov ecx, dword [esp + 0x10]
xor eax, eax
test ecx, ecx
setne al
test eax, eax
je 0x4052cd
mov eax, dword [esp + 0x150]
push ecx
push eax
call fcn.005064b6
add esp, 8
test eax, eax
je 0x4052d7
lea ecx, [esp + 0x14]
push ecx
push esi
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x405275
jmp 0x4052dc
push 0x80004005
call fcn.00401210
mov ebp, 1
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
mov byte [esp + 0x148], 0
lea edx, [eax + 0xc]
mov ecx, edi
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x405303
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x150]
add eax, 0xfffffff0
mov dword [esp + 0x148], edi
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edi
dec edi
test edi, edi
jg 0x405331
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, ebp
mov ecx, dword [esp + 0x140]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
mov ecx, dword [esp + 0x12c]
xor ecx, esp
call fcn.0050534a
add esp, 0x13c
ret 4
Function at 0x405360
Capabilities:
Access peb ldr_data
Persist via run registry key

Disassembly:
push 0xffffffffffffffff
push 0x520388
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push esi
mov eax, dword [0x576fe4]
xor eax, esp
push eax
lea eax, [esp + 0x18]
mov dword fs:[0], eax
lea ecx, [esp + 0xb]
mov dword [esp + 0x20], 1
call fcn.0040d470
mov eax, dword [esp + 0x28]
push ecx
add eax, 0xfffffff0
mov dword [esp + 0x10], esp
mov esi, esp
push eax
mov byte [esp + 0x28], 2
call fcn.00401c50
add eax, 0x10
mov dword [esi], eax
mov eax, dword [esp + 0x34]
add eax, 0xfffffff0
mov dword [esp + 0x18], esp
mov esi, esp
push eax
mov byte [esp + 0x2c], 3
call fcn.00401c50
add eax, 0x10
mov dword [esi], eax
mov ecx, esp
mov dword [esp + 0x20], esp
push str.SOFTWAREMicrosoftWindowsCurrentVersionRun
mov byte [esp + 0x30], 4
call fcn.00403850
push reloc.OLEAUT32.dll_SysReAllocString
lea ecx, [esp + 0x1b]
mov byte [esp + 0x30], 2
call fcn.0040d480
lea ecx, [esp + 0xb]
mov byte [esp + 0x20], 1
call fcn.00401000
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
mov byte [esp + 0x20], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40542b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x2c]
add eax, 0xfffffff0
mov dword [esp + 0x20], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405453
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x18]
mov dword fs:[0], ecx
pop ecx
pop esi
add esp, 0x1c
ret 8

Function at 0x405470
Capabilities:
Persist via run registry key

Disassembly:
push 0xffffffffffffffff
push 0x5203c8
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push esi
mov eax, dword [0x576fe4]
xor eax, esp
push eax
lea eax, [esp + 0x14]
mov dword fs:[0], eax
lea ecx, [esp + 0xb]
mov dword [esp + 0x1c], 0
call fcn.0040d470
mov eax, dword [esp + 0x24]
push ecx
add eax, 0xfffffff0
mov dword [esp + 0x10], esp
mov esi, esp
push eax
mov byte [esp + 0x24], 1
call fcn.00401c50
add eax, 0x10
mov dword [esi], eax
mov ecx, esp
mov dword [esp + 0x18], esp
push str.SOFTWAREMicrosoftWindowsCurrentVersionRun
mov byte [esp + 0x28], 2
call fcn.00403850
push reloc.OLEAUT32.dll_SysReAllocString
lea ecx, [esp + 0x17]
mov byte [esp + 0x28], 1
call fcn.0040d530
lea ecx, [esp + 0xb]
mov byte [esp + 0x1c], 0
call fcn.00401000
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
mov dword [esp + 0x1c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405521
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x14]
mov dword fs:[0], ecx
pop ecx
pop esi
add esp, 0x18
ret 4
Function at 0x405590
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x520429
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
mov eax, dword [0x576fe4]
xor eax, esp
push eax
lea eax, [esp + 0x14]
mov dword fs:[0], eax
mov dword [esp + 0xc], 0
mov esi, dword [esp + 0x24]
mov ebx, 1
push 0x530041
mov ecx, esi
mov dword [esp + 0x20], ebx
call fcn.00403850
mov eax, dword [esp + 0x30]
sub eax, 0
mov dword [esp + 0xc], ebx
je 0x405695
sub eax, ebx
je 0x40563f
sub eax, ebx
jne 0x4056fa
movzx eax, byte [esp + 0x2c]
mov ecx, dword [esp + 0x28]
push eax
push ecx
call fcn.005067b4
add esp, 8
test eax, eax
je 0x4056fa
sub eax, dword [esp + 0x28]
test eax, eax
jle 0x4056fa
push eax
lea edx, [esp + 0x30]
push edx
lea ecx, [esp + 0x30]
call fcn.00402a50
push eax
mov ecx, esi
mov byte [esp + 0x20], 4
call fcn.00402e20
mov eax, dword [esp + 0x2c]
jmp 0x4056da
movzx ecx, byte [esp + 0x2c]
mov edx, dword [esp + 0x28]
push ecx
push edx
call fcn.005067b4
add esp, 8
test eax, eax
je 0x4056fa
mov edx, dword [esp + 0x28]
sub eax, edx
mov ecx, eax
test ecx, ecx
jle 0x4056fa
mov eax, dword [edx - 0xc]
sub eax, ecx
sub eax, ebx
push eax
inc ecx
push ecx
lea eax, [esp + 0x38]
push eax
lea ecx, [esp + 0x34]
call fcn.004029a0
push eax
mov ecx, esi
mov byte [esp + 0x20], 3
call fcn.00402e20
mov eax, dword [esp + 0x30]
jmp 0x4056da
mov eax, dword [esp + 0x28]
cmp dword [eax - 0xc], 0
jle 0x4056fa
movzx ecx, byte [esp + 0x2c]
push ecx
push eax
call fcn.005066e1
add esp, 8
test eax, eax
je 0x4056fa
sub eax, dword [esp + 0x28]
test eax, eax
jle 0x4056fa
push eax
lea edx, [esp + 0x14]
push edx
lea ecx, [esp + 0x30]
call fcn.00402a50
push eax
mov ecx, esi
mov byte [esp + 0x20], 2
call fcn.00402e20
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
mov byte [esp + 0x1c], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4056fa
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
mov byte [esp + 0x1c], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40571f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, esi
mov ecx, dword [esp + 0x14]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
add esp, 0x14
ret 0x10
Function at 0x40a5e0
Capabilities:
Check os version

Disassembly:
sub esp, 0x98
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x94], eax
lea eax, [esp]
push eax
mov dword [esp + 4], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x40a632
cmp dword [esp + 0x10], 2
jne 0x40a632
cmp dword [esp + 4], 6
jb 0x40a632
mov eax, 1
mov ecx, dword [esp + 0x94]
xor ecx, esp
call fcn.0050534a
add esp, 0x98
ret
mov ecx, dword [esp + 0x94]
xor ecx, esp
xor eax, eax
call fcn.0050534a
add esp, 0x98
ret

Function at 0x40a650
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x3c
push 0x3c
lea eax, [esp + 4]
push 0
push eax
call fcn.00505810
mov edx, dword [esp + 0x50]
mov ecx, dword [esp + 0x4c]
mov eax, dword [esp + 0x54]
mov dword [esp + 0x1c], edx
add esp, 0xc
mov dword [esp + 8], ecx
mov ecx, dword [esp + 0x4c]
lea edx, [esp]
push edx
mov dword [esp + 4], 0x3c
mov dword [esp + 8], 0x500
mov dword [esp + 0x10], str.runas
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x20], 0
call dword [sym.imp.SHELL32.dll_ShellExecuteExA]
add esp, 0x3c
ret

Function at 0x40a7c0
Capabilities:
Get system information on windows

Disassembly:
sub esp, 0x48
mov eax, 0xffff
push esi
mov ecx, eax
push 0x531570
xor esi, esi
mov word [esp + 0x2c], ax
mov word [esp + 8], cx
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
test eax, eax
je 0x40a858
push ebx
push str.GetNativeSystemInfo
push eax
lea ebx, [esi + 1]
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x40a80e
lea edx, [esp + 8]
push edx
call eax
lea eax, [esp + 0x2c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
jmp 0x40a82a
push edi
lea ecx, [esp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov ecx, 9
lea esi, [esp + 0xc]
lea edi, [esp + 0x30]
rep movsd dword es:[edi], dword [esi]
pop edi
mov edx, dword [esp + 8]
push edx
call fcn.0040a740
mov ecx, dword [esp + 0x58]
mov dword [ecx + 0xa8], eax
mov eax, dword [esp + 0x30]
push eax
call fcn.0040a740
add esp, 8
mov dword [ecx + 0x10], eax
mov eax, ebx
pop ebx
pop esi
add esp, 0x48
ret 4
mov eax, esi
pop esi
add esp, 0x48
ret 4

Function at 0x40a910
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x10
lea eax, [esp]
push eax
push 0x20119
push 0
push str.SystemCurrentControlSetControlTerminal_Server
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x14], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40a98d
lea ecx, [esp + 8]
push ecx
mov ecx, dword [esp + 4]
lea edx, [esp + 8]
push edx
lea eax, [esp + 0x14]
push eax
push 0
push str.TSAppCompat
push ecx
mov dword [esp + 0x1c], 1
mov dword [esp + 0x20], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40a983
cmp dword [esp + 4], eax
jne 0x40a983
mov eax, dword [esp + 0x14]
or dword [eax + 0x130], 0x200
mov edx, dword [esp]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
add esp, 0x10
ret 4
Function at 0x40a9a0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x10
push 0x57
call dword [sym.imp.USER32.dll_GetSystemMetrics]
test eax, eax
jne 0x40aa26
mov dword [esp], eax
lea eax, [esp]
push eax
push 0x20119
push 0
push str.SystemWPAMediaCenter
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40aa34
lea ecx, [esp + 8]
push ecx
mov ecx, dword [esp + 4]
lea edx, [esp + 8]
push edx
mov dword [esp + 0xc], eax
lea eax, [esp + 0x14]
push eax
push 0
push str.Installed
push ecx
mov dword [esp + 0x20], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40aa16
cmp dword [esp + 4], eax
je 0x40aa16
mov eax, dword [esp + 0x14]
or dword [eax + 0x130], 0x4000
mov edx, dword [esp]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
add esp, 0x10
ret 4
mov eax, dword [esp + 0x14]
or dword [eax + 0x130], 0x4000
add esp, 0x10
ret 4

Function at 0x40aa40
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x10
push 0x56
call dword [sym.imp.USER32.dll_GetSystemMetrics]
test eax, eax
jne 0x40aac6
mov dword [esp], eax
lea eax, [esp]
push eax
push 0x20119
push 0
push str.SystemWPATabletPC
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40aad4
lea ecx, [esp + 8]
push ecx
mov ecx, dword [esp + 4]
lea edx, [esp + 8]
push edx
mov dword [esp + 0xc], eax
lea eax, [esp + 0x14]
push eax
push 0
push str.Installed
push ecx
mov dword [esp + 0x20], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40aab6
cmp dword [esp + 4], eax
je 0x40aab6
mov eax, dword [esp + 0x14]
or dword [eax + 0x130], 0x8000
mov edx, dword [esp]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
add esp, 0x10
ret 4
mov eax, dword [esp + 0x14]
or dword [eax + 0x130], 0x8000
add esp, 0x10
ret 4
Function at 0x40aae0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x40c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x408], eax
push esi
mov esi, dword [esp + 0x414]
lea eax, [esp + 4]
push eax
push 0x101
push 0
push str.SOFTWAREMicrosoftWindows_NTCurrentVersion
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x18], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40abe9
lea ecx, [esp + 8]
push ecx
lea edx, [esp + 0x10]
push edx
push eax
push eax
mov byte [esp + 0x1c], al
mov eax, dword [esp + 0x14]
push str.CurrentType
push eax
mov dword [esp + 0x20], 0x400
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40abde
lea ecx, [esp + 0xc]
push str.Uniprocessor_Free
push ecx
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40ab7a
or dword [esi + 0x130], 0x400
jmp 0x40abde
lea edx, [esp + 0xc]
push str.Uniprocessor_Checked
push edx
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40ab9c
or dword [esi + 0x130], 0x800
jmp 0x40abde
lea eax, [esp + 0xc]
push str.Multiprocessor_Free
push eax
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40abbe
or dword [esi + 0x130], 0x1000
jmp 0x40abde
lea ecx, [esp + 0xc]
push str.Multiprocessor_Checked
push ecx
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40abde
or dword [esi + 0x130], 0x2000
mov edx, dword [esp + 4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x40c]
pop esi
xor ecx, esp
call fcn.0050534a
add esp, 0x40c
ret 4

Function at 0x40ac10
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x8c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x90]
push esi
lea ecx, [esp + 4]
push ecx
lea edx, [esp + 0x10]
push edx
lea ecx, [esp + 0x10]
push ecx
xor esi, esi
push esi
push str.CurrentBuildNumber
push eax
mov dword [esp + 0x1c], 0x80
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40ac79
lea edx, [esp + 0xc]
push edx
call fcn.0050745a
add esp, 4
pop esi
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.0050534a
add esp, 0x8c
ret
mov ecx, dword [esp + 0x8c]
mov eax, esi
pop esi
xor ecx, esp
call fcn.0050534a
add esp, 0x8c
ret

Function at 0x40acf0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x8c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x90]
push ebx
mov ebx, dword [esp + 0x9c]
push esi
push edi
mov edi, dword [esp + 0xa0]
lea ecx, [esp + 0xc]
push ecx
lea edx, [esp + 0x18]
push edx
lea ecx, [esp + 0x18]
push ecx
push 0
push str.CurrentVersion
push eax
mov byte [esp + 0x2c], 0
mov dword [esp + 0x24], 0x80
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov esi, eax
neg esi
sbb esi, esi
add esi, 1
je 0x40ad65
push ebx
push edi
lea edx, [esp + 0x1c]
push str._u._u
push edx
call fcn.005074cf
add esp, 0x10
mov ecx, dword [esp + 0x94]
pop edi
mov eax, esi
pop esi
pop ebx
xor ecx, esp
call fcn.0050534a
add esp, 0x8c
ret
Function at 0x40ad80
Capabilities:
Get common file path
Get file version info

Disassembly:
sub esp, 0x11c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x118], eax
mov eax, dword [esp + 0x120]
push ebx
push 0x104
lea ecx, [esp + 0x1c]
xor ebx, ebx
push ecx
mov dword [esp + 0x18], eax
mov dword [esp + 0x10], ebx
mov byte [esp + 0x20], bl
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jne 0x40add4
pop ebx
mov ecx, dword [esp + 0x118]
xor ecx, esp
call fcn.0050534a
add esp, 0x11c
ret
push ebp
push esi
push edi
push str.HAL.DLL
lea edx, [esp + 0x28]
push 0x104
push edx
call fcn.005074f1
add esp, 0xc
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x28]
push ecx
mov dword [esp + 0x20], ebx
call sub.VERSION.dll_GetFileVersionInfoSizeA
mov edi, eax
cmp edi, ebx
je 0x40ae82
mov ebp, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push edi
push ebx
call ebp
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
cmp esi, ebx
jne 0x40ae22
xor eax, eax
jmp 0x40ae86
push esi
push edi
push ebx
lea edx, [esp + 0x30]
push edx
call sub.VERSION.dll_GetFileVersionInfoA
test eax, eax
je 0x40ae77
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x14]
push ecx
push 0x52ff5c
push esi
mov dword [esp + 0x30], ebx
mov dword [esp + 0x20], ebx
call sub.VERSION.dll_VerQueryValueA
test eax, eax
je 0x40ae77
mov edx, dword [esp + 0x10]
cmp dword [edx + 0xc], 0x25804287
jb 0x40ae6f
mov eax, dword [esp + 0x1c]
or dword [eax + 0x134], 0x400000
mov dword [esp + 0x14], 1
push esi
push ebx
call ebp
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x128]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0050534a
add esp, 0x11c
ret

Function at 0x40b9d0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x40c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x408], eax
push esi
mov esi, dword [esp + 0x414]
cmp dword [esi + 0x98], 5
jne 0x40baa7
cmp dword [esi + 0x9c], 0
je 0x40baa7
cmp word [esi + 0x12c], 1
jne 0x40baa7
lea eax, [esp + 4]
push eax
push 0x101
push 0
push str.SOFTWAREMicrosoftWindows_NTCurrentVersion
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x18], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40baa7
lea ecx, [esp + 8]
push ecx
lea edx, [esp + 0x10]
push edx
push eax
push eax
mov byte [esp + 0x1c], al
mov eax, dword [esp + 0x14]
push str.SubVersionNumber
push eax
mov dword [esp + 0x20], 0x400
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40ba9c
lea ecx, [esp + 0xc]
push 0x5317d4
push ecx
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40ba9c
mov edx, 1
mov word [esi + 0x12e], dx
cmp dword [esp + 0x418], eax
je 0x40ba9c
mov eax, edx
mov word [esi + 0x96], ax
mov ecx, dword [esp + 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x40c]
pop esi
xor ecx, esp
call fcn.0050534a
add esp, 0x40c
ret 8
Function at 0x40bac0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x40c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x408], eax
push esi
mov esi, dword [esp + 0x414]
lea eax, [esp + 4]
push eax
push 0x20119
push 0
push str.SystemCurrentControlSetControlProductOptions
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x18], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40bc17
lea ecx, [esp + 8]
push ecx
lea edx, [esp + 0x10]
push edx
push eax
push eax
mov byte [esp + 0x1c], al
mov eax, dword [esp + 0x14]
push str.ProductType
push eax
mov dword [esp + 0x20], 0x400
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40bc0c
push str.LANMANNT
cmp dword [esp + 0x41c], eax
je 0x40bb7d
lea ecx, [esp + 0x10]
push ecx
call fcn.005064b6
add esp, 8
test eax, eax
je 0x40bb98
lea edx, [esp + 0xc]
push str.LANSECNT
push edx
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40bc0c
or dword [esi + 0x130], 8
jmp 0x40bc0c
lea eax, [esp + 0x10]
push eax
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40bba1
mov dword [esi + 0x13c], 3
or dword [esi + 0x130], 4
jmp 0x40bc0c
lea ecx, [esp + 0xc]
push str.SERVERNT
push ecx
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40bbc3
mov dword [esi + 0x13c], 2
jmp 0x40bc0c
lea edx, [esp + 0xc]
push str.LANSECNT
push edx
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40bbec
or dword [esi + 0x130], 8
mov dword [esi + 0x13c], 3
jmp 0x40bc0c
lea eax, [esp + 0xc]
push str.WinNT
push eax
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40bc0c
mov dword [esi + 0x13c], 1
mov ecx, dword [esp + 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x40c]
pop esi
xor ecx, esp
call fcn.0050534a
add esp, 0x40c
ret 8

Function at 0x40bc30
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x40c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x408], eax
push esi
mov esi, dword [esp + 0x414]
lea eax, [esp + 4]
push eax
push 0x20119
push 0
push str.SoftwareMicrosoftWindows_NTCurrentVersion
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x18], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40bceb
lea ecx, [esp + 8]
push ecx
lea edx, [esp + 0x10]
push edx
push eax
push eax
mov byte [esp + 0x1c], al
mov eax, dword [esp + 0x14]
push str.EditionID
push eax
mov dword [esp + 0x20], 0x400
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40bce0
lea ecx, [esp + 0xc]
push ecx
call fcn.0050741f
lea edx, [esp + 0x10]
push str.CORECONNECTED
push edx
call fcn.0050660e
add esp, 0xc
test eax, eax
jne 0x40bcd6
lea eax, [esp + 0xc]
push str.CONNECTEDCORE
push eax
call fcn.0050660e
add esp, 8
test eax, eax
je 0x40bce0
or dword [esi + 0x134], 0x800000
mov ecx, dword [esp + 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x40c]
pop esi
xor ecx, esp
call fcn.0050534a
add esp, 0x40c
ret 4
Function at 0x40bd10
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0xc
push edi
lea eax, [esp + 4]
push eax
push 0x20119
xor edi, edi
push edi
push str.SystemCurrentControlSetControlProductOptions
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x18], edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40be57
mov eax, dword [esp + 4]
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
lea ecx, [esp + 0xc]
push ecx
push edi
lea edx, [esp + 0x18]
push edx
push edi
push str.ProductSuite
push eax
mov dword [esp + 0x28], edi
mov dword [esp + 0x24], edi
call esi
test eax, eax
jne 0x40be4b
mov ecx, dword [esp + 0xc]
push ebp
push ecx
call fcn.00412be7
mov ecx, dword [esp + 0x10]
add esp, 4
lea edx, [esp + 0x10]
push edx
mov ebp, eax
push ebp
lea eax, [esp + 0x1c]
push eax
push edi
push str.ProductSuite
push ecx
call esi
test eax, eax
jne 0x40be41
mov esi, ebp
cmp byte [ebp], al
je 0x40be41
mov edi, dword [esp + 0x1c]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenA]
push str.Terminal_Server
push esi
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40bdcd
or dword [edi + 0x130], 0x10
jmp 0x40be2e
push 0x5318a8
push esi
call fcn.005064b6
add esp, 8
test eax, eax
je 0x40be27
push str.Small_Business
push esi
call fcn.005064b6
add esp, 8
test eax, eax
je 0x40be27
push str.Enterprise
push esi
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40be0c
or dword [edi + 0x130], 2
jmp 0x40be2e
push str.Personal
push esi
call fcn.005064b6
add esp, 8
test eax, eax
jne 0x40be2e
or dword [edi + 0x130], 0x40
jmp 0x40be2e
or dword [edi + 0x130], 1
push esi
call ebx
cmp byte [esi + eax + 1], 0
lea esi, [esi + eax + 1]
jne 0x40bdb2
pop ebx
push ebp
call fcn.00412bf2
add esp, 4
pop ebp
mov edx, dword [esp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
pop edi
add esp, 0xc
ret 4