joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4024f0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
movsx eax, byte [0x46f03c]
add eax, 4
mov byte [0x46f03c], al
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov dword [ebp - 4], eax
movsx edx, byte [0x46f03c]
add edx, 4
mov byte [0x46f03c], dl
cmp dword [ebp - 4], 0xffffffff
je 0x402530
mov eax, dword [ebp + 8]
movsx ecx, byte [eax]
test ecx, ecx
jne 0x402534
xor eax, eax
jmp 0x402539
mov eax, 1
mov esp, ebp
pop ebp
ret

Function at 0x402715
Capabilities:
Accept command line arguments
Parse pe header
Terminate process

Disassembly:
push 0x60
push 0x407170
call fcn.00402aa0
mov edi, 0x94
mov eax, edi
call fcn.004037b0
mov dword [ebp - 0x18], esp
mov esi, esp
mov dword [esi], edi
push esi
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov ecx, dword [esi + 0x10]
mov dword [0x46f3c0], ecx
mov eax, dword [esi + 4]
mov dword [0x46f3cc], eax
mov edx, dword [esi + 8]
mov dword [0x46f3d0], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x46f3c4], esi
cmp ecx, 2
je 0x402775
or esi, 0x8000
mov dword [0x46f3c4], esi
shl eax, 8
add eax, edx
mov dword [0x46f3c8], eax
xor esi, esi
push esi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x4027b0
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4027b0
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x4027c8
cmp eax, 0x20b
je 0x4027b5
mov dword [ebp - 0x1c], esi
jmp 0x4027dc
cmp dword [ecx + 0x84], 0xe
jbe 0x4027b0
xor eax, eax
cmp dword [ecx + 0xf8], esi
jmp 0x4027d6
cmp dword [ecx + 0x74], 0xe
jbe 0x4027b0
xor eax, eax
cmp dword [ecx + 0xe8], esi
setne al
mov dword [ebp - 0x1c], eax
push esi
call fcn.00403752
pop ecx
test eax, eax
jne 0x402808
cmp dword [0x46f3ac], 1
jne 0x4027f5
call fcn.00402f07
push 0x1c
call fcn.00402d90
push 0xff
call fcn.00402bf5
pop ecx
pop ecx
call fcn.004036b0
mov dword [ebp - 4], esi
call fcn.00403505
test eax, eax
jge 0x402821
push 0x1b
call fcn.004026f0
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x46f934], eax
call fcn.004033e3
mov dword [0x46f3a4], eax
call fcn.00403341
test eax, eax
jge 0x402847
push 8
call fcn.004026f0
pop ecx
call fcn.0040310e
test eax, eax
jge 0x402858
push 9
call fcn.004026f0
pop ecx
push 1
call fcn.00402c25
pop ecx
mov dword [ebp - 0x28], eax
cmp eax, esi
je 0x40286e
push eax
call fcn.004026f0
pop ecx
mov dword [ebp - 0x44], esi
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
call fcn.004030b1
mov dword [ebp - 0x20], eax
test byte [ebp - 0x44], 1
je 0x40288f
movzx eax, word [ebp - 0x40]
jmp 0x402892
push 0xa
pop eax
push eax
push dword [ebp - 0x20]
push esi
push esi
call edi
push eax
call fcn.004014a0
mov edi, eax
mov dword [ebp - 0x2c], edi
cmp dword [ebp - 0x1c], esi
jne 0x4028b0
push edi
call fcn.00402d50
call fcn.00402d72
jmp 0x4028e2
or dword [ebp - 4], 0xffffffff
mov eax, edi
lea esp, [ebp - 0x7c]
call fcn.00402adb
ret
Function at 0x402c8f
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push esi
xor esi, esi
inc esi
cmp dword [0x46f400], esi
push edi
jne 0x402caf
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
cmp dword [ebp + 0xc], 0
mov al, byte [ebp + 0x10]
mov dword [0x46f3fc], esi
mov byte [0x46f3f8], al
jne 0x402d15
mov ecx, dword [0x46f928]
test ecx, ecx
je 0x402cf6
mov eax, dword [0x46f924]
sub eax, 4
cmp eax, ecx
jmp 0x402cef
mov eax, dword [eax]
test eax, eax
je 0x402ce1
call eax
mov eax, dword [0x46f924]
sub eax, 4
cmp eax, dword [0x46f928]
mov dword [0x46f924], eax
jae 0x402cd9
mov eax, 0x40901c
mov esi, 0x409020
cmp eax, esi
mov edi, eax
jae 0x402d15
mov eax, dword [edi]
test eax, eax
je 0x402d0e
call eax
add edi, 4
cmp edi, esi
jb 0x402d06
mov eax, 0x409024
mov esi, 0x409028
cmp eax, esi
mov edi, eax
jae 0x402d34
mov eax, dword [edi]
test eax, eax
je 0x402d2d
call eax
add edi, 4
cmp edi, esi
jb 0x402d25
cmp dword [ebp + 0x10], 0
pop edi
pop esi
jne 0x402d4e
push dword [ebp + 8]
mov dword [0x46f400], 1
call fcn.00402bf5
pop ebp
ret

Function at 0x402d90
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x46f120]
mov ecx, dword [ebp + 0x94]
push ebx
push esi
mov dword [ebp + 0x88], eax
xor edx, edx
push edi
xor eax, eax
cmp ecx, dword [eax*8 + 0x46f138]
je 0x402dc5
inc eax
cmp eax, 0x13
jb 0x402db6
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x46f138]
jne 0x402eeb
mov eax, dword [0x46f3ac]
cmp eax, 1
je 0x402ec3
cmp eax, edx
jne 0x402df5
cmp dword [0x46f134], 1
je 0x402ec3
cmp ecx, 0xfc
je 0x402eeb
push 0x104
lea eax, [ebp - 0x80]
push eax
push edx
mov byte [ebp + 0x84], dl
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x402e2b
lea eax, [ebp - 0x80]
push str._program_name_unknown_
push eax
call fcn.00402590
pop ecx
pop ecx
lea edi, [ebp - 0x80]
mov eax, edi
push eax
call fcn.00403a20
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x402e5f
mov eax, edi
push eax
call fcn.00403a20
mov edi, eax
lea eax, [ebp - 0x80]
sub eax, 0x3b
push 3
add edi, eax
push 0x4071b4
push edi
call fcn.004038f0
add esp, 0x10
push edi
call fcn.00403a20
push dword [esi + 0x46f13c]
mov ebx, eax
call fcn.00403a20
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.004037b0
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.00402590
push edi
push ebx
call fcn.004025a0
push 0x4071b0
push ebx
call fcn.004025a0
push dword [esi + 0x46f13c]
push ebx
call fcn.004025a0
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.004037ed
add esp, 0x2c
jmp 0x402eeb
push edx
lea eax, [ebp + 0x94]
push eax
lea esi, [esi + 0x46f13c]
push dword [esi]
call fcn.00403a20
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea esp, [ebp - 0x8c]
mov ecx, dword [ebp + 0x88]
call fcn.00402581
pop edi
pop esi
pop ebx
add ebp, 0x8c
leave
ret
Function at 0x4037ed
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x46f51c], ebx
push esi
push edi
jne 0x40386d
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x4038a8
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
test eax, eax
mov dword [0x46f51c], eax
je 0x4038a8
push str.GetActiveWindow
push edi
call esi
push str.GetLastActivePopup
push edi
mov dword [0x46f520], eax
call esi
cmp dword [0x46f3c0], 2
mov dword [0x46f524], eax
jne 0x40386d
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x46f52c], eax
je 0x40386d
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x46f528], eax
mov eax, dword [0x46f528]
test eax, eax
je 0x4038b2
call eax
test eax, eax
je 0x403899
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x46f52c]
test eax, eax
je 0x403899
test byte [ebp - 8], 1
jne 0x4038b2
cmp dword [0x46f3cc], 4
jb 0x4038ac
or byte [ebp + 0x12], 0x20
jmp 0x4038d1
xor eax, eax
jmp 0x4038e1
or byte [ebp + 0x12], 4
jmp 0x4038d1
mov eax, dword [0x46f520]
test eax, eax
je 0x4038d1
call eax
mov ebx, eax
test ebx, ebx
je 0x4038d1
mov eax, dword [0x46f524]
test eax, eax
je 0x4038d1
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x46f51c]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x403b9a
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
mov esi, dword [ebp + 8]
mov ebx, dword [esi + 8]
test bl, 3
jne 0x403bc8
mov eax, dword fs:[0x18]
mov dword [ebp + 8], eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 8]
cmp ebx, ecx
mov dword [ebp - 4], ecx
jb 0x403bcf
cmp ebx, dword [eax + 4]
jae 0x403bcf
xor eax, eax
jmp 0x403dbf
push edi
mov edi, dword [esi + 0xc]
cmp edi, 0xffffffff
jne 0x403be0
xor eax, eax
inc eax
jmp 0x403dbe
xor edx, edx
mov dword [ebp + 8], edx
mov eax, ebx
mov ecx, dword [eax]
cmp ecx, 0xffffffff
je 0x403bf6
cmp ecx, edx
jae 0x403d3b
cmp dword [eax + 4], 0
je 0x403bff
inc dword [ebp + 8]
inc edx
add eax, 0xc
cmp edx, edi
jbe 0x403be7
cmp dword [ebp + 8], 0
je 0x403c21
mov eax, dword [esi - 8]
cmp eax, dword [ebp - 4]
jb 0x403d3b
cmp eax, esi
jae 0x403d3b
mov eax, dword [0x46f530]
mov edi, ebx
and edi, 0xfffff000
xor esi, esi
test eax, eax
jle 0x403c46
cmp dword [esi*4 + 0x46f538], edi
je 0x403d3f
inc esi
cmp esi, eax
jl 0x403c34
push 0x1c
lea eax, [ebp - 0x20]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x403dbb
cmp dword [ebp - 8], 0x1000000
jne 0x403dbb
test byte [ebp - 0xc], 0xcc
je 0x403cc4
mov ecx, dword [ebp - 0x1c]
cmp word [ecx], 0x5a4d
jne 0x403dbb
mov eax, dword [ecx + 0x3c]
add eax, ecx
cmp dword [eax], 0x4550
jne 0x403dbb
cmp word [eax + 0x18], 0x10b
jne 0x403dbb
sub ebx, ecx
cmp word [eax + 6], 0
movzx ecx, word [eax + 0x14]
lea ecx, [ecx + eax + 0x18]
jbe 0x403dbb
mov eax, dword [ecx + 0xc]
cmp ebx, eax
jb 0x403cc4
mov edx, dword [ecx + 8]
add edx, eax
cmp ebx, edx
jae 0x403cc4
test byte [ecx + 0x27], 0x80
jne 0x403d3b
push 1
push 0x46f578
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test eax, eax
jne 0x403bd8
mov ecx, dword [0x46f530]
test ecx, ecx
mov edx, ecx
jle 0x403cf8
lea eax, [ecx*4 + 0x46f534]
cmp dword [eax], edi
je 0x403cf8
dec edx
sub eax, 4
test edx, edx
jg 0x403cec
test edx, edx
jne 0x403d29
push 0xf
pop ebx
cmp ecx, ebx
jg 0x403d05
mov ebx, ecx
xor edx, edx
test ebx, ebx
jl 0x403d1d
lea eax, [edx*4 + 0x46f538]
mov esi, dword [eax]
inc edx
cmp edx, ebx
mov dword [eax], edi
mov edi, esi
jle 0x403d0b
cmp ecx, 0x10
jge 0x403d29
inc ecx
mov dword [0x46f530], ecx
push 0
push 0x46f578
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
jmp 0x403bd8
xor eax, eax
jmp 0x403dbe
test esi, esi
jle 0x403bd8
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedExchange]
push 1
push 0x46f578
call ebx
test eax, eax
jne 0x403bd8
cmp dword [esi*4 + 0x46f538], edi
je 0x403d95
mov eax, dword [0x46f530]
lea esi, [eax - 1]
test esi, esi
jl 0x403d83
cmp dword [esi*4 + 0x46f538], edi
je 0x403d7f
dec esi
jns 0x403d73
test esi, esi
jge 0x403d93
cmp eax, 0x10
jge 0x403d8e
inc eax
mov dword [0x46f530], eax
lea esi, [eax - 1]
jmp 0x403d95
je 0x403dad
xor ecx, ecx
test esi, esi
jl 0x403dad
lea eax, [ecx*4 + 0x46f538]
mov edx, dword [eax]
inc ecx
cmp ecx, esi
mov dword [eax], edi
mov edi, edx
jle 0x403d9b
push 0
push 0x46f578
call ebx
jmp 0x403bd8
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
Function at 0x405e49
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
push 4
pop eax
call fcn.004037b0
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x405ee4
mov ebx, dword [ebp - 0x24]
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov ecx, dword [ebp - 0x48]
mov eax, dword [0x46f3c0]
lea edi, [ecx - 1]
not edi
and edi, esi
sub edi, ecx
mov esi, eax
dec esi
neg esi
sbb esi, esi
and esi, 0xfffffff1
add esi, 0x11
imul esi, ecx
add esi, ebx
cmp edi, esi
mov dword [ebp - 8], ecx
jb 0x405ee4
cmp eax, 1
je 0x405f05
mov dword [ebp - 4], ebx
mov ebx, 0x1000
push 0x1c
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x405ee4
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x405eb1
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x405ee0
xor eax, eax
inc eax
jmp 0x405f24
cmp edi, eax
jae 0x405ee8
xor eax, eax
jmp 0x405f24
cmp eax, esi
jae 0x405eef
mov dword [ebp - 4], esi
push 4
push ebx
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x46f3c0]
jmp 0x405f08
mov dword [ebp - 4], edi
dec eax
neg eax
sbb eax, eax
and eax, 0x103
lea ecx, [ebp - 0xc]
push ecx
inc eax
push eax
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea esp, [ebp - 0x58]
pop edi
pop esi
pop ebx
leave
ret

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

Disassembly:
pushal
nop
nop
nop
nop
mov eax, section..text
mov ebx, 0x407ef8
nop
mov ecx, 0xe3165f9
nop
nop
nop
nop
nop
test eax, eax
je 0x42e04e
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
cmp eax, ebx
nop
nop
nop
nop
nop
nop
nop
nop
jne 0x42e024
nop
mov eax, section..data
nop
mov ebx, 0x42cd70
nop
mov ecx, 0x29ee1bfe
test eax, eax
nop
nop
nop
nop
nop
nop
nop
je 0x42e084
nop
xor dword [eax], ecx
nop
nop
nop
nop
add eax, 4
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
nop
nop
jne 0x42e06c
nop
nop
nop
popal
nop
nop
nop
nop
jmp 0x401219
Function at 0x41ecb0
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x12000]
push edi
or ebp, 0xffffffff
jmp 0x41ecd2
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x41ecd9
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x41ecc8
mov eax, 1
add ebx, ebx
jne 0x41eceb
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x41ece0
jne 0x41ecfc
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x41ece0
xor ecx, ecx
sub eax, 3
jb 0x41ed10
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x41ed82
mov ebp, eax
add ebx, ebx
jne 0x41ed1b
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x41ed28
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x41ed4c
inc ecx
add ebx, ebx
jne 0x41ed38
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x41ed2d
jne 0x41ed49
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x41ed2d
add ecx, 2
cmp ebp, 0xfffff300
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x41ed6c
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x41ed5d
jmp 0x41ecce
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x41ed6c
add edi, ecx
jmp 0x41ecce
pop esi
mov edi, esi
mov ecx, 0x1b9
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x41ed8a
cmp byte [edi], 7
jne 0x41ed8a
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov eax, ebx
loop 0x41ed8f
lea edi, [esi + 0x1c000]
mov eax, dword [edi]
or eax, eax
je 0x41edfe
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x1e000]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x1e028]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x41edbc
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x1e02c]
or eax, eax
je 0x41edf8
mov dword [ebx], eax
add ebx, 4
jmp 0x41edd9
call dword [esi + 0x1e030]
popal
jmp 0x402625
Function at 0x4024d1
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
xor ebx, ebx
mov esi, ecx
push ebx
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [esi + 0x30], eax
test eax, eax
je 0x402515
push edi
lea eax, [ebp - 4]
push eax
push ebx
push esi
push 0x4020ef
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov edi, eax
test edi, edi
jne 0x402512
push dword [esi + 0x30]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 0x30], ebx
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x402a01
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
cmp byte [0x4174d8], 0
je 0x402a19
mov eax, dword [0x4174dc]
jmp 0x402ae9
push esi
lea eax, [ebp - 4]
xor esi, esi
push eax
push 0x20019
push esi
push str.SoftwarePoliciesMicrosoftSecurity
push reloc.AppVIsvSubsystems32.dll_Ordinal_1
mov dword [ebp - 4], esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x402a68
lea eax, [ebp - 8]
mov dword [ebp - 8], 4
push eax
push 0x4174dc
push esi
push esi
push dword [0x4170fc]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x402a68
cmp dword [ebp - 8], 4
je 0x402ac2
mov eax, dword [ebp - 4]
mov dword [ebp - 4], esi
test eax, eax
je 0x402a79
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 4]
push eax
push 0x20019
push esi
push str.SoftwareMicrosoftSecurity
push reloc.AppVIsvSubsystems32.dll_Ordinal_1
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x402aca
lea eax, [ebp - 8]
mov dword [ebp - 8], 4
push eax
push 0x4174dc
push esi
push esi
push dword [0x4170fc]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x402aca
cmp dword [ebp - 8], 4
jne 0x402aca
mov esi, dword [0x4174dc]
jmp 0x402ad0
mov dword [0x4174dc], esi
cmp dword [ebp - 4], 0
mov byte [0x4174d8], 1
je 0x402ae6
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x402aed
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
lea eax, [ebp - 8]
push eax
push 0x20019
xor ebx, ebx
push ebx
push 0x411b50
push Ordinal_1
mov dword [ebp - 8], ebx
call edi
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
jne 0x402b7f
lea eax, [ebp - 4]
mov dword [ebp - 4], ebx
push eax
push 0x20019
push ebx
push dword [ebp + 8]
push dword [ebp - 8]
call edi
test eax, eax
jne 0x402b75
push 4
pop edi
lea eax, [ebp + 8]
mov dword [ebp + 8], edi
push eax
lea eax, [ebp - 0xc]
push eax
push ebx
push ebx
push str.InsecureQI
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x402b75
cmp dword [ebp + 8], edi
jne 0x402b75
mov edi, dword [ebp - 0xc]
cmp edi, 3
ja 0x402b75
cmp dword [ebp - 4], ebx
je 0x402b81
push dword [ebp - 4]
call esi
jmp 0x402b81
cmp dword [ebp - 4], ebx
je 0x402b7f
push dword [ebp - 4]
call esi
mov edi, ebx
cmp dword [ebp - 8], ebx
je 0x402b8b
push dword [ebp - 8]
call esi
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x40759c
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push 0x424
mov eax, 0x40fb29
call fcn.0040df74
mov eax, dword [ebp + 0xc]
xor ebx, ebx
mov esi, dword [ebp + 8]
mov dword [ebp - 0x420], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x41c], eax
mov dword [ebp - 0x428], ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x42c], ecx
mov dword [ebp - 0x430], ebx
mov dword [ebp - 0x418], ebx
push 0x60
push ebx
push esi
mov byte [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
mov dword [ebp - 0x424], edi
test edi, edi
jne 0x407619
push 2
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
mov dword [ebp - 0x424], eax
test edi, edi
jne 0x407619
call fcn.004015ef
mov esi, eax
jmp 0x4076f0
push dword [ebp - 0x41c]
push dword [ebp - 0x420]
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x40763c
call fcn.004015ef
jmp 0x4076e3
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0x41c], eax
test eax, eax
je 0x407632
push esi
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
mov dword [ebp - 0x420], esi
lea eax, [esi + 1]
cmp eax, esi
jae 0x40766c
mov esi, 0x8007000e
jmp 0x4076e5
push eax
lea ecx, [ebp - 0x418]
mov byte [ebp - 4], 2
call fcn.00404754
jmp 0x407692
cmp dword [ebp - 0x418], 0
mov dword [ebp - 4], 1
je 0x407665
push esi
push dword [ebp - 0x418]
push esi
push dword [ebp - 0x41c]
push ebx
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ecx, eax
test ecx, ecx
je 0x407632
mov eax, dword [ebp - 0x418]
xor edx, edx
push dword [ebp + 0x14]
mov word [eax + ecx*2], dx
lea ecx, [ebp - 0x430]
push dword [ebp - 0x418]
call fcn.00407462
mov esi, eax
test edi, edi
je 0x4076f0
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea eax, [ebp - 0x414]
cmp dword [ebp - 0x418], eax
je 0x407709
lea ecx, [ebp - 0x418]
call fcn.00405446
lea ecx, [ebp - 0x428]
call fcn.00401263
mov eax, esi
call fcn.0040dec5
ret 0x10
Function at 0x408cd1
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov edx, dword [ebp + 0xc]
push ebx
mov ebx, ecx
test edx, edx
jne 0x408ce4
push 0xd
pop eax
jmp 0x408d28
push esi
xor eax, eax
push edi
mov dword [ebp + 0xc], eax
mov esi, eax
mov edi, edx
mov ecx, edi
lea eax, [ecx + 2]
mov dword [ebp - 4], eax
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp + 0xc]
jne 0x408cf7
sub ecx, dword [ebp - 4]
sar ecx, 1
inc ecx
lea edi, [edi + ecx*2]
lea esi, [esi + ecx*2]
cmp ecx, 1
jne 0x408cef
push esi
push edx
push 7
xor eax, eax
push eax
push dword [ebp + 8]
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8

Function at 0x408d2f
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 0xc]
push esi
mov esi, ecx
test edx, edx
jne 0x408d41
push 0xd
pop eax
jmp 0x408d73
mov ecx, edx
push ebx
push edi
xor ebx, ebx
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x408d4a
sub ecx, edi
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push edx
push dword [ebp + 0x10]
push ebx
push dword [ebp + 8]
push dword [esi]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
pop edi
pop ebx
pop esi
pop ebp
ret 0xc

Function at 0x409cb4
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x4132a4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x210]
push edi
mov edi, dword [ebp + 0xc]
push eax
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x210], 0x208
push eax
push 0
push 2
push esi
push 0x4127c0
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegGetValueW]
test eax, eax
jne 0x409d1d
cmp dword [ebp - 0x210], 4
jb 0x409d1d
test edi, edi
lea eax, [ebp - 0x20c]
cmovne esi, edi
push esi
push eax
call fcn.00409dd7
jmp 0x409d1f
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0040d73d
mov esp, ebp
pop ebp
ret 8

Function at 0x409d31
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x4132a4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x210], 0x208
push eax
push 0
push 2
push str.CommonFilesDir
push str.SoftwareMicrosoftWindowsCurrentVersion
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegGetValueW]
test eax, eax
jne 0x409dc4
mov ecx, dword [ebp - 0x210]
cmp ecx, 4
jb 0x409dc4
shr ecx, 1
push 0xffffffffffffffff
cmp word [ebp + ecx*2 - 0x210], 0x5c
sete al
lea eax, [eax*2 + str.Microsoft_SharedOffice16_]
push eax
lea eax, [ebp - 0x20c]
push 0x104
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncat_s]
add esp, 0x10
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.00409dd7
jmp 0x409dc6
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0040d73d
mov esp, ebp
pop ebp
ret 4