joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401ce0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push edi
mov edi, dword [esp + 0x10]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x401cf9
pop edi
pop ebx
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x401d34
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [esp + 0x18]
add eax, esi
and ecx, 0xf
jbe 0x401d30
lea ebx, [ebx]
cmp esi, eax
jae 0x401d34
sub ecx, 1
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x401d20
cmp esi, eax
jb 0x401d3a
pop esi
pop edi
xor eax, eax
pop ebx
ret
mov ax, word [esi]
neg ax
sbb eax, eax
and eax, esi
pop esi
pop edi
pop ebx
ret

Function at 0x401e00
Capabilities:
Enumerate pe sections

Disassembly:
push ecx
mov eax, dword [esp + 0x10]
push ebx
mov ebx, dword [eax + 4]
mov eax, dword [eax]
cmp word [eax + 6], 0
movzx ecx, word [eax + 0x14]
push ebp
push esi
push edi
lea ecx, [ecx + eax + 0x18]
mov dword [esp + 0x10], 0
jbe 0x401ef2
mov ebp, dword [sym.imp.KERNEL32.dll_VirtualAlloc]
lea esi, [ecx + 0xc]
cmp dword [esi + 4], 0
jne 0x401e87
jae 0x401e53
jb 0x401e53
int 0x7c
push ecx
into
fldenv [edx + 0x3a]
add eax, 0x1a65119f
invalid
mov edx, dword [esp + 0x1c]
mov edi, dword [edx + 0x38]
test edi, edi
jle 0x401ed2
mov eax, dword [esi]
push 4
push 0x1000
push edi
add eax, ebx
push eax
call ebp
test eax, eax
je 0x401efd
mov eax, dword [esi]
push edi
add eax, ebx
push 0
push eax
mov dword [esi - 4], eax
call fcn.0041f900
jmp 0x401ecf
jmp 0x401ea0
mov ecx, dword [esi + 4]
mov edx, dword [esi]
push 4
push 0x1000
push ecx
add edx, ebx
push edx
call ebp
test eax, eax
je 0x401efd
mov ecx, dword [esi + 8]
mov eax, dword [esi + 4]
add ecx, dword [esp + 0x18]
mov edi, dword [esi]
push eax
add edi, ebx
push ecx
push edi
call fcn.00423740
mov dword [esi - 4], edi
add esp, 0xc
mov edx, dword [esp + 0x20]
mov ecx, dword [edx]
mov eax, dword [esp + 0x10]
movzx edx, word [ecx + 6]
add eax, 1
add esi, 0x28
cmp eax, edx
mov dword [esp + 0x10], eax
jl 0x401e32
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
pop ecx
ret
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
Function at 0x401fe0
Capabilities:
Enumerate pe sections

Disassembly:
sub esp, 0x18
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x2c]
mov esi, dword [edi]
movzx eax, word [esi + 0x14]
mov edx, dword [edi + 0x30]
mov ecx, dword [eax + esi + 0x20]
sub edx, 1
lea eax, [eax + esi + 0x18]
not edx
and edx, ecx
mov dword [esp + 0x14], ecx
mov ecx, dword [eax + 0x10]
test ecx, ecx
mov dword [esp + 0x18], edx
jne 0x402048
mov ebx, dword [eax + 0x24]
test bl, 0x40
je 0x402041
je 0x40203a
jne 0x40203a
wait
dec esp
mov esi, 0x5903c147
jbe 0x40209d
mov byte [esi - 0x45], ah
mov eax, dword [0x6298fd2e]
sub byte [esi - 0x74f07487], dl
dec ecx
and bl, ch
pop es
mov ecx, dword [edi]
mov ecx, dword [ecx + 0x20]
jmp 0x402048
test bl, bl
jns 0x402048
mov ecx, dword [esi + 0x24]
mov dword [esp + 0x1c], ecx
mov ecx, dword [eax + 0x24]
mov dword [esp + 0x20], ecx
mov dword [esp + 0x24], 0
add eax, 0x28
jmp 0x40207d
mov ecx, dword [edi]
mov esi, 1
cmp word [ecx + 6], si
mov dword [esp + 0x10], esi
jbe 0x40218a
lea ebx, [eax + 0x24]
mov esi, dword [edi + 0x30]
mov ebp, dword [ebx - 0x1c]
mov edi, dword [ebx - 0x14]
in al, dx
sub esi, 1
not esi
and esi, ebp
test edi, edi
jne 0x4020e1
mov eax, dword [ebx]
test al, 0x40
je 0x4020da
jne 0x4020cf
je 0x4020cf
out dx, al
xlatb
cmp esp, dword [ebx - 0x1d]
stosd dword es:[edi], eax
out dx, al
invalid
mov eax, dword [esp + 0x2c]
mov ecx, dword [eax]
mov edi, dword [ecx + 0x20]
jmp 0x4020e1
test al, al
jns 0x4020e1
mov edi, dword [ecx + 0x24]
cmp edx, esi
je 0x402136
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x14]
add eax, ecx
cmp eax, esi
ja 0x402136
jnp 0x40210f
jp 0x40210f
cdq
imul esp, dword [eax - 0x48], 0xf4dcfaa3
and eax, 0xb806e317
aas
add eax, 0x24548b11
sub al, 0x8d
dec esp
and al, 0x14
mov edx, dword [esp + 0x2c]
lea ecx, [esp + 0x14]
call fcn.00401f10
test eax, eax
je 0x4021ab
mov eax, dword [ebx]
mov edx, esi
mov dword [esp + 0x14], ebp
mov dword [esp + 0x18], edx
mov dword [esp + 0x20], eax
jmp 0x402162
mov eax, dword [ebx]
test eax, 0x2000000
je 0x40214f
test dword [esp + 0x20], 0x2000000
je 0x40214f
or dword [esp + 0x20], eax
jmp 0x40215c
or eax, dword [esp + 0x20]
and eax, 0xfdffffff
mov dword [esp + 0x20], eax
sub edi, dword [esp + 0x14]
add edi, ebp
mov ecx, dword [esp + 0x2c]
mov ecx, dword [ecx]
mov eax, dword [esp + 0x10]
movzx esi, word [ecx + 6]
add eax, 1
add ebx, 0x28
cmp eax, esi
mov dword [esp + 0x1c], edi
mov edi, dword [esp + 0x2c]
mov dword [esp + 0x10], eax
jl 0x402095
lea ecx, [esp + 0x14]
mov edx, edi
mov dword [esp + 0x24], 1
call fcn.00401f10
pop edi
neg eax
pop esi
sbb eax, eax
pop ebp
neg eax
pop ebx
add esp, 0x18
ret
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x18
ret
Function at 0x4037e7
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x11c
mov eax, dword [0x4425e0]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 8], 0x800
push ebx
push esi
mov esi, ecx
mov ebx, edx
lea eax, [ebp - 0x11c]
jne 0x403827
push 0x4348e0
push 4
push eax
call fcn.0041ff73
push eax
call fcn.004029b0
add esp, 0x10
jmp 0x403839
push 4
push eax
push 3
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoA]
test eax, eax
je 0x4038a7
push edi
call fcn.0042013c
mov edi, dword [eax]
call fcn.0042013c
and dword [eax], 0
lea eax, [ebp - 0x11c]
push eax
push ebx
push esi
push 0x111
mov esi, 0x112
lea eax, [ebp - 0x118]
push esi
push eax
call fcn.004200e2
add esp, 0x18
mov ebx, eax
call fcn.0042013c
cmp dword [eax], 0
je 0x403887
call fcn.0042013c
push dword [eax]
call fcn.0040377b
pop ecx
jmp 0x40388e
call fcn.0042013c
mov dword [eax], edi
cmp ebx, 0xffffffff
pop edi
je 0x4038a7
cmp ebx, esi
jae 0x4038a7
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
jmp 0x4038a9
xor eax, eax
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.0041e49d
leave
ret
Function at 0x40569b
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 4], ebx
je 0x4056e1
call fcn.0040c683
mov esi, dword [eax + 0xc]
push pe_nt_image_headers32
push dword [ebp + 0xc]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x4056e1
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
mov dword [ebp - 4], eax
je 0x405724
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebx, eax
test ebx, ebx
mov esi, dword [ebp + 8]
mov dword [ebp + 0xc], 1
je 0x40570d
push dword [ebp + 0x10]
mov eax, dword [edi]
push ebx
push esi
mov ecx, edi
call dword [eax + 0x20]
cmp dword [ebp - 4], 0
mov dword [ebp + 0xc], eax
je 0x40570d
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeResource]
cmp dword [esi + 0x4c], 0
je 0x405721
mov ecx, dword [esi + 0x4c]
push dword [ebp + 0x10]
mov eax, dword [ecx]
call dword [eax + 0xa0]
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
leave
ret 0xc

Function at 0x40bd32
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push ebp
push esi
push edi
xor edi, edi
xor ebx, ebx
cmp dword [esp + 0x14], edi
mov ebp, ecx
je 0x40bd75
call fcn.0040c683
mov esi, dword [eax + 0xc]
push pe_nt_image_headers32
push dword [esp + 0x18]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x40bd75
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
test edi, edi
je 0x40bd90
push edi
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebx, eax
push ebx
mov ecx, ebp
call fcn.0040b8e9
test ebx, ebx
mov esi, eax
je 0x40bd8e
test edi, edi
je 0x40bd8e
push edi
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret 4

Function at 0x40eb91
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x40ebbf
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x40ebdd
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.0040eafb
jmp 0x40ebdd
mov eax, dword [esi + 0x14]
test eax, eax
je 0x40ebdd
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
push eax
mov ecx, esi
call fcn.0040eafb
test edi, edi
mov eax, edi
jne 0x40ebc7
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
mov ecx, dword [0x645528]
test ecx, ecx
je 0x40eca0
jmp 0x40eb90
ret 8

Function at 0x41e49d
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x4425e0]
jne 0x41e4a7
repz ret
jmp fcn.00422f58
Function at 0x42550d
Capabilities:
Write file on windows

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
push esi
push edi
xor esi, esi
xor edi, edi
cmp ebx, dword [edi*8 + 0x442d60]
je 0x425528
inc edi
cmp edi, 0x17
jb 0x425519
cmp edi, 0x17
jae 0x4256a8
push ebp
push 3
call fcn.0042c2dd
cmp eax, 1
pop ecx
je 0x425674
push 3
call fcn.0042c2dd
test eax, eax
pop ecx
jne 0x42555c
cmp dword [0x442450], 1
je 0x425674
cmp ebx, 0xfc
je 0x4256a7
push str.Runtime_Error__n_nProgram:
mov ebx, 0x314
push ebx
mov ebp, 0x645d78
push ebp
call fcn.0041ff73
add esp, 0xc
test eax, eax
je 0x425592
push esi
push esi
push esi
push esi
push esi
call fcn.00423aaf
add esp, 0x14
push 0x104
mov esi, 0x645d91
push esi
push 0
mov byte [0x645e95], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4255d6
push str._program_name_unknown_
push 0x2fb
push esi
call fcn.0041ff73
add esp, 0xc
test eax, eax
je 0x4255d6
xor eax, eax
push eax
push eax
push eax
push eax
push eax
call fcn.00423aaf
add esp, 0x14
push esi
call fcn.0041ffe0
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x42561b
push esi
call fcn.0041ffe0
sub esi, 0x3b
add eax, esi
push 3
mov ecx, 0x64608c
push 0x4378b4
sub ecx, eax
push ecx
push eax
call fcn.00421cca
add esp, 0x14
test eax, eax
je 0x42561b
xor esi, esi
push esi
push esi
push esi
push esi
push esi
call fcn.00423aaf
add esp, 0x14
jmp 0x42561d
xor esi, esi
push 0x4378b0
push ebx
push ebp
call fcn.00420207
add esp, 0xc
test eax, eax
je 0x42563d
push esi
push esi
push esi
push esi
push esi
call fcn.00423aaf
add esp, 0x14
push dword [edi*8 + 0x442d64]
push ebx
push ebp
call fcn.00420207
add esp, 0xc
test eax, eax
je 0x42565f
push esi
push esi
push esi
push esi
push esi
call fcn.00423aaf
add esp, 0x14
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebp
call fcn.0042c120
add esp, 0xc
jmp 0x4256a7
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ebp, eax
cmp ebp, esi
je 0x4256a7
cmp ebp, 0xffffffff
je 0x4256a7
push 0
lea eax, [esp + 0x14]
push eax
lea esi, [edi*8 + 0x442d64]
push dword [esi]
call fcn.0041ffe0
pop ecx
push eax
push dword [esi]
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebp
pop edi
pop esi
pop ebx
pop ecx
ret
Function at 0x42c120
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
call fcn.00423136
xor ebx, ebx
cmp dword [0x6462cc], ebx
mov dword [ebp - 8], eax
mov dword [ebp - 4], ebx
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], ebx
jne 0x42c1f6
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x42c2d6
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x438b2c
push edi
call esi
cmp eax, ebx
je 0x42c2d6
push eax
call fcn.004230c8
mov dword [esp], 0x438b1c
push edi
mov dword [0x6462cc], eax
call esi
push eax
call fcn.004230c8
mov dword [esp], 0x438b08
push edi
mov dword [0x6462d0], eax
call esi
push eax
call fcn.004230c8
mov dword [0x6462d4], eax
lea eax, [ebp - 0xc]
push eax
call fcn.0041fa23
test eax, eax
pop ecx
pop ecx
je 0x42c1c4
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.00423aaf
add esp, 0x14
cmp dword [ebp - 0xc], 2
jne 0x42c1f6
push str.GetUserObjectInformationA
push edi
call esi
push eax
call fcn.004230c8
cmp eax, ebx
pop ecx
mov dword [0x6462dc], eax
je 0x42c1f6
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.004230c8
pop ecx
mov dword [0x6462d8], eax
mov eax, dword [0x6462d8]
mov ecx, dword [ebp - 8]
cmp eax, ecx
je 0x42c27b
cmp dword [0x6462dc], ecx
je 0x42c27b
push eax
call fcn.0042313f
push dword [0x6462dc]
mov esi, eax
call fcn.0042313f
cmp esi, ebx
pop ecx
pop ecx
mov edi, eax
je 0x42c27b
cmp edi, ebx
je 0x42c27b
call esi
cmp eax, ebx
je 0x42c248
lea ecx, [ebp - 0x14]
push ecx
push 0xc
lea ecx, [ebp - 0x20]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x42c248
test byte [ebp - 0x18], 1
jne 0x42c27b
lea eax, [ebp - 0x10]
push eax
call fcn.0041fa5a
test eax, eax
pop ecx
je 0x42c263
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.00423aaf
add esp, 0x14
cmp dword [ebp - 0x10], 4
jb 0x42c272
or dword [ebp + 0x10], 0x200000
jmp 0x42c2b6
or dword [ebp + 0x10], 0x40000
jmp 0x42c2b6
mov eax, dword [0x6462d0]
cmp eax, dword [ebp - 8]
je 0x42c2b6
push eax
call fcn.0042313f
cmp eax, ebx
pop ecx
je 0x42c2b6
call eax
cmp eax, ebx
mov dword [ebp - 4], eax
je 0x42c2b6
mov eax, dword [0x6462d4]
cmp eax, dword [ebp - 8]
je 0x42c2b6
push eax
call fcn.0042313f
cmp eax, ebx
pop ecx
je 0x42c2b6
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x6462cc]
call fcn.0042313f
cmp eax, ebx
pop ecx
je 0x42c2d6
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x42c2d8
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x431b24
Capabilities:
Check os version

Disassembly:
push ebp
lea ebp, [esp - 0x78]
sub esp, 0x98
mov eax, dword [0x4425e0]
xor eax, ebp
mov dword [ebp + 0x74], eax
push esi
mov esi, ecx
call fcn.00431ab9
mov eax, 0x400000
push 0x94
mov dword [esi + 8], eax
mov dword [esi + 4], eax
lea eax, [ebp - 0x20]
push 0
push eax
mov dword [esi], 0x3c
mov byte [esi + 0xc], 0
call fcn.0041f900
add esp, 0xc
lea eax, [ebp - 0x20]
push eax
mov dword [ebp - 0x20], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [ebp - 0x10], 2
jne 0x431b73
cmp dword [ebp - 0x1c], 5
jb 0x431b8b
jmp 0x431b87
cmp dword [ebp - 0x10], 1
jne 0x431b8b
cmp dword [ebp - 0x1c], 4
ja 0x431b87
jne 0x431b8b
cmp dword [ebp - 0x18], 0
jbe 0x431b8b
mov byte [esi + 0xc], 1
lea ecx, [esi + 0x18]
mov dword [esi + 0x10], 0x800
mov dword [esi + 0x14], 0x4393a0
call fcn.0043198d
test eax, eax
jge 0x431bac
mov byte [0x646434], 1
mov ecx, dword [ebp + 0x74]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.0041e49d
add ebp, 0x78
leave
ret
Function at 0x100269a
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push edi
mov edi, 0x100121c
push edi
call fcn.0100262f
mov ecx, dword [ebp + 0xc]
mov dword [ecx], eax
test eax, eax
je 0x1002726
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
call esi
push dword [ebp + 8]
mov ebx, eax
call esi
and dword [ebp - 4], 0
add ebx, eax
lea ebx, [ebx + ebx + 4]
push ebx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
push eax
lea ecx, [ebp - 4]
call fcn.01002447
mov esi, dword [ebp - 4]
test esi, esi
jne 0x10026ee
xor eax, eax
jmp 0x1002724
push dword [ebp + 8]
shr ebx, 1
push ebx
push esi
call fcn.0100246b
push 0x1001228
push ebx
push esi
call fcn.010024a5
mov eax, dword [ebp + 0xc]
push dword [eax]
push ebx
push esi
call fcn.010024a5
push esi
push edi
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
xor eax, eax
inc eax
pop esi
pop ebx
pop edi
leave
ret 8
Function at 0x1003334
Capabilities:
Accept command line arguments

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
push edi
xor esi, esi
push esi
push esi
push 1
push esi
mov dword [ebp - 4], esi
mov dword [ebp - 8], esi
call dword [sym.imp.KERNEL32.dll_HeapSetInformation]
push esi
call fcn.0100372f
push 0x52
call dword [sym.imp.USER32.dll_GetSystemMetrics]
or ebx, 0xffffffff
test eax, eax
je 0x100338c
push 0x1001afc
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [ebp - 4], eax
cmp eax, esi
je 0x100338c
push 0x1001aec
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, esi
je 0x100338c
push ebx
call eax
lea eax, [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov edi, eax
cmp edi, esi
je 0x1003460
cmp dword [ebp - 8], 1
jle 0x1003460
mov esi, dword [sym.imp.KERNEL32.dll_CompareStringW]
push ebx
push 0x1001adc
push ebx
push dword [edi + 4]
push 1
push 0x7f
call esi
cmp eax, 2
jne 0x10033e2
xor eax, eax
inc eax
push eax
lea ecx, [ebp - 0x10]
call fcn.010022d7
lea ecx, [ebp - 0x10]
call fcn.0100321f
jmp 0x1003460
push ebx
push 0x1001acc
push ebx
push dword [edi + 4]
push 1
push 0x7f
call esi
cmp eax, 2
jne 0x10033fb
push eax
pop eax
jmp 0x10033cf
push ebx
push 0x1001ab8
push ebx
push dword [edi + 4]
push 1
push 0x7f
call esi
cmp eax, 2
jne 0x1003414
xor eax, eax
jmp 0x10033cf
push ebx
push 0x1001aa4
push ebx
push dword [edi + 4]
push 1
push 0x7f
call esi
cmp eax, 2
jne 0x100342d
push 3
jmp 0x10033f8
push ebx
push 0x1001a7c
push ebx
push dword [edi + 4]
push 1
push 0x7f
call esi
cmp eax, 2
jne 0x1003449
call fcn.01003303
jmp 0x1003460
cmp dword [0x1006138], 0
je 0x1003460
push 0x1001a28
push 0
call fcn.01003510
pop ecx
pop ecx
cmp dword [ebp - 4], 0
je 0x100346f
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
test edi, edi
je 0x100347a
push edi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
pop esi
xor eax, eax
pop ebx
leave
ret 0x10
Function at 0x1003510
Capabilities:
Print debug messages
Query environment variable
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xa0
mov eax, dword [0x1006110]
xor eax, ebp
mov dword [ebp - 4], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x90], eax
mov eax, dword [0x1006138]
movzx ecx, ax
dec ecx
je 0x100354f
dec ecx
je 0x100354a
xor ecx, ecx
cmp dword [ebp + 8], 1
sete cl
jmp 0x1003558
xor ecx, ecx
inc ecx
jmp 0x1003558
xor ecx, ecx
cmp dword [ebp + 8], 2
setne cl
push esi
mov esi, eax
and eax, 0x10000
and esi, 0x20000
mov dword [ebp - 0x84], eax
test ecx, ecx
je 0x1003711
push 0x1000
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x80], eax
test eax, eax
je 0x1003711
push ebx
push edi
lea eax, [ebp - 0xa0]
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
movzx eax, word [ebp - 0x92]
push eax
movzx eax, word [ebp - 0x94]
push eax
movzx eax, word [ebp - 0x96]
push eax
movzx eax, word [ebp - 0x98]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push 0x1001b10
lea eax, [ebp - 0x7c]
push 0x3c
push eax
call fcn.010024ff
mov edi, dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
add esp, 0x24
test esi, esi
je 0x10035ec
lea eax, [ebp - 0x7c]
push eax
call edi
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0xc]
push 0x800
push dword [ebp - 0x80]
call fcn.010034d4
mov ebx, 0x1001b54
test esi, esi
je 0x1003611
push dword [ebp - 0x80]
call edi
push ebx
call edi
cmp dword [ebp - 0x84], 0
je 0x1003706
push 0x208
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
xor edi, edi
mov dword [ebp - 0x84], eax
cmp eax, edi
je 0x1003706
mov esi, 0x104
push esi
push eax
push str._SystemRoot_DebugUserModegpsvc.log
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
cmp eax, edi
je 0x10036fa
cmp eax, esi
ja 0x10036fa
push edi
push 0x80
push 4
push edi
push 1
push 6
push dword [ebp - 0x84]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x88], eax
cmp eax, 0xffffffff
je 0x10036fa
push 2
push edi
push edi
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
je 0x10036ee
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
push edi
lea eax, [ebp - 0x8c]
push eax
lea eax, [ebp - 0x7c]
push eax
call esi
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
add eax, eax
push eax
lea eax, [ebp - 0x7c]
push eax
push dword [ebp - 0x88]
call edi
push 0
lea eax, [ebp - 0x8c]
push eax
push dword [ebp - 0x80]
call esi
add eax, eax
push eax
push dword [ebp - 0x80]
push dword [ebp - 0x88]
call edi
push 0
lea eax, [ebp - 0x8c]
push eax
push ebx
call esi
add eax, eax
push eax
push ebx
push dword [ebp - 0x88]
call edi
push dword [ebp - 0x88]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x84]
call dword [sym.imp.KERNEL32.dll_LocalFree]
push dword [ebp - 0x80]
call dword [sym.imp.KERNEL32.dll_LocalFree]
pop edi
pop ebx
push dword [ebp - 0x90]
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.01004780
leave
ret
Function at 0x100372f
Capabilities:
Move file
Query environment variable
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x650
mov eax, dword [0x1006110]
xor eax, ebp
mov dword [ebp - 4], eax
and dword [0x1006138], 0
push ebx
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
push edi
lea eax, [ebp - 0x620]
push eax
mov ebx, 0x20019
push ebx
push 0
push 0x1001c58
mov edi, 0x80000002
push edi
call esi
mov dword [ebp - 0x62c], eax
test eax, eax
jne 0x10037b6
lea eax, [ebp - 0x624]
push eax
push 0x1006138
lea eax, [ebp - 0x628]
push eax
push 0
push 0x1001c34
push dword [ebp - 0x620]
mov dword [ebp - 0x624], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 0x620]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [ebp - 0x62c], 2
jne 0x1003811
lea eax, [ebp - 0x620]
push eax
push ebx
push 0
push 0x1001300
push edi
call esi
test eax, eax
jne 0x1003811
lea eax, [ebp - 0x624]
push eax
push 0x1006138
lea eax, [ebp - 0x628]
push eax
push 0
push 0x1001c10
push dword [ebp - 0x620]
mov dword [ebp - 0x624], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 0x620]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x620]
push eax
push ebx
push 0
push 0x1001bb8
push edi
call esi
xor ebx, ebx
test eax, eax
jne 0x1003864
lea eax, [ebp - 0x624]
push eax
push 0x1006138
lea eax, [ebp - 0x628]
push eax
push ebx
push 0x1001c34
push dword [ebp - 0x620]
mov dword [ebp - 0x624], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 0x620]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [0x1006138], ebx
je 0x100393b
cmp dword [ebp + 8], ebx
je 0x100393b
mov edi, dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
mov esi, 0x104
push esi
lea eax, [ebp - 0x61c]
push eax
push str._SystemRoot_DebugUserMode
call edi
cmp eax, ebx
je 0x100393b
cmp eax, esi
ja 0x100393b
push ebx
lea eax, [ebp - 0x61c]
push eax
call fcn.010041c3
push esi
lea eax, [ebp - 0x20c]
push eax
push str._SystemRoot_DebugUserModegpsvc.log
call edi
cmp eax, ebx
je 0x100393b
cmp eax, esi
ja 0x100393b
lea eax, [ebp - 0x650]
push eax
push ebx
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesExW]
test eax, eax
je 0x100393b
cmp dword [ebp - 0x630], 0x4b000
jb 0x100393b
push esi
lea eax, [ebp - 0x414]
push eax
push str._SystemRoot_DebugUserModegpsvc.bak
call edi
cmp eax, ebx
je 0x100393b
cmp eax, esi
ja 0x100393b
push 1
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x100393b
cmp dword [0x1006138], ebx
je 0x100393b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x1001b60
push 2
call fcn.01003510
add esp, 0xc
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.01004780
leave
ret 4