Function at 0x409d20
Capabilities:
Enumerate services
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc60
mov eax, dword [0x4a6004]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [0x4a8304]
mov ecx, dword [0x23c03ac]
push ebx
push esi
push edi
xor ebx, ebx
xor eax, eax
mov edi, 0xec58acac
or esi, 0xffffffff
mov edi, edi
cmp eax, 0x180
jne 0x409d5d
lea ecx, [edx + 0xa231]
cmp ecx, 0x141
jne 0x409d71
mov dword [0x4a8e00], edi
mov dword [0x4a8e04], esi
inc eax
cmp eax, 0x12376ec
jl 0x409d50
mov edi, dword [sym.imp.KERNEL32.dll_GlobalReAlloc]
mov dword [0x23c03ac], ecx
xor esi, esi
cmp esi, 0x562d05
jne 0x409d99
mov eax, dword [0x4a6ef8]
mov dword [0x23c04dc], eax
cmp ecx, 0x3c
jne 0x409da9
push ebx
push ebx
push ebx
call edi
mov ecx, dword [0x23c03ac]
inc esi
cmp esi, 0x5f6c74
jl 0x409d87
cmp ecx, 0x7c
jne 0x409e95
lea ecx, [ebp - 0xc18]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
push ebx
call dword [sym.imp.USER32.dll_SetActiveWindow]
lea edx, [ebp - 0xc60]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
push ebx
lea eax, [ebp - 0xc14]
push eax
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_WriteConsoleW]
xor edx, edx
xor ecx, ecx
mov word [ebp - 0xc0a], dx
xor eax, eax
mov word [ebp - 0xc06], cx
lea edx, [ebp - 0xc20]
push edx
mov word [ebp - 0xc08], ax
mov eax, dword [ebp - 0xc08]
push eax
mov word [ebp - 0xc0c], cx
mov ecx, dword [ebp - 0xc0c]
push ecx
lea edx, [ebp - 0xc10]
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_ReadConsoleOutputA]
lea eax, [ebp - 0x404]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
cmp dword [0x23c03ac], 0x11
jne 0x409e67
lea ecx, [ebp - 0xc0c]
push ecx
lea edx, [ebp - 0xc08]
push edx
push ebx
lea eax, [ebp - 0xc44]
push eax
push ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_EnumDependentServicesW]
cmp dword [0x23c03ac], 0x2d
jne 0x409e77
push ebx
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
push 0x4a4d64
push 0x4a8d78
call fcn.004011a2
push ebx
call fcn.00401267
mov ecx, dword [0x23c03ac]
add esp, 0xc
cmp ecx, 0x110a
jne 0x409f26
push ebx
push ebx
mov dword [0x23c03a0], ebx
mov dword [0x23c03a4], ebx
call dword [sym.imp.KERNEL32.dll_CompareFileTime]
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_SetLocaleInfoA]
mov ecx, dword [ebp - 0xc10]
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_SetConsoleScreenBufferSize]
push ebx
push ebx
lea edx, [ebp - 0x404]
push edx
call dword [sym.imp.KERNEL32.dll_GetConsoleAliasesA]
push ebx
push ebx
push ebx
lea eax, [ebp - 0xc04]
push eax
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CompareStringW]
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_ActivateActCtx]
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_PurgeComm]
push ebx
push ebx
call fcn.00401049
push ebx
push ebx
call fcn.00401049
call fcn.004064f7
push ebx
push ebx
call fcn.0040127d
push ebx
call fcn.004010d8
push ebx
call fcn.00401015
add esp, 0x20
call fcn.00409990
xor esi, esi
cmp dword [0x23c03ac], ebx
jbe 0x409f8c
mov edi, dword [sym.imp.KERNEL32.dll_CommConfigDialogW]
mov ebx, 0x19b0
mov ecx, dword [0x23c04dc]
mov dword [ebp - 0xc08], ecx
mov eax, 0xa231
add dword [ebp - 0xc08], eax
mov edx, dword [ebp - 0xc08]
mov al, byte [edx + esi]
mov ecx, dword [0x23c01f4]
mov byte [ecx + esi], al
cmp dword [0x23c03ac], 0x5ab
jne 0x409f83
push 0
push 0
push 0
call edi
mov dword [0x23c01f8], ebx
inc esi
cmp esi, dword [0x23c03ac]
jb 0x409f40
push str.msimg32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
call fcn.00409a00
call fcn.004099d0
call fcn.00409ca0
call fcn.004099c0
mov ecx, dword [ebp - 0xc40]
xor eax, eax
cmp eax, 0x408e
jle 0x409fc2
cmp ecx, 0xf5bed7
jne 0x409fca
inc eax
cmp eax, 0x687ed2
jl 0x409fb3
mov esi, dword [sym.imp.KERNEL32.dll_EnumTimeFormatsW]
mov edi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov dword [ebp - 0xc0c], 0x1e4165
mov ebx, 0x8e46a6f0
jmp 0x409ff0
cmp dword [0x23c03ac], 0xcc1
jne 0x40a004
push 0
push 0
push 0
call esi
cmp dword [0x23c03ac], 0x7c4
mov dword [0x23c03a8], ebx
jne 0x40a018
call edi
sub dword [ebp - 0xc0c], 1
jne 0x409ff0
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00401006
mov esp, ebp
pop ebp
ret