joyce8/EMBER2024-capa huggingface dataset:
Function at 0x404e70
Capabilities:
Get disk information

Disassembly:
sub esp, 0x83c
mov eax, dword [esp + 0x840]
mov edx, dword [eax]
push ebx
push ebp
mov ebp, dword [0x49e768]
push esi
push edi
mov edi, dword [eax + 4]
mov eax, dword [0x49e76c]
xor ebx, ebx
mov dword [esp + 0x34], eax
lea eax, [esp + 0x14]
mov dword [esp + 0x28], edx
mov dword [esp + 0x14], ebx
mov dword [esp + 0x30], 0x9e3779b9
call fcn.00404e40
mov ecx, dword [0x49e770]
mov eax, dword [0x49e774]
add dword [esp + 0x14], 0x23f
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x38], eax
mov dword [esp + 0x2c], 0x20
jmp 0x404ee4
mov edx, dword [esp + 0x28]
mov dword [esp + 0x1c], 2
add dword [esp + 0x1c], 3
mov eax, dword [0x75e7f4]
mov ecx, edx
shl ecx, 4
add ecx, dword [esp + 0x3c]
mov dword [esp + 0x10], ecx
cmp eax, 0xfa9
jne 0x404f16
mov dword [0x75e7f0], 0xedeb2e40
jmp 0x404f23
cmp eax, 0x3eb
jne 0x404f23
mov dword [0x75b6f8], ebx
mov eax, dword [esp + 0x28]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x14]
add dword [esp + 0x20], eax
mov ecx, dword [esp + 0x1c]
shr edx, cl
mov ecx, dword [esp + 0x38]
lea eax, [esp + 0x24]
mov dword [0x75e7ec], 0xf4ea3dee
mov dword [esp + 0x24], edx
call fcn.00404e50
mov eax, dword [esp + 0x20]
xor dword [esp + 0x10], eax
mov esi, dword [esp + 0x24]
xor esi, dword [esp + 0x10]
cmp dword [0x75e7f4], 0x213
jne 0x404fb6
lea edx, [esp + 0x40]
push edx
lea eax, [esp + 0x4c]
push eax
lea ecx, [esp + 0x2c]
push ecx
push ebx
push ebx
push ebx
mov dword [esp + 0x3c], ebx
call dword [sym.imp.KERNEL32.dll_GetWriteWatch]
lea edx, [esp + 0x4c]
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateHardLinkA]
lea eax, [esp + 0x44]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetCompressedFileSizeA]
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteTimerQueueTimer]
sub edi, esi
mov eax, edi
lea ecx, [esp + 0x10]
mov dword [esp + 0x24], edi
call fcn.00404e30
add dword [esp + 0x10], ebp
mov dword [esp + 0x18], ebx
mov eax, dword [esp + 0x14]
add dword [esp + 0x18], eax
mov eax, dword [esp + 0x24]
nop
add dword [esp + 0x18], eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x20], eax
mov esi, edi
shr esi, 5
add esi, dword [esp + 0x34]
mov eax, dword [esp + 0x20]
xor dword [esp + 0x10], eax
cmp dword [0x75e7f4], 0x121
jne 0x40500b
call dword [sym.imp.KERNEL32.dll_GetConsoleAliasExesLengthA]
mov ecx, dword [esp + 0x10]
xor ecx, esi
lea eax, [esp + 0x28]
mov dword [esp + 0x10], ecx
call fcn.00404e60
mov eax, dword [esp + 0x30]
sub dword [esp + 0x14], eax
sub dword [esp + 0x2c], 1
jne 0x404ee0
mov eax, dword [esp + 0x850]
mov ecx, dword [esp + 0x28]
mov dword [eax + 4], edi
pop edi
pop esi
pop ebp
mov dword [eax], ecx
pop ebx
add esp, 0x83c
ret 4
Function at 0x405050
Capabilities:
Delete file
Enumerate gui resources

Disassembly:
mov eax, 0x243c
call fcn.00416950
mov eax, dword [0x75e7f4]
mov ecx, dword [0x75b6fc]
push ebx
push ebp
shr eax, 3
push esi
push edi
test eax, eax
jbe 0x4051db
mov edi, dword [sym.imp.KERNEL32.dll_GetConsoleMode]
mov ebx, dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
mov ebp, dword [sym.imp.KERNEL32.dll_CreateActCtxA]
mov esi, dword [sym.imp.KERNEL32.dll_EnumResourceTypesA]
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], eax
cmp dword [0x75e7f4], 0x959
jne 0x4051c1
push 0
push 0
call edi
push 0
lea eax, [esp + 0x84c]
push eax
push 0x40370c
call ebx
lea ecx, [esp + 0x28]
push ecx
call ebp
lea edx, [esp + 0x1c]
push edx
lea eax, [esp + 0x144c]
push eax
push 0x403724
call dword [sym.imp.KERNEL32.dll_DnsHostnameToComputerNameW]
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WriteProfileSectionW]
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x4c]
push edx
push 0
push 0x40373c
push 0x403778
push 0x4037ec
call dword [sym.imp.KERNEL32.dll_SearchPathW]
push 0
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push 0
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_EnumCalendarInfoExA]
push 0
lea eax, [esp + 0x28]
push eax
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WriteConsoleW]
push 0
push 0
lea ecx, [esp + 0xc50]
push ecx
call dword [sym.imp.KERNEL32.dll_GetConsoleAliasesW]
push 0
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push 0
lea edx, [esp + 0x1c4c]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0
push 0
push 0
call esi
call dword [sym.imp.KERNEL32.dll_DebugBreak]
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetCommState]
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetCommTimeouts]
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetConsoleTitleW]
push 0
push 0
call dword [sym.imp.KERNEL32.dll_BeginUpdateResourceW]
push 0
push 0x40381c
call dword [sym.imp.KERNEL32.dll_IsBadStringPtrW]
push 0
push 0x403824
push 0x40383c
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceExA]
push 0
push 0
push 0
call esi
mov eax, dword [esp + 0x14]
push eax
call fcn.00404e70
add dword [esp + 0x14], 8
sub dword [esp + 0x18], 1
jne 0x405094
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x243c
ret
Function at 0x40917d
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x49d208]
jne 0x409187
repz ret
jmp fcn.00410f9c

Function at 0x414b91
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.0040e648
and dword [ebp - 4], 0
cmp dword [0x4a0a30], 0
mov ebx, eax
jne 0x414c42
push 0x402dd0
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x414cf3
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x402dc4
push edi
call esi
test eax, eax
je 0x414cf3
push eax
call fcn.0040e5d6
mov dword [esp], 0x402db4
push edi
mov dword [0x4a0a30], eax
call esi
push eax
call fcn.0040e5d6
mov dword [esp], 0x402da0
push edi
mov dword [0x4a0a34], eax
call esi
push eax
call fcn.0040e5d6
mov dword [esp], 0x402d84
push edi
mov dword [0x4a0a38], eax
call esi
push eax
call fcn.0040e5d6
pop ecx
mov dword [0x4a0a40], eax
test eax, eax
je 0x414c42
push 0x402d6c
push edi
call esi
push eax
call fcn.0040e5d6
pop ecx
mov dword [0x4a0a3c], eax
mov eax, dword [0x4a0a3c]
cmp eax, ebx
je 0x414c9a
cmp dword [0x4a0a40], ebx
je 0x414c9a
push eax
call fcn.0040e651
push dword [0x4a0a40]
mov esi, eax
call fcn.0040e651
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x414c9a
test edi, edi
je 0x414c9a
call esi
test eax, eax
je 0x414c91
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x414c91
test byte [ebp - 0xc], 1
jne 0x414c9a
or dword [ebp + 0x10], 0x200000
jmp 0x414cd3
mov eax, dword [0x4a0a34]
cmp eax, ebx
je 0x414cd3
push eax
call fcn.0040e651
pop ecx
test eax, eax
je 0x414cd3
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x414cd3
mov eax, dword [0x4a0a38]
cmp eax, ebx
je 0x414cd3
push eax
call fcn.0040e651
pop ecx
test eax, eax
je 0x414cd3
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x4a0a30]
call fcn.0040e651
pop ecx
test eax, eax
je 0x414cf3
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x414cf5
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x403c53
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [0x48ecec]
mov ecx, dword [0x48ec58]
sub esp, 0x40c
push esi
shr eax, 3
xor esi, esi
cmp eax, esi
jbe 0x403ced
push ebx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_WriteConsoleA]
mov ebx, ecx
mov dword [ebp - 4], eax
cmp dword [0x48ecec], 0x5d
jne 0x403cdd
push esi
push esi
call dword [sym.imp.KERNEL32.dll_WriteProfileSectionA]
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
push esi
lea eax, [ebp - 8]
push eax
push esi
push esi
push esi
call edi
push esi
push esi
call dword [sym.imp.KERNEL32.dll_MoveFileW]
push 0x4030c8
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push esi
push esi
push esi
call dword [sym.imp.KERNEL32.dll_SetConsoleWindowInfo]
push esi
lea eax, [ebp - 0xc]
push eax
push esi
lea eax, [ebp - 0x40c]
push eax
push esi
call edi
push esi
push esi
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push esi
push esi
call dword [sym.imp.KERNEL32.dll_GetConsoleTitleA]
push ebx
call fcn.00403415
add ebx, 8
dec dword [ebp - 4]
jne 0x403c7e
pop edi
pop ebx
pop esi
leave
ret
Function at 0x404416
Capabilities:
Manipulate console buffer

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x644
push ebx
push esi
xor esi, esi
cmp dword [0x48ecec], 0xc
push edi
jne 0x404468
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
push 0x403124
push 0x403128
call fcn.004047c4
push esi
call fcn.00404536
add esp, 0xc
lea ecx, [esp + 0x18]
call fcn.0040455e
lea ecx, [esp + 0x18]
call fcn.0040459a
push esi
call fcn.004047db
pop ecx
mov eax, dword [0x44dccc]
mov dword [0x48ecec], eax
mov ebx, 0x9ae37
cmp dword [0x48ecec], 0x15
jne 0x40451a
push esi
push esi
push 0x403138
call dword [sym.imp.KERNEL32.dll_FindFirstChangeNotificationW]
push esi
call dword [sym.imp.KERNEL32.dll_GetConsoleAliasesLengthA]
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push 0x403198
push esi
push esi
push esi
call dword [sym.imp.KERNEL32.dll_SetCalendarInfoW]
lea eax, [esp + 0x250]
push eax
push esi
push 0x4031b0
call dword [sym.imp.KERNEL32.dll_GetFileAttributesExW]
push esi
call dword [sym.imp.KERNEL32.dll_UnregisterWait]
lea eax, [esp + 0x30]
push eax
push esi
push esi
call dword [sym.imp.KERNEL32.dll_GetCPInfoExW]
xor eax, eax
mov word [esp + 0xc], ax
lea edi, [esp + 0xe]
stosw word es:[edi], ax
lea eax, [esp + 0x14]
push eax
push dword [esp + 0x10]
push esi
push esi
push esi
call dword [sym.imp.KERNEL32.dll_FillConsoleOutputCharacterA]
xor eax, eax
push esi
mov word [esp + 0x14], ax
lea edi, [esp + 0x16]
stosw word es:[edi], ax
push dword [esp + 0x14]
push esi
push esi
push esi
call dword [sym.imp.KERNEL32.dll_WriteConsoleOutputCharacterW]
push esi
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
dec ebx
jne 0x404477
call fcn.00403390
call fcn.00403d41
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 0x10

Function at 0x406b46
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x446430]
jne 0x406b50
repz ret
jmp fcn.00409641
Function at 0x408f6f
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x446430]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x1c], eax
call fcn.00406611
and dword [ebp - 0x14], 0
cmp dword [0x44e8dc], 0
mov dword [ebp - 0x18], eax
jne 0x409022
push 0x402168
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x4090ca
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x40215c
push ebx
call edi
test eax, eax
je 0x4090ca
mov esi, dword [sym.imp.KERNEL32.dll_EncodePointer]
push eax
call esi
push 0x40214c
push ebx
mov dword [0x44e8dc], eax
call edi
push eax
call esi
push 0x402138
push ebx
mov dword [0x44e8e0], eax
call edi
push eax
call esi
push 0x40211c
push ebx
mov dword [0x44e8e4], eax
call edi
push eax
call esi
mov dword [0x44e8ec], eax
test eax, eax
je 0x409022
push 0x402104
push ebx
call edi
push eax
call esi
mov dword [0x44e8e8], eax
mov eax, dword [0x44e8e8]
mov ecx, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, ecx
je 0x40907b
cmp dword [0x44e8ec], ecx
je 0x40907b
push eax
call esi
push dword [0x44e8ec]
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x40907b
test ebx, ebx
je 0x40907b
call edi
test eax, eax
je 0x409072
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call ebx
test eax, eax
je 0x409072
test byte [ebp - 8], 1
jne 0x40907b
or dword [ebp + 0x10], 0x200000
jmp 0x4090ae
mov eax, dword [0x44e8e0]
cmp eax, dword [ebp - 0x18]
je 0x4090ae
push eax
call esi
test eax, eax
je 0x4090ae
call eax
mov dword [ebp - 0x14], eax
test eax, eax
je 0x4090ae
mov eax, dword [0x44e8e4]
cmp eax, dword [ebp - 0x18]
je 0x4090ae
push eax
call esi
test eax, eax
je 0x4090ae
push dword [ebp - 0x14]
call eax
mov dword [ebp - 0x14], eax
push dword [0x44e8dc]
call esi
test eax, eax
je 0x4090ca
push dword [ebp + 0x10]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
call eax
jmp 0x4090cc
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00406b46
leave
ret
Function at 0x408315
Capabilities:
Set registry value

Disassembly:
push esi
push dword [esp + 8]
mov esi, ecx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [eax + eax + 2]
push eax
push dword [esp + 0xc]
push 1
push 0
push dword [esp + 0x1c]
push dword [esi]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
pop esi
ret 8
Function at 0x408eec
Capabilities:
Get common file path

Disassembly:
push ebx
push esi
push edi
mov esi, ecx
lea edi, [esi + 4]
push edi
push 0x104
mov dword [esi], 0x401374
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov ebx, dword [sym.imp.MSVCRT.dll_wcscat]
push 0x401c44
push edi
call ebx
push dword [esp + 0x18]
push edi
call ebx
add esp, 0x10
pop edi
mov eax, esi
pop esi
pop ebx
ret 4

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x208
push ebx
push esi
push edi
mov edi, dword [sym.imp.MSVCRT.dll_wcsncpy]
mov esi, ecx
lea eax, [esi + 0x764]
push 0x104
push eax
lea eax, [ebp - 0x208]
push eax
call edi
mov ebx, dword [sym.imp.SHLWAPI.dll_PathAppendW]
jmp 0x409633
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x20]
push 0x104
lea eax, [esi + 0x764]
push eax
lea eax, [ebp - 0x208]
push eax
call edi
and word [ebp - 2], 0
add esp, 0xc
push dword [ebp + 8]
lea eax, [ebp - 0x208]
push eax
call ebx
lea eax, [ebp - 0x208]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x409617
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x40981a
Capabilities:
Query service status

Disassembly:
mov eax, 0x411338
call fcn.00408d00
sub esp, 0x20
add ecx, 4
push esi
push ecx
lea ecx, [ebp - 0x10]
call fcn.0040979d
and dword [ebp - 4], 0
or esi, 0xffffffff
cmp dword [ebp - 0x10], 0
je 0x40987a
lea eax, [ebp - 0x2c]
push eax
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x40987a
mov eax, dword [ebp - 0x28]
xor esi, esi
inc esi
cmp eax, esi
je 0x40987a
cmp eax, 2
je 0x409877
cmp eax, 3
je 0x40987a
jbe 0x409872
cmp eax, 5
jbe 0x409877
cmp eax, 7
jbe 0x40987a
or esi, 0xffffffff
jmp 0x40987a
push 4
pop esi
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x10]
call fcn.0040970e
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop esi
mov dword fs:[0], ecx
leave
ret

Function at 0x4098ce
Capabilities:
Modify service

Disassembly:
mov eax, 0x411338
call fcn.00408d00
push ecx
add ecx, 4
push esi
push ecx
lea ecx, [ebp - 0x10]
call fcn.0040979d
xor eax, eax
mov dword [ebp - 4], eax
xor esi, esi
cmp dword [ebp - 0x10], eax
je 0x40990b
push eax
push eax
push eax
push eax
push eax
push eax
push eax
push 0xffffffffffffffff
push dword [ebp + 8]
push 0xffffffffffffffff
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigW]
mov esi, eax
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x10]
call fcn.0040970e
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop esi
mov dword fs:[0], ecx
leave
ret 4
Function at 0x409978
Capabilities:
Query service status

Disassembly:
mov eax, 0x41134c
call fcn.00408d00
sub esp, 0x30
push ebx
push esi
mov esi, ecx
push edi
lea ebx, [esi + 4]
push ebx
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x20], ebx
call fcn.0040979d
xor eax, eax
mov dword [ebp - 4], eax
mov ecx, esi
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x10], eax
call fcn.0040981a
xor edi, edi
inc edi
cmp eax, edi
je 0x4099b8
mov dword [esi + 0x1bc], eax
cmp dword [ebp - 0x14], 0
je 0x409b07
lea eax, [ebp - 0x3c]
push eax
push edi
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x409ad8
lea eax, [ebp - 0x3c]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x409a9b
mov ebx, 0x9c40
cmp dword [ebp - 0x24], ebx
jb 0x4099fa
mov ebx, dword [ebp - 0x24]
cmp dword [ebp - 0x38], edi
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x1c], eax
je 0x409a62
mov edi, 0xfa
test ebx, ebx
jbe 0x409a59
push edi
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp ebx, edi
jb 0x409a1d
sub ebx, edi
jmp 0x409a1f
xor ebx, ebx
lea eax, [ebp - 0x3c]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x409a50
mov eax, dword [ebp - 0x28]
cmp eax, dword [ebp - 0x1c]
je 0x409a48
mov ebx, 0x9c40
cmp dword [ebp - 0x24], ebx
jb 0x409a45
mov ebx, dword [ebp - 0x24]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x38], 1
jne 0x409a0a
jmp 0x409a5f
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x38], 1
jne 0x409a76
xor edi, edi
inc edi
mov esi, dword [esi]
test esi, esi
je 0x409b02
push dword [ebp - 0x20]
push 0x40242c
jmp 0x409af4
cmp dword [ebp - 0x10], 0
jne 0x409a9b
mov eax, dword [esi]
test eax, eax
je 0x409aba
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push 0x4023b0
push 0x402390
push eax
call fcn.00408f88
add esp, 0x14
mov esi, dword [esi]
test esi, esi
je 0x409aba
push dword [ebp - 0x10]
push dword [ebp - 0x20]
push 0x402348
push 0x402390
push esi
call fcn.00408f6d
add esp, 0x14
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.0040970e
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x18]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x426
mov dword [ebp - 0x10], eax
jne 0x409a9b
mov esi, dword [esi]
test esi, esi
je 0x409b02
push ebx
push 0x402314
push 0x402390
push esi
call fcn.00408f88
add esp, 0x10
mov dword [ebp - 0x18], edi
jmp 0x409aba
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x424
mov dword [ebp - 0x10], eax
jne 0x409a9b
mov esi, dword [esi]
test esi, esi
je 0x409b02
push ebx
push 0x4022e0
jmp 0x409af4
Function at 0x409b25
Capabilities:
Query service status
Start service

Disassembly:
mov eax, 0x41134c
call fcn.00408d00
sub esp, 0x30
push ebx
push esi
mov esi, ecx
push edi
lea edi, [esi + 4]
push edi
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x20], edi
call fcn.0040979d
xor ebx, ebx
mov dword [ebp - 4], ebx
mov ecx, esi
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x10], ebx
call fcn.0040981a
cmp eax, 4
je 0x409b63
mov dword [esi + 0x1bc], eax
cmp dword [ebp - 0x14], ebx
je 0x409cb0
push ebx
push ebx
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
je 0x409c7d
lea eax, [ebp - 0x3c]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x409c40
mov ebx, 0x1d4c0
cmp dword [ebp - 0x24], ebx
jb 0x409ba1
mov ebx, dword [ebp - 0x24]
cmp dword [ebp - 0x38], 4
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x1c], eax
je 0x409c07
mov edi, 0xfa
test ebx, ebx
jbe 0x409c01
push edi
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp ebx, edi
jb 0x409bc5
sub ebx, edi
jmp 0x409bc7
xor ebx, ebx
lea eax, [ebp - 0x3c]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x409bf8
mov eax, dword [ebp - 0x28]
cmp eax, dword [ebp - 0x1c]
je 0x409bf0
mov ebx, 0x1d4c0
cmp dword [ebp - 0x24], ebx
jb 0x409bed
mov ebx, dword [ebp - 0x24]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x38], 4
jne 0x409bb2
jmp 0x409c07
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x38], 4
jne 0x409c1b
mov esi, dword [esi]
test esi, esi
je 0x409ca7
push dword [ebp - 0x20]
push 0x402554
jmp 0x409c99
cmp dword [ebp - 0x10], 0
jne 0x409c40
mov eax, dword [esi]
test eax, eax
je 0x409c5f
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push 0x4024d8
push 0x402390
push eax
call fcn.00408f88
add esp, 0x14
mov esi, dword [esi]
test esi, esi
je 0x409c5f
push dword [ebp - 0x10]
push dword [ebp - 0x20]
push 0x402490
push 0x402390
push esi
call fcn.00408f6d
add esp, 0x14
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.0040970e
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x18]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x420
mov dword [ebp - 0x10], eax
jne 0x409c40
mov esi, dword [esi]
cmp esi, ebx
je 0x409ca7
push edi
push 0x402454
push 0x402390
push esi
call fcn.00408f88
add esp, 0x10
mov dword [ebp - 0x18], 1
jmp 0x409c5f
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x424
mov dword [ebp - 0x10], eax
jne 0x409c40
mov esi, dword [esi]
cmp esi, ebx
je 0x409ca7
push edi
push 0x4022e0
jmp 0x409c99
Function at 0x409dfb
Capabilities:
Enumerate services

Disassembly:
mov eax, 0x41136a
call fcn.00408d00
sub esp, 0x18
push ebx
push edi
push 0x1c0
mov edi, ecx
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
mov ecx, eax
mov dword [ebp - 0x24], ecx
xor ebx, ebx
mov dword [ebp - 4], ebx
cmp ecx, ebx
je 0x409e34
push dword [edi]
push dword [ebp + 8]
call fcn.00409723
mov dword [ebp - 0x1c], eax
jmp 0x409e37
mov dword [ebp - 0x1c], ebx
or dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x1c]
cmp eax, ebx
mov dword [ebp - 0x24], eax
jne 0x409e4c
xor eax, eax
jmp 0x409f25
push dword [ebp + 8]
lea ecx, [ebp - 0x14]
call fcn.0040979d
xor eax, eax
inc eax
mov dword [ebp - 4], eax
cmp dword [ebp - 0x14], ebx
je 0x409eeb
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_EnumDependentServicesW]
lea ecx, [ebp - 0x10]
push ecx
lea ecx, [ebp + 8]
push ecx
push ebx
push ebx
push eax
push dword [ebp - 0x14]
mov dword [ebp + 8], ebx
mov dword [ebp - 0x10], ebx
call esi
mov dword [ebp - 0x20], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp dword [ebp - 0x20], ebx
jne 0x409eea
cmp eax, 0xea
jne 0x409eea
push dword [ebp + 8]
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
cmp eax, ebx
pop ecx
mov dword [ebp - 0x20], eax
je 0x409eea
lea ecx, [ebp - 0x10]
push ecx
lea ecx, [ebp + 8]
push ecx
push dword [ebp + 8]
push eax
push 1
push dword [ebp - 0x14]
call esi
cmp eax, ebx
je 0x409ee1
cmp dword [ebp - 0x10], ebx
mov dword [ebp - 0x18], ebx
jbe 0x409ee1
mov esi, dword [ebp - 0x20]
push dword [esi]
mov ecx, edi
call fcn.00409dfb
inc dword [ebp - 0x18]
mov eax, dword [ebp - 0x18]
add esi, 0x24
cmp eax, dword [ebp - 0x10]
jb 0x409eca
push dword [ebp - 0x20]
call fcn.00408d06
pop ecx
pop esi
lea eax, [edi + 0x194]
mov ecx, dword [eax]
cmp ecx, 0x64
jge 0x409f04
mov edx, dword [ebp - 0x1c]
mov dword [edi + ecx*4 + 4], edx
inc dword [eax]
mov dword [ebp - 0x24], ebx
mov ecx, dword [ebp - 0x24]
cmp ecx, ebx
je 0x409f14
push 1
call fcn.00409ddc
jmp 0x409f17
xor ebx, ebx
inc ebx
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.0040970e
mov eax, ebx
mov ecx, dword [ebp - 0xc]
pop edi
pop ebx
mov dword fs:[0], ecx
leave
ret 4

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

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
ret 4
Function at 0x40a076
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
lea eax, [ebp - 4]
mov esi, ecx
push eax
push esi
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov edi, eax
test edi, edi
je 0x40a0f2
push edi
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
push eax
push edi
push dword [ebp - 4]
mov dword [esi + 0x208], eax
push esi
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x40a0cc
lea edi, [esi + 0x210]
push edi
lea eax, [esi + 0x20c]
push eax
push 0x40261c
push dword [esi + 0x208]
call sub.VERSION.dll_VerQueryValueW
test eax, eax
jne 0x40a0ef
push dword [esi + 0x208]
call fcn.00408d06
and dword [esi + 0x208], 0
and dword [esi + 0x20c], 0
lea edi, [esi + 0x210]
and dword [edi], 0
pop ecx
shr dword [edi], 2
pop edi
pop esi
leave
ret