joyce8/EMBER2024-capa huggingface dataset:
Function at 0x101e49f
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x1026bcc]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 8], 0
push edi
mov edi, dword [ebp + 0xc]
jne 0x101e4c2
xor eax, eax
jmp 0x101e51d
push 0x40
call fcn.0101f4eb
test eax, eax
je 0x101e4be
push esi
mov esi, 0x104
push esi
lea eax, [ebp - 0x210]
push eax
push 0x100509c
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x101e505
cmp eax, esi
ja 0x101e505
push dword [ebp + 8]
lea eax, [ebp - 0x210]
push 8
push eax
push edi
call dword [sym.imp.USER32.dll_WinHelpW]
xor eax, eax
jmp 0x101e51c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push 0x1005050
call fcn.0101fb68
pop ecx
pop ecx
mov eax, esi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop edi
call fcn.0101d957
leave
ret 8

Function at 0x101e531
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x214
mov eax, dword [0x1026bcc]
xor eax, ebp
mov dword [ebp - 4], eax
and dword [ebp - 0x210], 0
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x20c], ax
lea eax, [ebp - 0x20a]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
mov eax, dword [section..data]
mov esi, section..data
mov ebx, 0x1005020
cmp eax, esi
je 0x101e59e
test byte [eax + 0x1c], 2
je 0x101e59e
cmp byte [eax + 0x19], 5
jb 0x101e59e
push ebx
push 0xa
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
lea eax, [ebp - 0x20c]
push eax
xor eax, eax
push eax
push eax
push dword [ebp + 8]
push eax
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
mov dword [ebp - 0x214], eax
test eax, eax
jge 0x101e5ef
mov eax, dword [section..data]
cmp eax, esi
je 0x101e5e6
test byte [eax + 0x1c], 2
je 0x101e5e6
cmp byte [eax + 0x19], 2
jb 0x101e5e6
push dword [ebp - 0x214]
push ebx
push 0xb
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01007024
movzx eax, word [ebp - 0x214]
jmp 0x101e62f
lea eax, [ebp - 0x20c]
push eax
push dword [ebp + 0x10]
push edi
call fcn.01007fc2
mov edi, eax
test edi, edi
jge 0x101e638
mov eax, dword [section..data]
cmp eax, esi
je 0x101e62c
test byte [eax + 0x1c], 2
je 0x101e62c
cmp byte [eax + 0x19], 2
jb 0x101e62c
movzx ecx, di
push ecx
push ebx
push 0xc
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01007024
movzx eax, di
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x101e642
mov dword [ebp - 0x210], 1
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x210]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0101d957
leave
ret 0xc
Function at 0x101e65e
Capabilities:
Get common file path
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x630
mov eax, dword [0x1026bcc]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
xor eax, eax
mov esi, 0x208
push esi
mov word [ebp - 0x41c], ax
xor ebx, ebx
lea eax, [ebp - 0x41a]
push ebx
push eax
call sub.msvcrt.dll_memset
xor eax, eax
push esi
mov word [ebp - 0x210], ax
lea eax, [ebp - 0x20e]
push ebx
push eax
call sub.msvcrt.dll_memset
xor eax, eax
push 0x206
mov word [ebp - 0x624], ax
lea eax, [ebp - 0x622]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0x24
xor eax, eax
mov dword [ebp - 0x630], 0x20a
cmp edi, ebx
je 0x101e86a
push 1
push 1
push 0x10021cc
push 0x80000001
mov word [edi], ax
call fcn.0101fc67
mov esi, eax
cmp esi, ebx
je 0x101e868
lea eax, [ebp - 0x630]
push eax
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x62c]
push eax
push ebx
push 0x1005030
push esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push esi
mov ebx, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, 0x1004fcc
test ebx, ebx
je 0x101e749
cmp ebx, 2
jne 0x101e868
mov dword [ebp - 0x628], 0x1005164
jmp 0x101e7a8
cmp dword [ebp - 0x62c], 1
je 0x101e75f
cmp dword [ebp - 0x62c], 2
jne 0x101e868
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea ecx, [ebp - 0x210]
mov dword [ebp - 0x628], ecx
lea ecx, [eax - 1]
cmp ecx, 0x103
ja 0x101e7a8
cmp word [ebp + eax*2 - 0x212], 0x5c
je 0x101e7a8
push esi
push 0x105
lea eax, [ebp - 0x210]
push eax
call fcn.01007ffc
test eax, eax
jl 0x101e85e
push 0x105
lea eax, [ebp - 0x41c]
push eax
push 5
call fcn.0101e531
test eax, eax
jne 0x101e7d7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x1005128
call fcn.0101fb68
pop ecx
pop ecx
jmp 0x101e868
lea eax, [ebp - 0x41c]
push eax
push dword [ebp + 0xc]
push edi
call fcn.01007fc2
xor ebx, ebx
cmp eax, ebx
jl 0x101e85e
mov eax, dword [ebp - 0x628]
cmp word [eax], 0x5c
je 0x101e807
push esi
push dword [ebp + 0xc]
push edi
call fcn.01007ffc
cmp eax, ebx
jl 0x101e85e
push dword [ebp - 0x628]
push dword [ebp + 0xc]
push edi
call fcn.01007ffc
cmp eax, ebx
jl 0x101e85e
lea eax, [ebp - 0x624]
push eax
push 0x10050f4
push ebx
push ebx
push 0x8005
push ebx
call dword [sym.imp.SHELL32.dll_SHGetFolderPathAndSubDirW]
cmp eax, ebx
jl 0x101e85e
push 0x93d
push 0x10050b0
lea eax, [ebp - 0x624]
push eax
call dword [sym.imp.SHELL32.dll_SHSetLocalizedName]
cmp eax, ebx
jl 0x101e85e
push edi
call fcn.010204e6
xor eax, eax
inc eax
jmp 0x101e86a
movzx eax, ax
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0101d957
leave
ret 8
Function at 0x101f32c
Capabilities:
Check os version

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x120
mov eax, dword [0x1026bcc]
xor eax, ebp
mov dword [ebp - 4], eax
and dword [ebp - 0x120], 0
push ebx
push esi
push edi
push 0x118
lea eax, [ebp - 0x11c]
push 0
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
mov eax, dword [section..data]
mov esi, section..data
push 2
mov edi, 0x1005268
pop ebx
cmp eax, esi
je 0x101f390
test byte [eax + 0x1c], bl
je 0x101f390
cmp byte [eax + 0x19], 5
jb 0x101f390
push edi
push 0xa
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
lea eax, [ebp - 0x120]
push eax
mov dword [ebp - 0x120], 0x11c
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
jne 0x101f3df
mov eax, dword [section..data]
cmp eax, esi
je 0x101f3d8
test byte [eax + 0x1c], bl
je 0x101f3d8
cmp byte [eax + 0x19], bl
jb 0x101f3d8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov eax, dword [section..data]
push edi
push 0xc
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01007024
xor eax, eax
jmp 0x101f48c
cmp dword [ebp - 0x110], ebx
je 0x101f40b
mov eax, dword [section..data]
cmp eax, esi
je 0x101f3d8
test byte [eax + 0x1c], bl
je 0x101f3d8
cmp byte [eax + 0x19], 3
jb 0x101f3d8
push edi
push 0xd
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
jmp 0x101f3d8
cmp dword [ebp - 0x11c], 5
jae 0x101f42d
mov eax, dword [section..data]
cmp eax, esi
je 0x101f3d8
test byte [eax + 0x1c], bl
je 0x101f3d8
cmp byte [eax + 0x19], 3
jb 0x101f3d8
push edi
push 0xe
jmp 0x101f3fe
mov eax, dword [ebp - 8]
test al, 0x40
je 0x101f446
xor eax, eax
cmp byte [ebp - 6], 1
setne al
dec eax
and eax, 0xffffffe0
add eax, 0x40
jmp 0x101f48c
test eax, 0x200
je 0x101f452
xor eax, eax
inc eax
jmp 0x101f48c
test bl, al
je 0x101f45a
push 8
jmp 0x101f48b
test al, al
jns 0x101f462
push 0x10
jmp 0x101f48b
test eax, 0x400
je 0x101f470
mov eax, 0x80
jmp 0x101f48c
cmp byte [ebp - 6], 1
jne 0x101f47a
mov eax, ebx
jmp 0x101f48c
cmp byte [ebp - 6], 3
je 0x101f489
cmp byte [ebp - 6], bl
jne 0x101f3d8
push 4
pop eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0101d957
leave
ret
Function at 0x101f787
Capabilities:
Check os version

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
xor ebx, ebx
mov eax, dword [section..data]
mov esi, section..data
mov edi, 0x1005394
cmp eax, esi
je 0x101f7bf
test byte [eax + 0x1c], 2
je 0x101f7bf
cmp byte [eax + 0x19], 5
jb 0x101f7bf
push edi
push 0x29
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
call dword [sym.imp.KERNEL32.dll_GetVersion]
cmp al, 5
jae 0x101f7d1
push 0x78
pop eax
jmp 0x101f88f
push 0x10053c0
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [ebp - 4], eax
test eax, eax
jne 0x101f81d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov eax, dword [section..data]
cmp eax, esi
je 0x101f88d
test byte [eax + 0x1c], 2
je 0x101f88d
cmp byte [eax + 0x19], 2
jb 0x101f88d
push ebx
push edi
push 0x2a
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01007024
jmp 0x101f88d
push 0x10053d8
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
jne 0x101f850
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov eax, dword [section..data]
cmp eax, esi
je 0x101f884
test byte [eax + 0x1c], 2
je 0x101f884
cmp byte [eax + 0x19], 2
jb 0x101f884
push ebx
push edi
push 0x2b
jmp 0x101f879
push 1
call eax
test eax, eax
jne 0x101f884
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov eax, dword [section..data]
cmp eax, esi
je 0x101f884
test byte [eax + 0x1c], 2
je 0x101f884
cmp byte [eax + 0x19], 2
jb 0x101f884
push ebx
push edi
push 0x2c
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01007024
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret

Function at 0x101fabd
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x10
lea eax, [ebp - 4]
push eax
push 0x20019
push 0
push 0x10051ec
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x101fae8
xor eax, eax
leave
ret
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x10]
push eax
push 0
push 0x1005420
push dword [ebp - 4]
mov dword [ebp - 0xc], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x101fb15
cmp dword [ebp - 0x10], 4
je 0x101fb19
and dword [ebp - 8], 0
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp - 8]
leave
ret
Function at 0x101fb68
Capabilities:
Print debug messages

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x804
mov eax, dword [0x1026bcc]
xor eax, ebp
mov dword [ebp - 4], eax
xor eax, eax
push 0x7fe
push eax
mov word [ebp - 0x804], ax
lea eax, [ebp - 0x802]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
cmp dword [0x102926c], 0
jne 0x101fbb8
call fcn.0101fabd
mov dword [0x1028750], eax
mov dword [0x102926c], 1
cmp dword [0x1028750], 0
jle 0x101fc56
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 8]
lea eax, [ebp - 0x804]
push 0x400
push eax
call fcn.0101fb2c
test eax, eax
jl 0x101fc56
lea eax, [ebp - 0x804]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x101fbea
sub eax, edx
sar eax, 1
mov ecx, 0x3fd
cmp eax, ecx
jae 0x101fc1a
lea eax, [ebp - 0x804]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x101fc0a
sub eax, edx
sar eax, 1
jmp 0x101fc1c
mov eax, ecx
add eax, eax
cmp word [ebp + eax - 0x806], 0xa
je 0x101fc49
push 0xd
pop ecx
mov word [ebp + eax - 0x804], cx
push 0xa
pop ecx
mov word [ebp + eax - 0x802], cx
xor ecx, ecx
mov word [ebp + eax - 0x800], cx
lea eax, [ebp - 0x804]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0101d957
leave
ret

Function at 0x101fd0d
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
xor esi, esi
push edi
mov dword [ebp - 4], 4
mov dword [ebp - 8], esi
mov eax, dword [section..data]
mov edi, section..data
cmp eax, edi
je 0x101fd4f
test byte [eax + 0x1c], 2
je 0x101fd4f
cmp byte [eax + 0x19], 5
jb 0x101fd4f
push 0x1005448
push 0xe
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
lea eax, [ebp - 8]
push eax
push esi
lea eax, [ebp - 4]
push eax
push esi
push dword [ebp + 0xc]
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp + 8]
call esi
mov ebx, eax
test ebx, ebx
je 0x101fd98
mov eax, dword [section..data]
cmp eax, edi
je 0x101fe0f
test byte [eax + 0x1c], 2
je 0x101fe0f
cmp byte [eax + 0x19], 2
jb 0x101fe0f
push ebx
push 0x1005448
push 0xf
jmp 0x101fe04
cmp dword [ebp - 4], 4
je 0x101fdcc
mov eax, dword [section..data]
cmp eax, edi
je 0x101fdc5
test byte [eax + 0x1c], 2
je 0x101fdc5
cmp byte [eax + 0x19], 2
jb 0x101fdc5
push 0x1005448
push 0x10
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
mov ebx, 0x3f1
jmp 0x101fe0f
lea eax, [ebp - 8]
push eax
push dword [ebp + 0x10]
lea eax, [ebp - 4]
push eax
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
call esi
mov ebx, eax
test ebx, ebx
je 0x101fe0f
mov eax, dword [section..data]
cmp eax, edi
je 0x101fe0f
test byte [eax + 0x1c], 2
je 0x101fe0f
cmp byte [eax + 0x19], 2
jb 0x101fe0f
push ebx
push 0x1005448
push 0x11
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01007024
pop edi
pop esi
mov eax, ebx
pop ebx
leave
ret 0xc
Function at 0x102011d
Capabilities:
Get hostname

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
mov eax, dword [0x1026bcc]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
push edi
mov dword [ebp - 0x28], 0x10
mov eax, dword [section..data]
mov edi, section..data
cmp eax, edi
je 0x1020167
test byte [eax + 0x1c], 2
je 0x1020167
cmp byte [eax + 0x19], 5
jb 0x1020167
push 0x100575c
push 0x29
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
test esi, esi
jne 0x1020173
xor eax, eax
inc eax
jmp 0x1020219
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x1020178
sub eax, edx
sar eax, 1
je 0x102016b
mov ecx, esi
mov eax, 0x100576c
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x10201b5
test dx, dx
je 0x10201b1
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x10201b5
add eax, 4
add ecx, 4
test dx, dx
jne 0x102018f
xor eax, eax
jmp 0x10201ba
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x102016b
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_GetComputerNameW]
test eax, eax
jne 0x1020207
mov eax, dword [section..data]
cmp eax, edi
je 0x1020203
test byte [eax + 0x1c], 2
je 0x1020203
cmp byte [eax + 0x19], 2
jb 0x1020203
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov eax, dword [section..data]
push 0x100575c
push 0x2a
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01007024
xor eax, eax
jmp 0x1020219
lea eax, [ebp - 0x24]
push esi
push eax
call dword [sym.imp.msvcrt.dll__wcsicmp]
neg eax
pop ecx
sbb eax, eax
pop ecx
inc eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0101d957
leave
ret 4
Function at 0x102037a
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push edi
mov eax, dword [section..data]
mov edi, section..data
cmp eax, edi
je 0x10203ad
test byte [eax + 0x1c], 2
je 0x10203ad
cmp byte [eax + 0x19], 5
jb 0x10203ad
push 0x100575c
push 0x17
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
push 0x25
push dword [ebp + 8]
call dword [sym.imp.msvcrt.dll_wcschr]
pop ecx
pop ecx
test eax, eax
jne 0x10203fc
push dword [ebp + 8]
call fcn.010202cf
test eax, eax
jne 0x10204dc
mov eax, dword [section..data]
cmp eax, edi
je 0x10203f5
test byte [eax + 0x1c], 2
je 0x10203f5
cmp byte [eax + 0x19], 2
jb 0x10203f5
push 0x100575c
push 0x18
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
xor eax, eax
jmp 0x10204dc
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
push 0
push 0
push dword [ebp + 8]
call esi
mov ebx, eax
test ebx, ebx
jne 0x1020453
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [section..data]
cmp ecx, edi
je 0x10204d8
test byte [ecx + 0x1c], 2
je 0x10204d8
cmp byte [ecx + 0x19], 2
jb 0x10204d8
push eax
push 0x100575c
push 0x19
push dword [ecx + 0x14]
push dword [ecx + 0x10]
call fcn.01007024
jmp 0x10204d8
inc ebx
lea eax, [ebx + ebx]
push eax
call fcn.010207d9
mov dword [ebp - 4], eax
test eax, eax
jne 0x102048d
mov eax, dword [section..data]
cmp eax, edi
je 0x10204d8
test byte [eax + 0x1c], 2
je 0x10204d8
cmp byte [eax + 0x19], 2
jb 0x10204d8
push 0x100575c
push 0x1a
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
jmp 0x10204d8
push ebx
push eax
push dword [ebp + 8]
call esi
test eax, eax
je 0x10204a1
cmp eax, ebx
ja 0x10204a1
mov eax, dword [ebp - 4]
jmp 0x10204da
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [section..data]
cmp ecx, edi
je 0x10204d0
test byte [ecx + 0x1c], 2
je 0x10204d0
cmp byte [ecx + 0x19], 2
jb 0x10204d0
push eax
push 0x100575c
push 0x1b
push dword [ecx + 0x14]
push dword [ecx + 0x10]
call fcn.01007024
push dword [ebp - 4]
call fcn.01020871
xor eax, eax
pop esi
pop ebx
pop edi
leave
ret 4
Function at 0x102088d
Capabilities:
Check os version

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x118
mov eax, dword [0x1026bcc]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov eax, dword [section..data]
mov esi, section..data
mov edi, 0x10057b8
cmp eax, esi
je 0x10208d1
test byte [eax + 0x1c], 2
je 0x10208d1
cmp byte [eax + 0x19], 5
jb 0x10208d1
push edi
push 0xf
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01006ffe
push 0x110
lea eax, [ebp - 0x114]
push 0
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
lea eax, [ebp - 0x118]
push eax
mov dword [ebp - 0x118], 0x114
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
jne 0x1020935
mov eax, dword [section..data]
cmp eax, esi
je 0x1020931
test byte [eax + 0x1c], 2
je 0x1020931
cmp byte [eax + 0x19], 2
jb 0x1020931
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov eax, dword [section..data]
push edi
push 0x10
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01007024
xor eax, eax
jmp 0x102093f
cmp dword [ebp - 0x114], 6
sbb eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0101d957
leave
ret

Function at 0x1020952
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x118
mov eax, dword [0x1026bcc]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
mov dword [ebp - 0x110], eax
lea eax, [ebp - 0x10c]
push eax
push 0x20019
xor esi, esi
push esi
push 0x10057f4
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x1020a27
push edi
lea eax, [ebp - 0x118]
push eax
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x114]
push eax
push esi
push esi
push dword [ebp - 0x10c]
mov edi, 0x104
mov dword [ebp - 0x118], edi
mov dword [ebp - 0x114], 1
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x1020a16
cmp dword [ebp - 0x114], 2
mov byte [ebp - 5], al
lea eax, [ebp - 0x108]
jne 0x1020a00
push edi
push dword [ebp - 0x110]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
dec eax
lea ecx, [edi - 1]
cmp ecx, eax
sbb esi, esi
inc esi
jmp 0x1020a16
push eax
push edi
push dword [ebp - 0x110]
call fcn.01020267
xor ecx, ecx
test eax, eax
setge cl
mov esi, ecx
push dword [ebp - 0x10c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop edi
jmp 0x1020a29
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0101d957
leave
ret 4
Function at 0x10040df
Capabilities:
Set registry value

Disassembly:
mov eax, 0x1006a39
call fcn.010065f4
sub esp, 0x54
push ebx
push esi
push edi
mov dword [ebp - 0x10], esp
push dword [ebp + 0xc]
mov esi, ecx
push 0x1100
mov dword [ebp - 0x18], esi
call fcn.010060ae
xor edi, edi
lea ecx, [esi + 0x60]
mov dword [ebp - 4], edi
mov dword [esi], reloc.MFC42u.DLL_CWndconstCWnd::wndTop
call fcn.0100306a
lea ecx, [esi + 0xa0]
mov byte [ebp - 4], 1
call fcn.01003f04
lea ecx, [esi + 0xe0]
mov byte [ebp - 4], 2
call fcn.01003f65
lea ebx, [esi + 0x120]
mov dword [ebx], edi
lea ecx, [esi + 0x13c]
mov byte [ebp - 4], 4
call fcn.01005fa6
lea eax, [ebp - 0x14]
push eax
push 0x1001a34
lea ecx, [ebp - 0x24]
mov dword [ebp - 0x14], edi
call fcn.01003b5f
mov byte [ebp - 4], 6
call fcn.01005d36
mov ecx, dword [eax + 4]
call fcn.01004c70
mov edi, dword [ebp + 8]
push edi
push ebx
mov byte [ebp - 4], 7
call dword [sym.imp.ATL.DLL_AtlComPtrAssign]
mov eax, dword [edi]
lea ecx, [esi + 0x124]
push ecx
push edi
call dword [eax + 0x14]
xor ebx, ebx
cmp eax, ebx
jge 0x1004152
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x30], 0x1001a0c
mov dword [ebp - 0x2c], 0x2d
lea esi, [ebp - 0x30]
lea edi, [ebp - 0x48]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
push 0x1006e14
lea eax, [ebp - 0x48]
jmp 0x10041c2
mov eax, dword [edi]
lea ecx, [esi + 0x140]
push ecx
push edi
call dword [eax + 0x28]
cmp eax, ebx
jge 0x1004187
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x30], 0x1001a0c
mov dword [ebp - 0x2c], 0x33
lea esi, [ebp - 0x30]
lea edi, [ebp - 0x54]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
push 0x1006e14
lea eax, [ebp - 0x54]
jmp 0x10041c2
mov dword [ebp + 8], ebx
mov dword [ebp - 0x1c], ebx
mov eax, dword [edi]
push ebx
lea ecx, [ebp + 8]
push ecx
push edi
mov byte [ebp - 4], 9
call dword [eax + 0x20]
cmp eax, ebx
jge 0x10041c8
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x30], 0x1001a0c
mov dword [ebp - 0x2c], 0x36
lea esi, [ebp - 0x30]
lea edi, [ebp - 0x60]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
push 0x1006e14
lea eax, [ebp - 0x60]
push eax
call fcn.010066e6
push dword [ebp + 8]
lea ecx, [esi + 0x13c]
call fcn.01005fd6
push dword [ebp + 0xc]
mov ecx, esi
push 0x1100
call fcn.01005fee
cmp dword [ebp + 8], ebx
je 0x1004223
push dword [ebp + 8]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
jmp 0x1004223
mov eax, dword [ebp - 0x14]
lea ecx, [ebp - 0x24]
mov dword [esi + 0x134], eax
mov dword [esi + 0x138], ebx
call fcn.01003b9c
mov ecx, dword [ebp - 0xc]
pop edi
mov eax, esi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret 8