joyce8/EMBER2024-capa huggingface dataset:
Function at 0x402d3b
Capabilities:
Delete registry key
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x110
push ebx
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, esi
lea eax, [ebp - 4]
and esi, 0x300
push eax
mov eax, esi
and edi, 1
or al, 9
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004060dd
xor ebx, ebx
cmp eax, ebx
jne 0x402e1e
test byte [ebp + 0x10], 2
je 0x402d9c
push ebx
push ebx
push ebx
lea eax, [ebp - 8]
push ebx
push eax
lea eax, [ebp - 0x110]
mov dword [ebp - 8], ebx
push eax
push ebx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegEnumValueA]
cmp eax, 0x103
jne 0x402e03
lea eax, [ebp - 0x110]
push 0x105
push eax
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
jmp 0x402dd8
test edi, edi
jne 0x402e03
push dword [ebp + 0x10]
lea eax, [ebp - 0x110]
push eax
push dword [ebp - 4]
call fcn.00402d3b
test eax, eax
jne 0x402de1
lea eax, [ebp - 0x110]
push 0x105
push eax
push edi
push dword [ebp - 4]
call ebx
test eax, eax
je 0x402db1
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 3
call fcn.00406663
test eax, eax
jne 0x402e13
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
jmp 0x402e1e
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 0x3eb
jmp 0x402e1e
push 0
push esi
push dword [ebp + 0xc]
push dword [ebp + 8]
call eax
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x403143
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
mov esi, dword [ebp + 0x14]
push edi
mov edi, dword [ebp + 0x10]
mov dword [ebp - 8], esi
test edi, edi
jne 0x403160
mov dword [ebp - 8], 0x8000
and dword [ebp - 4], 0
mov dword [ebp - 0xc], edi
test edi, edi
jne 0x403172
mov dword [ebp - 0xc], 0x42a048
mov eax, dword [ebp + 8]
test eax, eax
jl 0x403187
mov ecx, dword [0x452478]
add ecx, eax
push ecx
call fcn.0040336b
lea eax, [ebp + 0x14]
push 4
push eax
call fcn.00403355
test eax, eax
je 0x403343
test byte [ebp + 0x17], 0x80
je 0x4032ee
mov ebx, dword [sym.imp.KERNEL32.dll_GetTickCount]
call ebx
and dword [0x4149ac], 0
and dword [0x4149a8], 0
and dword [ebp + 0x14], 0x7fffffff
mov dword [ebp - 0x10], eax
mov eax, 0x416030
mov dword [0x414490], 8
mov dword [0x41e038], eax
mov dword [0x41e034], eax
mov eax, dword [ebp + 0x14]
mov dword [0x41e030], 0x41e030
mov dword [ebp + 8], eax
jle 0x40334b
mov esi, 0x4000
cmp dword [ebp + 0x14], esi
jge 0x403200
mov esi, dword [ebp + 0x14]
mov edi, 0x426048
push esi
push edi
call fcn.00403355
test eax, eax
je 0x403343
sub dword [ebp + 0x14], esi
mov dword [0x414480], edi
mov dword [0x414484], esi
mov edi, dword [ebp - 0xc]
mov eax, dword [ebp - 8]
push 0x414480
mov dword [0x414488], edi
mov dword [0x41448c], eax
call fcn.00406788
test eax, eax
mov dword [ebp - 0x14], eax
jl 0x4032e6
mov esi, dword [0x414488]
sub esi, edi
call ebx
test byte [0x4524d4], 1
mov edi, eax
je 0x4032a1
sub eax, dword [ebp - 0x10]
cmp eax, 0xc8
ja 0x40326e
cmp dword [ebp + 0x14], 0
jne 0x4032a1
mov eax, dword [ebp + 8]
push dword [ebp + 8]
sub eax, dword [ebp + 0x14]
push 0x64
push eax
call dword [sym.imp.KERNEL32.dll_MulDiv]
push eax
lea eax, [ebp - 0x54]
push str....__d__
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea eax, [ebp - 0x54]
push eax
push 0
call fcn.00405378
mov dword [ebp - 0x10], edi
test esi, esi
je 0x4032da
cmp dword [ebp + 0x10], 0
jne 0x4032c0
push esi
push dword [ebp - 0xc]
push dword [ebp + 0xc]
call fcn.00405e91
test eax, eax
je 0x4032ea
add dword [ebp - 4], esi
jmp 0x4032ce
mov eax, dword [0x414488]
add dword [ebp - 4], esi
sub dword [ebp - 8], esi
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0x14], 1
jne 0x403223
jmp 0x40334b
cmp dword [ebp + 0x14], 0
jg 0x4031f3
jmp 0x40334b
push 0xfffffffffffffffc
jmp 0x403345
push 0xfffffffffffffffe
jmp 0x403345
test edi, edi
jne 0x403330
cmp dword [ebp + 0x14], edi
jle 0x40334b
mov ebx, dword [ebp - 8]
cmp dword [ebp + 0x14], ebx
mov esi, dword [ebp + 0x14]
jl 0x403304
mov esi, ebx
mov edi, 0x426048
push esi
push edi
call fcn.00403355
test eax, eax
je 0x403343
push esi
push edi
push dword [ebp + 0xc]
call fcn.00405e91
test eax, eax
je 0x4032ea
add dword [ebp - 4], esi
sub dword [ebp + 0x14], esi
cmp dword [ebp + 0x14], 0
jg 0x4032fa
jmp 0x40334b
cmp dword [ebp + 0x14], esi
jge 0x403338
mov esi, dword [ebp + 0x14]
push esi
push edi
call fcn.00403355
test eax, eax
jne 0x403348
push 0xfffffffffffffffd
pop eax
jmp 0x40334e
mov dword [ebp - 4], esi
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x40583e
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, 0x408384
and byte [ebp - 0x1f], 0
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x20]
and dword [ebp - 0x14], 0
and dword [ebp - 4], 0
mov dword [ebp - 8], eax
lea eax, [ebp - 0xc]
push esi
push eax
mov byte [ebp - 0x20], 1
push dword [ebp + 8]
mov word [ebp - 0x1e], 4
mov dword [ebp - 0x10], 0x408374
mov dword [ebp - 0xc], 0xc
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x40588f
xor eax, eax
jmp 0x4058b6
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 0xb7
jne 0x4058b6
lea eax, [ebp - 0x20]
push eax
push 0x80000007
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityA]
test eax, eax
jne 0x40588b
call esi
pop esi
leave
ret 4

Function at 0x4058f0
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
lea eax, [ebp - 0x10]
mov dword [0x448098], 0x44
push eax
xor eax, eax
push 0x448098
push eax
push eax
push 0x4000000
push eax
push eax
push eax
push dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x40592f
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
leave
ret 4

Function at 0x405933
Capabilities:
Create process on windows

Disassembly:
mov eax, dword [esp + 4]
push eax
and dword [eax + 0x24], 0
mov dword [eax], 0x3c
call dword [sym.imp.SHELL32.dll_ShellExecuteExA]
ret 4

Function at 0x4059d1
Capabilities:
Delete directory
Delete file
Set file attributes

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
push esi
call fcn.00405dc5
mov edi, eax
cmp edi, 0xffffffff
je 0x405a12
test byte [esp + 0x10], 1
push esi
je 0x4059f4
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
jmp 0x4059fa
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
je 0x405a03
xor eax, eax
inc eax
jmp 0x405a14
test byte [esp + 0x10], 4
jne 0x405a12
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
xor eax, eax
pop edi
pop esi
ret 8
Function at 0x405a19
Capabilities:
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14c
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
mov eax, ebx
and eax, 4
push edi
mov dword [ebp - 4], eax
call fcn.00405cd7
test bl, 8
mov dword [ebp - 0xc], eax
je 0x405a58
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
neg eax
sbb eax, eax
inc eax
add dword [0x4524a8], eax
jmp 0x405be2
mov dword [ebp + 8], ebx
and dword [ebp + 8], 1
je 0x405a72
test eax, eax
je 0x405b90
test bl, 2
je 0x405b90
mov esi, 0x444098
push edi
push esi
call fcn.00406257
cmp dword [ebp + 8], 0
je 0x405a91
push str..
push esi
call sub.KERNEL32.dll_lstrcatA
jmp 0x405a97
push edi
call fcn.00405c30
cmp byte [edi], 0
jne 0x405aa5
cmp byte [0x444098], 0x5c
jne 0x405ab0
push 0x40a014
push edi
call sub.KERNEL32.dll_lstrcatA
push edi
call sub.KERNEL32.dll_lstrlenA
mov ebx, eax
lea eax, [ebp - 0x14c]
push eax
push esi
add ebx, edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
mov dword [ebp - 8], eax
je 0x405b86
lea eax, [ebp - 0x120]
push 0x3f
push eax
lea esi, [ebp - 0x120]
call fcn.00405c14
cmp byte [eax], 0
je 0x405af6
cmp byte [ebp - 0x1c], 0
je 0x405af6
lea esi, [ebp - 0x1c]
cmp byte [esi], 0x2e
jne 0x405b0c
mov al, byte [esi + 1]
test al, al
je 0x405b65
cmp al, 0x2e
jne 0x405b0c
cmp byte [esi + 2], 0
je 0x405b65
push esi
push ebx
call fcn.00406257
test byte [ebp - 0x14c], 0x10
je 0x405b31
mov eax, dword [ebp + 0xc]
and eax, 3
cmp al, 3
jne 0x405b65
push dword [ebp + 0xc]
push edi
call fcn.00405a19
jmp 0x405b65
push dword [ebp - 4]
push edi
call fcn.004059d1
test eax, eax
jne 0x405b5d
cmp dword [ebp - 4], eax
je 0x405b55
push edi
push 0xfffffffffffffff1
call fcn.00405378
push 0
push edi
call fcn.00406030
jmp 0x405b65
inc dword [0x4524a8]
jmp 0x405b65
push edi
push 0xfffffffffffffff2
call fcn.00405378
lea eax, [ebp - 0x14c]
push eax
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x405ad4
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [ebp + 8], 0
je 0x405b90
and byte [ebx - 1], 0
xor esi, esi
cmp dword [ebp + 8], esi
je 0x405be2
cmp dword [ebp - 0xc], esi
jne 0x405ba4
inc dword [0x4524a8]
jmp 0x405be2
push edi
call fcn.004065ce
test eax, eax
je 0x405be2
push edi
call fcn.00405be9
mov eax, dword [ebp - 4]
or al, 1
push eax
push edi
call fcn.004059d1
test eax, eax
jne 0x405bda
cmp dword [ebp - 4], esi
je 0x405b9c
push edi
push 0xfffffffffffffff1
call fcn.00405378
push esi
push edi
call fcn.00406030
jmp 0x405be2
push edi
push 0xffffffffffffffe5
call fcn.00405378
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x405cd7
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
push dword [esp + 0xc]
mov esi, 0x446098
push esi
call fcn.00406257
push esi
call fcn.00405c82
mov edi, eax
test edi, edi
jne 0x405cf8
xor eax, eax
jmp 0x405d4a
push edi
call fcn.00406535
test byte [0x452438], 0x80
je 0x405d11
mov al, byte [edi]
test al, al
je 0x405cf4
cmp al, 0x5c
je 0x405cf4
sub edi, esi
jmp 0x405d29
call fcn.004065ce
test eax, eax
je 0x405d23
test byte [eax], 0x10
je 0x405cf4
push esi
call fcn.00405c30
push esi
call sub.KERNEL32.dll_lstrlenA
cmp eax, edi
push esi
jg 0x405d15
call fcn.00405be9
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
pop edi
pop esi
ret 4

Function at 0x405dc5
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
push esi
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov esi, eax
cmp esi, 0xffffffff
je 0x405de4
and al, 0xfe
push eax
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov eax, esi
pop esi
ret 4

Function at 0x405dea
Capabilities:
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ecx, eax
push 0
inc ecx
neg ecx
sbb ecx, ecx
and ecx, eax
push ecx
push dword [esp + 0x14]
push 0
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
ret 0xc

Function at 0x405e19
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
push 0x64
pop edi
mov eax, dword [0x40a3d4]
dec edi
mov dword [ebp + 8], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x1a
xor edx, edx
pop ecx
div ecx
push esi
lea eax, [ebp + 8]
push 0
push eax
push dword [ebp + 0xc]
add byte [ebp + 0xa], dl
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
jne 0x405e5e
test edi, edi
jne 0x405e24
and byte [esi], 0
pop edi
pop esi
pop ebp
ret 8
mov eax, esi
jmp 0x405e58
Function at 0x405ec0
Capabilities:
Get file size

Disassembly:
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
push ebp
push esi
mov esi, dword [esp + 0x14]
push edi
test esi, esi
mov dword [0x448620], 0x4c554e
mov edi, 0x400
mov ebp, 0x448620
je 0x405f0c
push 1
push 0
push esi
call fcn.00405dea
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebp
push esi
call ebx
test eax, eax
je 0x40602b
cmp eax, edi
jg 0x40602b
mov esi, 0x448a20
push edi
push esi
push dword [esp + 0x1c]
call ebx
test eax, eax
je 0x40602b
cmp eax, edi
jg 0x40602b
push esi
push ebp
push str._s_s_r_n
push 0x448220
call dword [sym.imp.USER32.dll_wsprintfA]
mov ebx, eax
mov eax, dword [0x452430]
add esp, 0x10
push dword [eax + 0x128]
push esi
call fcn.004062ea
push 4
push 0xc0000000
push esi
call fcn.00405dea
mov ebp, eax
cmp ebp, 0xffffffff
mov dword [esp + 0x18], ebp
je 0x40602b
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea eax, [edi + ebx + 0xa]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x406024
push edi
push esi
push ebp
call fcn.00405e62
test eax, eax
je 0x406024
push str._Rename__r_n
push esi
call fcn.00405d4f
test eax, eax
jne 0x405fc2
lea eax, [esi + edi]
push str._Rename__r_n
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
add edi, 0xa
jmp 0x405ff7
add eax, 0xa
push 0x40a3d8
push eax
call fcn.00405d4f
mov ebp, eax
test ebp, ebp
je 0x405ff3
lea ecx, [esi + edi]
lea eax, [ecx + ebx]
jmp 0x405fe4
mov dl, byte [ecx]
mov byte [eax], dl
dec eax
dec ecx
cmp ecx, ebp
ja 0x405fde
sub ebp, esi
inc ebp
mov eax, ebp
mov ebp, dword [esp + 0x18]
jmp 0x405ff9
mov ebp, dword [esp + 0x18]
mov eax, edi
push ebx
add eax, esi
push 0x448220
push eax
call fcn.00405da5
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
add edi, ebx
push edi
push esi
push ebp
call fcn.00405e91
push esi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x406030
Capabilities:
Move file

Disassembly:
push 5
push dword [esp + 0xc]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
test eax, eax
jne 0x406053
push dword [esp + 8]
push dword [esp + 8]
call fcn.00405ec0
pop ecx
pop ecx
inc dword [0x4524b0]
ret 8

Function at 0x40613e
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
lea eax, [ebp + 0x18]
push esi
push eax
mov eax, dword [ebp + 0x18]
neg eax
sbb eax, eax
mov dword [ebp - 4], 0x2000
and eax, 0x100
or eax, 0x20019
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004060dd
mov esi, dword [ebp + 0x14]
test eax, eax
jne 0x4061ad
lea eax, [ebp - 4]
push edi
push eax
lea eax, [ebp + 0xc]
push esi
push eax
push 0
push dword [ebp + 0x10]
push dword [ebp + 0x18]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp + 0x18]
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
and byte [esi + 0x1fff], 0
test edi, edi
pop edi
jne 0x4061ad
cmp dword [ebp + 0xc], 1
je 0x4061b0
cmp dword [ebp + 0xc], 2
je 0x4061b0
and byte [esi], 0
pop esi
leave
ret 0x14
Function at 0x4065f5
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x120
push esi
mov esi, 0x104
lea eax, [ebp - 0x120]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
cmp eax, esi
pop esi
jbe 0x406619
xor eax, eax
test eax, eax
je 0x40662b
cmp byte [ebp + eax - 0x121], 0x5c
je 0x40662b
xor ecx, ecx
jmp 0x40662e
xor ecx, ecx
inc ecx
push dword [ebp + 8]
lea ecx, [ecx + 0x40a014]
lea eax, [ebp + eax - 0x120]
push ecx
push str._s_s.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
lea eax, [ebp - 0x120]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
leave
ret 4

Function at 0x40671a
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x448e24], 0
push esi
jne 0x406751
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x40672b
mov dword [ecx*4 + 0x448e20], eax
inc ecx
cmp ecx, 0x100
jl 0x406726
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x406782
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x448e20]
xor eax, esi
inc ecx
dec edx
jne 0x406764
pop edi
not eax
pop esi
ret 0xc
Function at 0x100598f
Capabilities:
Query environment variable

Disassembly:
push 0x14
mov eax, 0x10207f5
call fcn.01013512
xor ebx, ebx
lea ecx, [ebp - 0x20]
mov byte [ebp - 0xd], 1
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x1c], ebx
call fcn.01011f6f
mov dword [ebp - 4], ebx
mov edi, 0x80004005
cmp dword [ebp + 8], ebx
jne 0x10059cb
mov dword [ebp + 8], 0x80070057
jmp 0x1005b07
mov ecx, dword [ebp + 0xc]
call sub.MFC42u.dll_CString::Empty
push 0x1025788
xor ecx, ecx
push 2
pop edx
mov eax, 0x411
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0101363f
pop ecx
pop ecx
mov dword [ebp - 0x18], eax
cmp eax, ebx
jne 0x1005a06
mov dword [ebp + 8], 0x8007000e
jmp 0x1005b07
mov esi, 0x410
push esi
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
cmp eax, ebx
je 0x1005b04
cmp eax, esi
ja 0x1005b04
lea eax, [ebp - 0x1c]
push eax
push ebx
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.SHELL32.dll_SHEvaluateSystemCommandTemplate]
cmp eax, ebx
mov dword [ebp + 8], eax
jl 0x1005b04
cmp byte [ebp + 0x14], bl
je 0x1005ac6
push 0x822
push ebx
push dword [ebp - 0x18]
call sub.msvcrt.dll_memset
add esp, 0xc
push dword [ebp - 0x14]
push esi
push dword [ebp - 0x18]
call fcn.010054db
cmp eax, ebx
mov dword [ebp + 8], eax
jl 0x1005b07
push dword [ebp - 0x18]
call dword [sym.imp.msvcrt.dll__wcslwr]
pop ecx
test eax, eax
je 0x1005b04
push 0x1001c84
push dword [ebp - 0x18]
call dword [sym.imp.msvcrt.dll_wcsstr]
pop ecx
pop ecx
test eax, eax
je 0x1005ac6
cmp dword [ebp - 0x1c], ebx
je 0x1005ac6
cmp dword [ebp - 0x14], ebx
je 0x1005aaf
push dword [ebp - 0x14]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov dword [ebp - 0x14], ebx
mov byte [ebp - 0xd], bl
push 0x1001c80
push dword [ebp - 0x1c]
call dword [sym.imp.msvcrt.dll_wcstok]
pop ecx
pop ecx
mov dword [ebp - 0x14], eax
cmp eax, ebx
je 0x1005b04
push ebx
push dword [ebp - 0x14]
lea ecx, [ebp - 0x20]
call fcn.010124eb
test eax, eax
jl 0x1005b07
lea ecx, [ebp - 0x20]
cmp byte [ebp + 0x10], bl
jne 0x1005ae5
call fcn.01011f88
jmp 0x1005aea
call fcn.01011f9c
mov ecx, dword [ebp + 0xc]
push eax
call fcn.01012aaa
mov ecx, dword [ebp + 0xc]
mov eax, dword [ecx]
cmp dword [eax - 8], ebx
je 0x1005b07
call sub.MFC42u.dll_CString::TrimLeft
jmp 0x1005b07
mov dword [ebp + 8], edi
mov ecx, dword [ebp + 0xc]
mov eax, dword [ecx]
cmp dword [eax - 8], ebx
jne 0x1005b24
cmp byte [ebp + 0x10], bl
jne 0x1005b24
push 0x7b
call sub.MFC42u.dll_CString::LoadStringW
test eax, eax
jg 0x1005b24
mov dword [ebp + 8], edi
cmp dword [ebp - 0x18], ebx
je 0x1005b32
push dword [ebp - 0x18]
call fcn.0101302e
pop ecx
cmp byte [ebp - 0xd], bl
je 0x1005b45
cmp dword [ebp - 0x14], ebx
je 0x1005b45
push dword [ebp - 0x14]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
cmp dword [ebp - 0x1c], ebx
je 0x1005b53
push dword [ebp - 0x1c]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x20]
call fcn.01011f7a
mov eax, dword [ebp + 8]
call fcn.010135fe
ret 0x10
Function at 0x1007b32
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0x10]
push edi
push esi
lea eax, [ebp - 4]
push eax
xor ebx, ebx
push ebx
push dword [ebp + 0xc]
mov dword [ebp - 4], ebx
push dword [ecx]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp dword [ebp - 4], ebx
jbe 0x1007b9d
cmp dword [ebp - 4], 2
jbe 0x1007b89
cmp dword [ebp - 4], 7
jne 0x1007b9d
mov ecx, dword [edi]
test cl, 1
jne 0x1007b9d
shr ecx, 1
cmp ecx, 2
jb 0x1007b9d
cmp esi, ebx
je 0x1007ba0
cmp word [esi + ecx*2 - 2], bx
jne 0x1007b9d
cmp word [esi + ecx*2 - 4], bx
jmp 0x1007b9b
mov ecx, dword [edi]
test cl, 1
jne 0x1007b9d
cmp esi, ebx
je 0x1007ba0
shr ecx, 1
cmp word [esi + ecx*2 - 2], bx
je 0x1007ba0
push 0xd
pop eax
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x1009cf8
Capabilities:
Enumerate files on windows
Get common file path

Disassembly:
push 0x690
mov eax, 0x1020fad
call fcn.01013585
push 7
xor ebx, ebx
pop eax
mov dword [ebp - 0x684], ecx
mov dword [ebp - 0x698], eax
mov dword [ebp - 0x694], 0x18
mov dword [ebp - 0x690], ebx
mov dword [ebp - 0x678], ebx
push ebx
push eax
lea eax, [ebp - 0x420]
push eax
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x1009f0c
lea eax, [ebp - 0x420]
push eax
lea ecx, [ebp - 0x674]
call sub.MFC42u.dll_CString::CString_1
push 0x5c
lea ecx, [ebp - 0x674]
mov dword [ebp - 4], ebx
call sub.MFC42u.dll_CString::ReverseFind
lea ecx, [ebp - 0x674]
cmp eax, 0xffffffff
je 0x1009f03
push eax
lea eax, [ebp - 0x688]
push eax
call sub.MFC42u.dll_CString::Left
push eax
lea ecx, [ebp - 0x674]
mov byte [ebp - 4], 1
call fcn.01012b16
lea ecx, [ebp - 0x688]
mov byte [ebp - 4], bl
call fcn.01012a9e
mov eax, dword [ebp - 0x674]
mov ecx, eax
movzx eax, word [eax]
cmp ax, bx
je 0x1009dc5
movzx eax, ax
cmp ax, 0x20
jbe 0x1009dc5
inc ecx
inc ecx
movzx eax, word [ecx]
cmp ax, bx
jne 0x1009db5
cmp word [ecx], bx
je 0x1009efd
push 0x1002558
lea ecx, [ebp - 0x68c]
call sub.MFC42u.dll_CString::CString_1
push eax
lea ecx, [ebp - 0x674]
mov byte [ebp - 4], 2
call sub.MFC42u.dll_CString::operator_1
lea ecx, [ebp - 0x68c]
mov byte [ebp - 4], bl
call fcn.01012a9e
lea eax, [ebp - 0x674]
push eax
lea ecx, [ebp - 0x67c]
call sub.MFC42u.dll_CString::CString_2
push 0x100254c
lea ecx, [ebp - 0x680]
mov byte [ebp - 4], 3
call sub.MFC42u.dll_CString::CString_1
push eax
lea ecx, [ebp - 0x67c]
mov byte [ebp - 4], 4
call sub.MFC42u.dll_CString::operator_1
lea ecx, [ebp - 0x680]
mov byte [ebp - 4], 3
call fcn.01012a9e
lea eax, [ebp - 0x670]
push eax
push dword [ebp - 0x67c]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x1009eef
test byte [ebp - 0x670], 2
jne 0x1009ed2
lea eax, [ebp - 0x644]
push 0x1002534
push eax
call dword [sym.imp.msvcrt.dll__wcsicmp]
pop ecx
pop ecx
test eax, eax
je 0x1009ed2
test byte [ebp - 0x670], 0x10
jne 0x1009ed2
push 0x10
call sub.MFC42u.dll_operatornew
pop ecx
mov ecx, eax
mov dword [ebp - 0x69c], ecx
mov byte [ebp - 4], 5
cmp ecx, ebx
je 0x1009ebc
push dword [ebp - 0x674]
lea eax, [ebp - 0x420]
push eax
lea eax, [ebp - 0x644]
push eax
call fcn.01007f14
jmp 0x1009ebe
xor eax, eax
mov byte [ebp - 4], 3
cmp eax, ebx
je 0x1009ed2
mov ecx, dword [ebp - 0x684]
push eax
call fcn.010088e9
lea eax, [ebp - 0x670]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x1009e5f
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
lea ecx, [ebp - 0x67c]
mov byte [ebp - 4], bl
call fcn.01012a9e
lea ecx, [ebp - 0x674]
or dword [ebp - 4], 0xffffffff
call fcn.01012a9e
inc dword [ebp - 0x678]
mov eax, dword [ebp - 0x678]
mov eax, dword [ebp + eax*4 - 0x698]
cmp eax, ebx
jne 0x1009d2e
xor eax, eax
inc eax
call fcn.01013617
ret