Function at 0x45abf0
Capabilities:
Check for time delay via queryperformancecounter
Print debug messages
Query service status
Start service

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4c56d0
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x78
mov eax, dword [0x501040]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
xor al, al
cmp dword [esi + 0x10], 0
mov byte [ebp - 0x55], al
je 0x45ae2d
push 5
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 0x5c], eax
test eax, eax
je 0x45ae2a
cmp dword [esi + 0x14], 7
jbe 0x45ac5e
mov esi, dword [esi]
push 0x14
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov esi, eax
test esi, esi
je 0x45ae21
mov edi, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
lea eax, [ebp - 0x54]
push eax
push esi
call edi
test eax, eax
je 0x45ae1a
cmp dword [ebp - 0x50], 4
je 0x45ae16
push 0
push 0
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
jne 0x45ad2d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x1c], eax
lea ecx, [ebp - 0x20]
sub esp, 8
mov dword [ebp - 0x20], 0x20000000
mov eax, esp
mov dword [ebp - 4], 0xffffffff
push 0x22
mov dword [eax + 4], ecx
lea ecx, [ebp - 0x74]
push str._WINTUN__2_StartServiceW_Fail:__d_n
mov dword [eax], 1
call fcn.0040a5c0
add esp, 0x10
lea eax, [ebp - 0x74]
cmp dword [ebp - 0x60], 0xf
cmova eax, dword [ebp - 0x74]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov ecx, dword [ebp - 0x60]
cmp ecx, 0xf
jbe 0x45ae1a
mov edx, dword [ebp - 0x74]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x45ad1e
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x45ae4b
push ecx
push edx
call fcn.00472bfe
add esp, 8
jmp 0x45ae1a
lea eax, [ebp - 0x28]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
test eax, eax
je 0x45ad65
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
test eax, eax
je 0x45ad65
push 0
push 0x3e8
push dword [ebp - 0x24]
push dword [ebp - 0x28]
call fcn.004bfe30
push edx
push eax
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
jmp 0x45ad79
lea ecx, [ebp - 0x30]
call fcn.00415d10
push 0
push 0xf4240
push dword [eax + 4]
push dword [eax]
call fcn.004bfe30
mov dword [ebp - 0x24], edx
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x54]
push eax
push esi
call edi
test eax, eax
je 0x45ae1a
mov eax, dword [ebp - 0x50]
cmp eax, 4
je 0x45ae16
cmp eax, 2
jne 0x45ae1a
push 0xc8
call dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
test eax, eax
je 0x45ade3
lea eax, [ebp - 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
test eax, eax
je 0x45ade3
push 0
push 0x3e8
push dword [ebp - 0x34]
push dword [ebp - 0x38]
call fcn.004bfe30
push edx
push eax
push dword [ebp - 0x2c]
push dword [ebp - 0x30]
jmp 0x45adf7
lea ecx, [ebp - 0x80]
call fcn.00415d10
push 0
push 0xf4240
push dword [eax + 4]
push dword [eax]
call fcn.004bfe30
sub eax, dword [ebp - 0x1c]
sbb edx, dword [ebp - 0x24]
jne 0x45ae1a
jb 0x45ad84
cmp eax, 0xea60
ja 0x45ae1a
jmp 0x45ad84
mov byte [ebp - 0x55], 1
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push dword [ebp - 0x5c]
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov al, byte [ebp - 0x55]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0047299a
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
call fcn.004a074e
int3