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

Disassembly:
push ebp
mov ebp, esp
push ecx
lea eax, [ebp + 8]
push esi
xor esi, esi
push eax
push 0x20019
push esi
push dword [ebp + 8]
mov dword [ebp - 4], esi
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x100230c
push esi
push esi
push esi
lea eax, [ebp - 4]
push esi
push eax
push esi
push esi
push esi
push esi
push esi
push esi
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyA]
test eax, eax
je 0x1002303
mov dword [ebp - 4], esi
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp - 4]
pop esi
leave
ret 4

Function at 0x1002367
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x1002384
push 0
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
jmp 0x1002387
and eax, 0x10
ret 4

Function at 0x100249d
Capabilities:
Get common file path
Query environment variable
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [ebp + 8]
and dword [ebp - 4], 0
push ebx
push esi
and byte [eax], 0
push edi
mov edi, dword [ebp + 0x10]
cmp byte [edi], 0x23
jne 0x10025b1
movsx eax, byte [edi + 1]
inc edi
push eax
call dword [sym.imp.USER32.dll_CharUpperA]
mov esi, dword [sym.imp.USER32.dll_CharNextA]
push edi
mov bl, al
call esi
push eax
call esi
cmp bl, 0x53
mov edi, eax
je 0x10025a9
cmp bl, 0x57
je 0x100259b
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x10c]
mov ebx, 0x104
push 0x100136c
push eax
mov dword [ebp - 8], ebx
call esi
lea eax, [ebp - 0x10c]
push edi
push eax
call fcn.01005c31
lea eax, [ebp + 0x10]
push eax
push 0x20019
lea eax, [ebp - 0x10c]
push 0
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x10025bb
lea eax, [ebp - 8]
push eax
lea eax, [ebp + 0xc]
push dword [ebp + 8]
push eax
push 0
push 0x10012fc
push dword [ebp + 0x10]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x1002590
cmp dword [ebp + 0xc], 2
jne 0x1002583
lea eax, [ebp - 0x10c]
push ebx
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
test eax, eax
je 0x1002583
lea eax, [ebp - 0x10c]
push eax
push dword [ebp + 8]
call esi
jmp 0x1002589
cmp dword [ebp + 0xc], 1
jne 0x1002590
mov dword [ebp - 4], 1
push dword [ebp + 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x10025bb
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
jmp 0x10025bb
push dword [ebp + 0xc]
push dword [ebp + 8]
jmp 0x10025b5
push dword [ebp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
cmp dword [ebp - 4], 0
jne 0x10025ca
push edi
push dword [ebp + 8]
call fcn.01005c31
push 1
pop eax
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x10025d4
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
xor edi, edi
cmp dword [ebx + 0x7c], edi
mov dword [ebp - 4], edi
mov dword [ebp - 0x10], edi
mov dword [ebp - 8], edi
jle 0x1002718
mov dword [ebp + 8], edi
jmp 0x10025fb
xor edi, edi
mov ecx, dword [ebp + 8]
mov eax, ebx
add eax, dword [ebx + 0x80]
lea esi, [eax + ecx + 0x84]
mov eax, dword [eax + ecx + 0xbc]
lea eax, [eax + ebx + 0x84]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call fcn.0100249d
test eax, eax
je 0x100271f
lea eax, [ebp - 0x18]
push eax
push dword [ebp + 0xc]
call sub.VERSION.dll_GetFileVersionInfoSizeA
cmp eax, edi
mov dword [ebp - 0x14], eax
je 0x10026fc
push eax
push 0x42
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
cmp eax, edi
mov dword [ebp - 4], eax
je 0x100271f
push eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov edi, eax
test edi, edi
je 0x100271f
push edi
push dword [ebp - 0x14]
push dword [ebp - 0x18]
push dword [ebp + 0xc]
call sub.VERSION.dll_GetFileVersionInfoA
test eax, eax
je 0x10026f1
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0xc]
push eax
push 0x10013a0
push edi
call sub.VERSION.dll_VerQueryValueA
test eax, eax
je 0x10026f1
xor edi, edi
cmp dword [ebp - 0x1c], edi
je 0x10026f1
add esi, 0x10
push dword [esi - 0xc]
mov eax, dword [ebp - 0xc]
push dword [esi - 0x10]
push dword [eax + 0xc]
push dword [eax + 8]
call fcn.01002768
push dword [esi]
mov dword [ebp + edi - 0x24], eax
mov eax, dword [ebp - 0xc]
push dword [esi - 4]
push dword [eax + 0xc]
push dword [eax + 8]
call fcn.01002768
mov dword [ebp + edi - 0x2c], eax
add edi, 4
add esi, 0x18
cmp edi, 8
jl 0x100269f
cmp dword [ebp - 0x24], 0
jl 0x10026e5
cmp dword [ebp - 0x2c], 0
jle 0x10026f1
cmp dword [ebp - 0x20], 0
jl 0x1002740
cmp dword [ebp - 0x28], 0
jg 0x1002740
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
jmp 0x1002705
cmp dword [esi], edi
jne 0x100271f
cmp dword [esi + 4], edi
jne 0x100271f
inc dword [ebp - 8]
add dword [ebp + 8], 0x3c
mov eax, dword [ebp - 8]
cmp eax, dword [ebx + 0x7c]
jl 0x10025f9
mov dword [ebp - 0x10], 1
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp - 8]
cmp dword [ebp - 4], 0
mov dword [eax], ecx
je 0x1002736
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [ebp - 0x10]
pop edi
pop esi
pop ebx
leave
ret 0x10
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
jmp 0x100271f
Function at 0x1003a6d
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
push ebx
push esi
xor esi, esi
push 1
cmp dword [ebp + 8], esi
pop ebx
jne 0x1003a89
xor eax, eax
jmp 0x1003b61
push edi
xor eax, eax
lea edi, [ebp - 0x10]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0xc]
push esi
push esi
push 0x20
push esi
push esi
push esi
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x1003b19
push 0xffffffffffffffff
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp + 0xc]
push eax
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
cmp dword [0x100aaa8], esi
mov ecx, dword [ebp + 0xc]
jne 0x1003af3
mov al, byte [0x100b6cc]
test bl, al
je 0x1003af3
test al, 2
jne 0x1003af3
mov eax, ecx
and eax, 0xff000000
cmp eax, 0xaa000000
jne 0x1003af3
mov dword [0x100b6cc], ecx
push ecx
call fcn.01003b67
push dword [ebp - 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call edi
push dword [ebp - 0x10]
call edi
test byte [0x100b6d5], 4
je 0x1003b5e
cmp dword [ebp + 0xc], esi
jge 0x1003b5e
jmp 0x1003b5c
call fcn.010058e2
mov dword [0x100b704], eax
push esi
lea eax, [ebp - 0x210]
push 0x200
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push esi
lea eax, [ebp - 0x210]
push 0x10
push eax
push dword [ebp + 8]
push 0x4c4
push esi
call fcn.01003e44
xor ebx, ebx
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x1003c44
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
push ebx
push esi
push edi
push str.SHELL32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
xor ebx, ebx
cmp edi, ebx
mov dword [ebp - 0x14], edi
je 0x1003d5e
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.SHBrowseForFolder
push edi
call esi
cmp eax, ebx
mov dword [ebp - 8], eax
je 0x1003d4b
push 0xc3
push edi
call esi
cmp eax, ebx
mov dword [ebp - 0x10], eax
je 0x1003d4b
push str.SHGetPathFromIDList
push edi
call esi
cmp eax, ebx
mov dword [ebp - 0xc], eax
je 0x1003d4b
cmp byte [0x100b720], bl
mov esi, 0x100b720
jne 0x1003ce8
push esi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov edi, dword [sym.imp.USER32.dll_CharPrevA]
add eax, esi
push eax
push esi
call edi
cmp byte [eax], 0x5c
mov dword [ebp - 4], eax
jne 0x1003ce8
push eax
push esi
call edi
cmp byte [eax], 0x3a
je 0x1003ce8
mov eax, dword [ebp - 4]
mov byte [eax], bl
mov eax, dword [ebp + 8]
mov edi, dword [ebp + 0x10]
mov dword [ebp - 0x34], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x34]
push eax
mov byte [edi], bl
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x24], 1
mov dword [ebp - 0x20], 0x1003c23
mov dword [ebp - 0x1c], esi
call dword [ebp - 8]
cmp eax, ebx
mov dword [ebp + 8], eax
je 0x1003d39
push esi
push eax
call dword [ebp - 0xc]
cmp byte [0x100b720], bl
je 0x1003d33
push esi
push edi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
push dword [ebp + 8]
call dword [ebp - 0x10]
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
xor eax, eax
cmp byte [edi], bl
setne al
jmp 0x1003d72
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
push ebx
push 0x10
push ebx
push ebx
push 0x4c1
jmp 0x1003d68
push ebx
push 0x10
push ebx
push ebx
push 0x4c2
push dword [ebp + 8]
call fcn.01003e44
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret 0xc

Function at 0x1003fe8
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_FindResourceA]
push edi
push 0xa
xor edi, edi
push dword [ebp + 8]
push edi
call esi
push eax
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
cmp ebx, dword [ebp + 0x10]
ja 0x1004051
cmp dword [ebp + 0xc], edi
je 0x1004051
cmp ebx, edi
je 0x1004031
push 0xa
push dword [ebp + 8]
push edi
call esi
push eax
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
cmp eax, edi
jne 0x1004035
xor eax, eax
jmp 0x1004053
mov edi, dword [ebp + 0xc]
mov ecx, ebx
mov edx, ecx
mov esi, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, ebx
pop edi
pop esi
pop ebx
pop ebp
ret 0xc
Function at 0x10040e8
Capabilities:
Set file attributes

Disassembly:
push ebx
push esi
push edi
mov edi, dword [esp + 0x10]
push 1
pop ebx
push edi
mov esi, ebx
call fcn.01005be1
test eax, eax
jne 0x1004102
mov eax, ebx
jmp 0x1004161
cmp dword [0x100ae7c], 0
jne 0x100414f
test byte [0x100aab8], bl
jne 0x100414f
push 6
push 0
push 0x100301a
mov dword [0x100b0a4], edi
push dword [0x100aa88]
push 0x7d3
push dword [0x100b6dc]
call fcn.01005b0f
sub eax, 6
je 0x100414d
dec eax
je 0x1004167
sub eax, 0x832
jne 0x100414f
mov dword [0x100ae7c], ebx
mov esi, ebx
test esi, esi
je 0x100415f
push 0x80
push edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov eax, esi
pop edi
pop esi
pop ebx
ret 4
xor esi, esi
jmp 0x100414f

Function at 0x100428b
Capabilities:
Create directory

Disassembly:
push ebx
push esi
push edi
mov edi, dword [esp + 0x10]
mov cl, byte [edi]
test cl, cl
je 0x10042ef
mov al, byte [edi + 1]
lea esi, [edi + 1]
xor ebx, ebx
cmp al, 0x3a
jne 0x10042af
cmp byte [edi + 2], 0x5c
jne 0x10042af
lea esi, [edi + 3]
jmp 0x10042be
cmp cl, 0x5c
jne 0x10042be
cmp al, cl
jne 0x10042be
push 2
lea esi, [edi + 2]
pop ebx
mov al, byte [esi]
test al, al
je 0x10042ef
cmp al, 0x5c
jne 0x10042e4
cmp byte [esi - 1], 0x3a
je 0x10042e4
test ebx, ebx
je 0x10042d5
dec ebx
jmp 0x10042e4
and byte [esi], 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov byte [esi], 0x5c
push esi
call dword [sym.imp.USER32.dll_CharNextA]
mov esi, eax
jmp 0x10042be
pop edi
pop esi
pop ebx
ret 4

Function at 0x1004c40
Capabilities:
Check if file exists
Create directory
Delete directory
Delete file
Get common file path
Get file attributes

Disassembly:
sub esp, 0x104
push ebx
push ebp
push esi
mov esi, dword [esp + 0x118]
push edi
xor edi, edi
xor ebp, ebp
mov eax, edi
inc edi
push eax
lea eax, [esp + 0x14]
push 0x10014a8
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
push dword [esp + 0x118]
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [esp + 0x10]
push eax
push esi
call fcn.01005c31
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ebx, dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
cmp eax, 0xffffffff
je 0x1004ca8
cmp edi, 0x190
jl 0x1004c55
jmp 0x1004cbb
xor ebp, ebp
push ebp
push esi
call ebx
test eax, eax
je 0x1004cbb
push 1
pop ebp
mov dword [0x100aaa0], ebp
test ebp, ebp
jne 0x1004ce6
push esi
push ebp
push 0x10014a4
push dword [esp + 0x124]
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
je 0x1004ce6
push 1
pop ebp
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push 0
push esi
call ebx
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x104
ret 8
Function at 0x1004cf5
Capabilities:
Create directory
Delete directory
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x128
push ebx
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
push esi
je 0x1004d82
lea eax, [ebp - 0x128]
push eax
push dword [ebp + 8]
call fcn.01004c40
test eax, eax
je 0x1004ddf
lea eax, [ebp - 0x128]
mov esi, 0x100ae84
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
test byte [0x100b6d4], 0x20
je 0x1004d75
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
movzx eax, word [ebp - 0x24]
sub eax, ebx
je 0x1004d6a
dec eax
je 0x1004d63
dec eax
je 0x1004d5c
dec eax
jne 0x1004d75
push 0x10014cc
jmp 0x1004d6f
push 0x10014c4
jmp 0x1004d6f
push 0x10014bc
jmp 0x1004d6f
push 0x10014b4
push esi
call fcn.01005c31
push 0x10012fc
push esi
call fcn.01005c31
jmp 0x1004d91
push dword [ebp + 8]
mov esi, 0x100ae84
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
push esi
call fcn.010050c7
test eax, eax
jne 0x1004db1
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x1004de7
mov dword [0x100aaa0], 1
push ebx
push dword [ebp + 0x10]
push esi
call fcn.01005166
test eax, eax
je 0x1004dca
push 1
mov dword [0x100b704], ebx
pop eax
jmp 0x1004de1
cmp dword [0x100aaa0], ebx
je 0x1004ddf
push esi
mov dword [0x100aaa0], ebx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
xor eax, eax
pop esi
pop ebx
leave
ret 0xc
call fcn.010058e2
mov dword [0x100b704], eax
jmp 0x1004ddf
Function at 0x10050c7
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push ebp
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
add eax, 0x14
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov esi, eax
xor ebp, ebp
cmp esi, ebp
jne 0x100510d
push ebp
push 0x10
push ebp
push ebp
push 0x4b5
push ebp
call fcn.01003e44
call fcn.010058e2
mov dword [0x100b704], eax
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret 4
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
push 0x10014e4
push esi
call fcn.01005c31
push ebp
push 0x4000080
push 1
push ebp
push ebp
push 0x40000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
cmp edi, 0xffffffff
je 0x10050fa
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x10050fa
test al, 0x10
je 0x10050fa
push 1
mov dword [0x100b704], ebp
pop eax
jmp 0x1005106
Function at 0x1005166
Capabilities:
Get common file path
Get disk information
Set current directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x318
push ebx
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
push esi
push edi
mov dword [ebp - 4], ebx
je 0x1005357
lea eax, [ebp - 0x118]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
push dword [ebp + 8]
mov esi, dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
call esi
test eax, eax
jne 0x10051c0
push ebx
push 0x10
push ebx
push ebx
push 0x4bc
push ebx
call fcn.01003e44
call fcn.010058e2
mov dword [0x100b704], eax
jmp 0x10052e2
lea eax, [ebp - 4]
push eax
push ebx
call fcn.01005f20
mov edi, eax
cmp edi, ebx
jne 0x1005225
push 0x7f
xor eax, eax
pop ecx
lea edi, [ebp - 0x317]
mov byte [ebp - 0x318], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
call fcn.010058e2
mov dword [0x100b704], eax
push ebx
lea eax, [ebp - 0x318]
push 0x200
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push ebx
lea eax, [ebp - 0x318]
push 0x10
push eax
push dword [ebp + 8]
push 0x4b0
jmp 0x100528e
push ebx
lea eax, [ebp - 0x10]
push ebx
push eax
lea eax, [ebp - 0x14]
push eax
push ebx
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
test eax, eax
jne 0x100529f
push 0x7f
lea edi, [ebp - 0x317]
pop ecx
mov byte [ebp - 0x318], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
call fcn.010058e2
mov dword [0x100b704], eax
push ebx
lea eax, [ebp - 0x318]
push 0x200
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push ebx
lea eax, [ebp - 0x318]
push 0x10
push eax
push dword [ebp + 8]
push 0x4f9
push ebx
call fcn.01003e44
lea eax, [ebp - 0x118]
push eax
call esi
jmp 0x10052e2
lea eax, [ebp - 0x118]
push eax
call esi
push 3
lea eax, [ebp - 0xc]
push dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
mov ecx, 0x200
xor eax, eax
cmp dword [ebp - 4], ecx
je 0x10052cc
shl ecx, 1
inc eax
cmp ax, 8
jb 0x10052be
cmp ax, 8
jne 0x10052e6
push ebx
push 0x10
push ebx
push ebx
push 0x4c5
push ebx
call fcn.01003e44
xor eax, eax
jmp 0x100535a
test byte [0x100b6d4], 8
je 0x1005310
test byte [ebp - 0xf], 0x80
je 0x1005310
mov edx, dword [0x100b6d8]
movzx eax, ax
mov ecx, edx
mov eax, dword [eax*4 + 0x100b6e0]
shr ecx, 2
shl eax, 1
add ecx, edx
jmp 0x1005320
mov ecx, dword [0x100b6d8]
movzx eax, ax
mov eax, dword [eax*4 + 0x100b6e0]
mov esi, dword [ebp + 0xc]
and esi, 1
je 0x1005335
test byte [ebp + 0xc], 2
je 0x1005335
lea edx, [ecx + eax]
cmp edx, edi
jmp 0x100533f
cmp esi, ebx
je 0x100533d
cmp eax, edi
jmp 0x100533f
cmp ecx, edi
jbe 0x1005351
lea edx, [ebp - 0xc]
push edx
push ecx
push eax
push dword [ebp + 0x10]
call fcn.010023ea
jmp 0x100535a
mov dword [0x100b704], ebx
push 1
pop eax
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x1005893
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x104
lea eax, [ebp - 0x104]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
jne 0x10058d0
push eax
push 0x10
push eax
push eax
push 0x4f0
push eax
call fcn.01003e44
call fcn.010058e2
mov dword [0x100b704], eax
xor eax, eax
leave
ret
push 2
lea eax, [ebp - 0x104]
push 2
push eax
call fcn.01005166
leave
ret

Function at 0x1005901
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
mov ebx, dword [sym.imp.USER32.dll_wsprintfA]
push esi
push edi
xor edi, edi
lea eax, [ebp - 0x24]
push edi
push 0x10013a8
push eax
mov dword [ebp - 8], 1
mov dword [ebp - 4], edi
call ebx
add esp, 0xc
lea eax, [ebp - 0x24]
push 0xa
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x10059ca
jmp 0x1005944
xor edi, edi
push eax
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
cmp esi, edi
je 0x10059b0
mov eax, dword [esi]
lea edi, [esi + 8]
mov dword [ebp - 0x10], eax
mov eax, dword [esi + 4]
push edi
mov dword [ebp - 0xc], eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea eax, [eax + edi + 1]
push eax
push edi
push dword [ebp - 0xc]
push dword [ebp - 0x10]
call dword [ebp + 8]
test eax, eax
je 0x10059bf
push esi
call dword [sym.imp.KERNEL32.dll_FreeResource]
inc dword [ebp - 4]
lea eax, [ebp - 0x24]
push dword [ebp - 4]
push 0x10013a8
push eax
call ebx
add esp, 0xc
lea eax, [ebp - 0x24]
push 0xa
push eax
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
jne 0x1005942
jmp 0x10059ca
mov dword [0x100b704], 0x80070714
mov dword [ebp - 8], edi
jmp 0x10059ca
and dword [ebp - 8], 0
push esi
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, dword [ebp - 8]
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x1005aaf
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x104
lea eax, [ebp - 0x104]
push 0x100ae84
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
push dword [ebp + 8]
lea eax, [ebp - 0x104]
push eax
call fcn.01005c31
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x1005b02
test al, 0x10
jne 0x1005b02
push 8
lea eax, [ebp - 0x104]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
jmp 0x1005b0b
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
leave
ret 4

Function at 0x1005be1
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x1005bf4
xor eax, eax
jmp 0x1005bfc
not eax
shr eax, 4
and eax, 1
ret 4
Function at 0x1005dd2
Capabilities:
Check os version
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xb0
and dword [ebp - 8], 0
cmp dword [0x100a308], 0xfffffffe
push edi
mov dword [ebp - 0xc], 0xc
jne 0x1005ec4
and dword [0x100a308], 0
lea eax, [ebp - 0xb0]
push eax
mov dword [ebp - 0xb0], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x1005ec4
cmp dword [ebp - 0xa0], 1
jne 0x1005ec4
cmp dword [ebp - 0xac], 4
jne 0x1005ec4
cmp dword [ebp - 0xa8], 0xa
jae 0x1005ec4
push 0x4a
call dword [sym.imp.USER32.dll_GetSystemMetrics]
test eax, eax
je 0x1005ec4
lea eax, [ebp - 4]
push eax
push 0x20019
push 0
push 0x1001500
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x1005ec4
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x10]
push eax
push 0
push 0x10012fc
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp - 4]
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test edi, edi
jne 0x1005ec4
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.01005cc9
test eax, eax
je 0x1005ec4
mov eax, dword [ebp - 8]
and eax, 0x3ff
cmp eax, 1
je 0x1005eba
cmp eax, 0xd
jne 0x1005ec4
mov dword [0x100a308], 1
mov eax, dword [0x100a308]
pop edi
leave
ret

Function at 0x1005ecc
Capabilities:
Get disk size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov ecx, dword [ebp + 8]
xor eax, eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 8], eax
cmp byte [ecx], al
mov dword [ebp - 4], eax
mov dword [ebp - 0x10], eax
je 0x1005f02
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
test eax, eax
jne 0x1005f06
xor eax, eax
jmp 0x1005f1c
mov eax, dword [ebp - 8]
push 0x400
imul eax, dword [ebp - 0xc]
push dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_MulDiv]
leave
ret 4

Function at 0x10071a7
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0xc]
mov eax, esi
shr eax, 2
push edi
mov edi, eax
dec eax
test edi, edi
jle 0x10071e7
lea edi, [eax + 1]
movzx eax, byte [ecx]
inc ecx
xor ebx, ebx
mov bh, byte [ecx]
or eax, ebx
inc ecx
movzx ebx, byte [ecx]
shl ebx, 0x10
or eax, ebx
inc ecx
movzx ebx, byte [ecx]
shl ebx, 0x18
or eax, ebx
inc ecx
xor edx, eax
dec edi
jne 0x10071c5
and esi, 3
xor eax, eax
dec esi
je 0x1007203
dec esi
je 0x10071fc
dec esi
jne 0x1007208
movzx eax, byte [ecx]
shl eax, 0x10
inc ecx
xor ebx, ebx
mov bh, byte [ecx]
or eax, ebx
inc ecx
movzx ecx, byte [ecx]
or eax, ecx
pop edi
pop esi
xor eax, edx
pop ebx
ret 0xc