Function at 0x40ff40
Capabilities:
Create process on windows
Resume thread

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x10094
call fcn.0041d6a0
mov eax, dword [0x424284]
xor eax, esp
mov dword [esp + 0x10090], eax
push ebx
push esi
push edi
mov edi, ecx
cmp dword [edi + 0x704d4], 0
mov dword [esp + 0x10], edi
mov byte [edi + 0x704e4], 0
jne 0x41040d
inc dword [edi + 0x70558]
push 0x44
lea eax, [esp + 0x34]
push 0
push eax
call fcn.0041a110
xor eax, eax
lea ecx, [esp + 0x3c]
add esp, 0xc
push ecx
mov ecx, edi
mov dword [esp + 0x34], 0x44
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], eax
call fcn.0040b5b0
add esp, 4
test eax, eax
je 0x40fffd
push 0
lea edx, [edi + 2]
push edx
push 0xc00003ec
push 1
call fcn.004021b0
mov eax, edi
call fcn.0040c970
push 1
push 1
push 2
mov eax, edi
call fcn.00410430
add esp, 0x1c
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x10090]
xor ecx, esp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
lea eax, [edi + 0x28414]
push eax
lea esi, [edi + 0x18416]
push esi
push str.__s___s
push 0xffffffffffffffff
lea ecx, [esp + 0xa8]
push 0x8000
push ecx
call fcn.004149b0
add esp, 0x18
test eax, eax
jns 0x410072
push 0
push str.start_service
push str.command_line
push 0xc00003eb
push 1
call fcn.004021b0
add esp, 0x14
mov eax, edi
call fcn.0040c970
push 1
push 1
push 2
mov eax, edi
call fcn.00410430
add esp, 0xc
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x10090]
xor ecx, esp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
mov ecx, edi
call fcn.004108d0
mov edx, dword [edi + 0x704d0]
lea ebx, [edi + 0x704b4]
push ebx
push edx
mov dword [edi + 0x704b8], 2
mov dword [edi + 0x704bc], 0x45
call dword [sym.imp.ADVAPI32.dll_SetServiceStatus]
cmp byte [edi + 0x704e5], 0
mov dword [esp + 0x18], 0
je 0x41036d
lea eax, [esp + 0x30]
push eax
push edi
call fcn.004072c0
add esp, 8
test eax, eax
je 0x410118
push 0
lea ecx, [edi + 2]
push ecx
push 0xc000041b
push 1
call fcn.004021b0
add esp, 0x10
call dword [sym.imp.KERNEL32.dll_FreeConsole]
lea esi, [esp + 0x30]
call fcn.004077c0
mov eax, edi
call fcn.0040c970
push 1
push 1
push 4
mov eax, edi
call fcn.00410430
add esp, 0xc
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x10090]
xor ecx, esp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_FreeConsole]
push 0
push 0x4e20
lea edx, [esp + 0x20]
push edx
push str.Start
mov ecx, 0x420034
mov edx, edi
call fcn.00405e40
add esp, 0x10
cmp eax, 0x63
jne 0x4101ad
push eax
push 0x4202bc
push 0xffffffffffffffff
lea eax, [esp + 0x84]
push 0x10
push eax
call fcn.004149b0
add esp, 0x14
push 0
lea ecx, [esp + 0x7c]
push ecx
lea edx, [edi + 2]
push edx
push 0x420034
push str.Start
push 0x40000437
push 1
call fcn.004021b0
add esp, 0x1c
mov eax, edi
call fcn.0040c970
push 1
push 1
push 5
mov eax, edi
call fcn.00410430
add esp, 0xc
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x10090]
xor ecx, esp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
mov eax, edi
call fcn.0040c920
xor cl, cl
test dword [esp + 0x5c], 0x100
je 0x4101c2
mov cl, 1
call fcn.0040c840
mov edx, dword [edi + 0x40400]
and eax, dword [edi + 0x4041c]
or edx, dword [edi + 0x40404]
je 0x4101de
or eax, 4
cmp dword [edi + 0x40420], 0
jne 0x4101ea
or eax, 0x10
lea edx, [esp + 0x20]
push edx
lea edx, [esp + 0x34]
push edx
lea edx, [edi + 0x30412]
push edx
push 0
push eax
movzx eax, cl
push eax
push 0
push 0
lea ecx, [esp + 0xb8]
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
jne 0x410274
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0
mov edi, eax
call fcn.00402080
mov edi, dword [esp + 0x14]
push eax
push esi
lea edx, [edi + 2]
push edx
push 0xc00003f2
push 1
call fcn.004021b0
lea esi, [esp + 0x48]
call fcn.004077c0
mov eax, edi
call fcn.0040c970
push 1
push 1
push 3
mov eax, edi
call fcn.00410430
add esp, 0x24
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x10090]
xor ecx, esp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x28]
inc dword [edi + 0x7055c]
lea esi, [edi + 0x70540]
push esi
push eax
mov dword [edi + 0x704d4], eax
mov dword [edi + 0x704d8], ecx
call fcn.00408da0
add esp, 8
test eax, eax
je 0x4102a9
xor eax, eax
mov dword [esi], eax
mov dword [esi + 4], eax
lea esi, [esp + 0x30]
call fcn.004077c0
mov edx, dword [edi + 0x40400]
or edx, dword [edi + 0x40404]
je 0x41036d
mov edx, dword [edi + 0x704d4]
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x18]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_GetProcessAffinityMask]
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x4102f5
mov eax, dword [esp + 0x1c]
and eax, dword [edi + 0x40400]
mov dword [esp + 0x14], eax
jmp 0x41032a
mov eax, dword [edi + 0x40400]
push 0
mov dword [esp + 0x18], eax
call esi
mov edi, eax
call fcn.00402080
mov ecx, dword [esp + 0x14]
push eax
add ecx, 2
push ecx
push 0x8000042d
push 1
call fcn.004021b0
mov eax, dword [esp + 0x28]
mov edi, dword [esp + 0x24]
add esp, 0x14
mov edx, dword [edi + 0x704d4]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_SetProcessAffinityMask]
test eax, eax
jne 0x410362
push eax
call esi
mov edi, eax
call fcn.00402080
push eax
mov eax, dword [esp + 0x18]
add eax, 2
push eax
push 0xc000042e
push 2
call fcn.004021b0
mov edi, dword [esp + 0x24]
add esp, 0x14
mov ecx, dword [esp + 0x24]
push ecx
call dword [sym.imp.KERNEL32.dll_ResumeThread]
mov eax, edi
call fcn.0040c970
mov edx, dword [edi + 0x70498]
mov eax, dword [edi + 0x704d0]
mov ecx, dword [edi + 0x704d4]
push edx
push str.start_service
lea edx, [edi + 2]
push eax
call fcn.00410a70
add esp, 0xc
cmp eax, 1
jne 0x4103a7
mov dword [edi + 0x704e8], 0
cmp byte [edi + 0x704e5], 0
je 0x41040d
mov ecx, dword [edi + 0x704d0]
and dword [edi + 0x704bc], 0xfffffffd
push ebx
push ecx
mov dword [edi + 0x704b8], 4
call dword [sym.imp.ADVAPI32.dll_SetServiceStatus]
cmp dword [edi + 0x704e8], 0
jne 0x4103f1
lea edx, [esp + 0x18]
push edx
mov eax, str.Post
mov ecx, str.Start
mov edx, edi
call fcn.00406580
add esp, 4
cmp dword [edi + 0x70494], 0
je 0x41040d
cmp dword [edi + 0x704e8], 0
jne 0x41040d
mov dword [edi + 0x704e8], 1
mov ecx, dword [esp + 0x1009c]
pop edi
pop esi
pop ebx
xor ecx, esp
xor eax, eax
call fcn.0041427b
mov esp, ebp
pop ebp
ret