Function at 0x40ef30
Capabilities:
Query service status
Start service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x238
mov eax, dword [0x424284]
xor eax, ebp
mov dword [ebp - 8], eax
cmp dword [ebp + 8], 1
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
mov ebx, ecx
mov dword [ebp - 0x234], eax
jge 0x40ef6d
call fcn.00408460
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
mov edi, dword [eax]
mov eax, 5
mov dword [ebp - 0x230], edi
call fcn.0040c9c0
mov esi, eax
test esi, esi
jne 0x40efb8
push 0x400001fb
call fcn.004147fb
add eax, 0x40
push eax
call fcn.00402220
xor eax, eax
add esp, 8
cmp byte [ebp + 0x10], al
setne al
dec eax
and eax, 2
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
mov eax, 4
cmp ebx, 0x80
ja case.0x40efcc.4
movzx ecx, byte [ebx + 0x40f390]
jmp dword [ecx*4 + 0x40f37c]
mov eax, 0x14
jmp case.0x40efcc.4
mov eax, 0x44
jmp case.0x40efcc.4
mov eax, 0x24
jmp case.0x40efcc.4
mov eax, 0x104
push 0x100
lea edx, [ebp - 0x20c]
push edx
push eax
push edi
push esi
call fcn.0040c9f0
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x40f02e
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
xor eax, eax
cmp byte [ebp + 0x10], al
setne al
dec eax
and eax, 3
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
test ebx, ebx
jne 0x40f1ae
mov eax, dword [ebp - 0x234]
mov ecx, dword [ebp + 8]
push eax
push ecx
push edi
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
mov dword [ebp - 0x22c], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov ebx, eax
call esi
cmp ebx, 0x3e5
jne 0x40f06b
xor ebx, ebx
jmp 0x40f078
cmp dword [ebp - 0x22c], 0
je 0x40f17c
mov edx, dword [ebp - 0x230]
push edx
xor al, al
mov ecx, 0x20019
xor edx, edx
mov dword [ebp - 0x22c], 0
call fcn.0040b3e0
add esp, 4
mov dword [ebp - 0x230], eax
test eax, eax
je 0x40f0d4
push eax
lea ecx, [ebp - 0x22c]
mov esi, str.AppThrottle
call fcn.0040ab10
add esp, 4
cmp eax, 1
je 0x40f0c7
mov dword [ebp - 0x22c], 0x5dc
mov eax, dword [ebp - 0x230]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 0x22c]
push ecx
push 1
push edi
push 0
lea esi, [ebp - 0x228]
call fcn.0040c2c0
add esp, 0x10
push edi
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test esi, esi
je 0x40f145
xor eax, eax
call fcn.0040f9a0
push eax
mov eax, dword [ebp - 0x224]
call fcn.0040fa90
push eax
lea edx, [ebp - 0x20c]
push edx
push 0x40000227
call fcn.004147fb
add eax, 0x40
push eax
call fcn.00402220
add esp, 0x14
xor eax, eax
cmp byte [ebp + 0x10], al
sete al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
mov edi, ebx
call fcn.00402080
push eax
xor eax, eax
call fcn.0040f9a0
push eax
lea eax, [ebp - 0x20c]
push eax
push str._s:__s:__s
call fcn.00414fc1
add esp, 0x10
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
push edi
call esi
mov edi, ebx
call fcn.00402080
push eax
xor eax, eax
call fcn.0040f9a0
push eax
lea ecx, [ebp - 0x20c]
push ecx
push str._s:__s:__s
call fcn.004147fb
add eax, 0x40
push eax
call fcn.00414cb9
jmp 0x40f129
cmp ebx, 4
jne 0x40f22f
lea edx, [ebp - 0x228]
push edx
push edi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
test esi, esi
je 0x40f205
mov eax, dword [ebp - 0x224]
call fcn.0040fa90
push eax
push 0x420224
call fcn.00414fc1
movzx eax, byte [ebp + 0x10]
add esp, 8
neg eax
sbb eax, eax
and eax, dword [ebp - 0x224]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
mov edi, eax
call fcn.00402080
push eax
lea eax, [ebp - 0x20c]
push eax
push str._s:__s_n
call fcn.004147fb
add eax, 0x40
push eax
call fcn.00414cb9
add esp, 0x10
jmp 0x40f12c
lea ecx, [ebp - 0x228]
push ecx
push ebx
push edi
call dword [sym.imp.ADVAPI32.dll_ControlService]
mov edx, dword [ebp - 0x224]
mov dword [ebp - 0x22c], eax
mov dword [ebp - 0x230], edx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov dword [ebp - 0x234], eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov esi, dword [ebp - 0x234]
cmp esi, 0x3e5
jne 0x40f27d
mov dword [ebp - 0x234], 0
jmp 0x40f28a
cmp dword [ebp - 0x22c], 0
je 0x40f313
mov eax, dword [ebp - 0x230]
lea esi, [ebp - 0x228]
mov ecx, edi
mov edx, ebx
call fcn.0040c370
push edi
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test esi, esi
je 0x40f2cc
mov eax, ebx
call fcn.0040f9a0
push eax
mov eax, dword [ebp - 0x224]
call fcn.0040fa90
push eax
lea eax, [ebp - 0x20c]
push eax
jmp 0x40f116
mov edi, dword [ebp - 0x234]
call fcn.00402080
push eax
mov eax, ebx
call fcn.0040f9a0
push eax
lea ecx, [ebp - 0x20c]
push ecx
push str._s:__s:__s
call fcn.00414fc1
movzx eax, byte [ebp + 0x10]
add esp, 0x10
neg eax
sbb eax, eax
and eax, dword [ebp - 0x224]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041427b
mov esp, ebp
pop ebp
ret
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov edi, esi
call fcn.00402080
push eax
mov eax, ebx
call fcn.0040f9a0
push eax
lea edx, [ebp - 0x20c]
push edx
push str._s:__s:__s
call fcn.004147fb
add eax, 0x40
push eax
call fcn.00414cb9
add esp, 0x14
cmp esi, 0x426
jne 0x40f12c
cmp ebx, 5
je 0x40f361
cmp ebx, 1
jne 0x40f12c
mov ecx, dword [ebp - 8]
xor eax, eax
cmp byte [ebp + 0x10], al
pop edi
setne al
pop esi
xor ecx, ebp
pop ebx
call fcn.0041427b
mov esp, ebp
pop ebp
ret