Function at 0x4060e0
Capabilities:
Check mutex on windows
Create pipe
Create process on windows
Create process suspended
Get common file path
Query environment variable
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
mov esi, eax
push ebx
sub esp, 0x3bc
mov dword [ebp - 0x36c], eax
mov eax, dword [eax + 8]
mov dword [ebp - 0x380], edx
mov dword [ebp - 0x370], eax
add eax, 0x18
mov dword [esp], eax
mov eax, dword [sym.imp.kernel32.dll_EnterCriticalSection]
mov dword [ebp - 0x37c], ecx
mov dword [ebp - 0x388], eax
call eax
mov ebx, dword [esi + 0x68]
sub esp, 4
test ebx, ebx
je 0x406160
mov dword [esp + 4], 0
mov eax, dword [ebx + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_WaitForSingleObject]
sub esp, 8
cmp eax, 0x102
mov eax, dword [ebp - 0x36c]
je 0x406a48
mov dword [eax + 0x68], 0
dec dword [ebx + 0x10]
mov dword [esp], ebx
call sym._release_process
mov ebx, dword [ebp - 0x36c]
mov esi, dword [sym.imp.kernel32.dll_ExpandEnvironmentStringsW]
mov dword [ebx + 0x70], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov eax, dword [ebx + 0x40]
mov dword [esp], eax
call esi
mov edi, dword [sym.imp.ucrtbase.dll_malloc]
sub esp, 0xc
mov ebx, eax
add eax, eax
mov dword [esp], eax
call edi
mov dword [ebp - 0x378], eax
test eax, eax
je 0x406881
mov dword [esp + 8], ebx
mov ebx, dword [ebp - 0x36c]
mov dword [esp + 4], eax
mov eax, dword [ebx + 0x40]
mov dword [esp], eax
call esi
mov edx, dword [ebx + 0x78]
sub esp, 0xc
test edx, edx
jne 0x406520
lea edx, [ebp - 0x220]
mov eax, dword [ebp - 0x36c]
mov dword [ebp - 0x370], edx
mov edx, dword [sym.imp.ucrtbase.dll_free]
mov eax, dword [eax + 0x34]
mov dword [ebp - 0x374], edx
dec eax
cmp eax, 1
jbe 0x406690
lea eax, [ebp - 0x354]
mov dword [esp + 8], 0
mov dword [esp + 0x14], eax
lea eax, [ebp - 0x34c]
mov dword [esp + 0x10], eax
mov eax, dword [ebp - 0x370]
mov dword [ebp - 0x34c], 0xffffffff
mov dword [esp + 0xc], eax
mov eax, dword [0x419244]
mov dword [ebp - 0x354], 4
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegQueryValueExW]
sub esp, 0x18
test eax, eax
jne 0x40625e
cmp dword [ebp - 0x220], 4
je 0x4068a8
mov eax, dword [0x419244]
mov dword [esp + 0x14], 4
mov dword [esp + 0x10], 0x419240
mov dword [esp + 0xc], 4
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegSetValueExW]
mov eax, dword [0x419240]
sub esp, 0x18
mov dword [esp + 0xc], eax
mov dword [esp + 8], str..pipe_netNtControlPipe_u
mov dword [esp + 4], 0x27
mov dword [esp], 0x419180
call sym._swprintf
inc dword [0x419240]
mov dword [esp + 4], 0x28
mov dword [esp], 1
call dword [sym.imp.ucrtbase.dll_calloc]
mov ebx, eax
test eax, eax
je 0x407244
mov dword [eax + 0xc], 1
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 0
call dword [sym.imp.kernel32.dll_CreateMutexW]
mov dword [ebx + 0x1c], eax
sub esp, 0xc
test eax, eax
je 0x4069b0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 0
call dword [sym.imp.kernel32.dll_CreateEventW]
mov dword [ebx + 0x24], eax
sub esp, 0x10
test eax, eax
je 0x406a20
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0x2710
mov dword [esp + 0x14], 0x100
mov dword [esp + 0x10], 0x100
mov dword [esp + 0xc], 1
mov dword [esp + 8], 0
mov dword [esp + 4], 0x40000003
mov dword [esp], 0x419180
call dword [sym.imp.kernel32.dll_CreateNamedPipeW]
mov dword [ebx + 0x20], eax
sub esp, 0x20
cmp eax, 0xffffffff
je 0x406b86
lea edx, [ebp - 0x21c]
xor eax, eax
mov ecx, 0x10
mov edi, edx
rep stosd dword es:[edi], eax
mov eax, dword [ebp - 0x36c]
mov dword [ebp - 0x220], 0x44
test byte [eax + 0x35], 1
jne 0x4063cb
mov dword [ebp - 0x218], str.__wineservice_winstationDefault
mov esi, dword [0x4190e0]
test esi, esi
je 0x406ba0
mov edi, dword [ebp - 0x36c]
mov eax, dword [edi + 0x30]
mov dword [edi + 0x18], 2
mov dword [edi + 0x1c], 0
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_ResetEvent]
mov eax, dword [edi + 8]
sub esp, 4
lea edx, [eax + 8]
mov dword [ebx + 8], eax
mov dword [ebx], edx
mov edx, dword [eax + 0xc]
mov dword [ebx + 4], edx
mov dword [edx], ebx
mov dword [eax + 0xc], ebx
lock inc dword [ebx + 0xc]
mov eax, dword [ebp - 0x37c]
inc dword [ebx + 0x10]
mov dword [edi + 0x68], ebx
mov dword [eax], 0
mov eax, dword [edi + 8]
mov dword [edi + 0x6c], 0
add eax, 0x18
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
lea eax, [ebp - 0x34c]
mov edi, dword [ebp - 0x378]
sub esp, 4
mov dword [esp + 0x24], eax
mov eax, dword [ebp - 0x370]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x20], eax
mov eax, dword [0x4190e0]
mov dword [esp + 0x14], 0x408
mov dword [esp + 0x18], eax
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], edi
mov dword [esp], 0
call dword [sym.imp.kernel32.dll_CreateProcessW]
sub esp, 0x28
mov esi, eax
mov eax, dword [ebp - 0x374]
mov dword [esp], edi
call eax
test esi, esi
je 0x4068c4
mov eax, dword [ebp - 0x34c]
mov dword [esp + 4], eax
mov eax, dword [0x4190f4]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_AssignProcessToJobObject]
sub esp, 8
test eax, eax
jne 0x4064e1
test byte [0x419030], 2
jne 0x406cfc
mov eax, dword [ebp - 0x344]
xor esi, esi
mov dword [ebx + 0x14], eax
mov eax, dword [ebp - 0x34c]
mov dword [ebx + 0x18], eax
mov eax, dword [ebp - 0x348]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CloseHandle]
mov eax, dword [ebp - 0x380]
sub esp, 4
mov dword [eax], ebx
lea esp, [ebp - 0xc]
mov eax, esi
pop ebx
pop esi
pop edi
pop ebp
ret
lea edx, [ebp - 0x220]
mov eax, dword [ebx + 0x34]
mov dword [ebp - 0x370], edx
mov edx, dword [sym.imp.ucrtbase.dll_free]
mov esi, eax
mov dword [ebp - 0x374], edx
and esi, 3
jne 0x4061f0
mov ebx, dword [ebp - 0x370]
mov dword [esp + 4], 0x104
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_GetSystemDirectoryW]
sub esp, 8
cmp word [ebp - 0x220], 0
je 0x4070ba
mov ecx, ebx
add ecx, 2
cmp word [ecx], 0
jne 0x406570
sub ecx, dword [ebp - 0x370]
mov dword [ebp - 0x374], ecx
mov eax, ecx
sar eax, 1
mov dword [esp + 8], eax
mov ebx, dword [ebp - 0x370]
mov eax, dword [ebp - 0x378]
mov dword [esp], ebx
mov dword [esp + 4], eax
call dword [sym.imp.ucrtbase.dll__wcsnicmp]
test eax, eax
jne 0x406a68
mov dword [ebp - 0x370], ebx
mov dword [esp], ebx
mov dword [esp + 4], 0x104
call dword [sym.imp.kernel32.dll_GetSystemWow64DirectoryW]
mov eax, dword [ebp - 0x378]
mov ebx, dword [sym.imp.ucrtbase.dll_wcslen]
sub esp, 8
mov dword [esp], eax
call ebx
mov edx, dword [ebp - 0x370]
mov dword [ebp - 0x384], eax
mov dword [esp], edx
call ebx
add eax, dword [ebp - 0x384]
add eax, eax
mov dword [esp], eax
call edi
mov ebx, eax
test eax, eax
je 0x406872
mov ecx, dword [ebp - 0x370]
xor eax, eax
lea esi, [esi]
movzx edx, word [ecx + eax]
mov word [ebx + eax], dx
add eax, 2
test dx, dx
jne 0x406610
mov ecx, dword [ebp - 0x374]
add ecx, dword [ebp - 0x378]
mov eax, ebx
cmp word [ebx], 0
je 0x406648
lea esi, [esi]
add eax, 2
cmp word [eax], 0
jne 0x406638
lea esi, [esi]
movzx edx, word [ecx + esi]
mov word [eax + esi], dx
add esi, 2
test dx, dx
jne 0x406648
mov eax, dword [ebp - 0x378]
mov dword [esp], eax
mov eax, dword [sym.imp.ucrtbase.dll_free]
mov dword [ebp - 0x374], eax
call eax
test byte [0x419030], 8
jne 0x406c2c
mov eax, dword [ebp - 0x36c]
mov dword [ebp - 0x378], ebx
mov eax, dword [eax + 0x34]
jmp 0x4061f0
mov ebx, dword [ebp - 0x370]
mov dword [esp + 4], 0x104
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_GetSystemDirectoryW]
mov eax, dword [ebp - 0x378]
sub esp, 8
mov dword [esp], eax
mov eax, dword [ebp - 0x374]
call eax
mov dword [esp], ebx
call dword [sym.imp.ucrtbase.dll_wcslen]
lea eax, [eax + eax + 0x20]
mov dword [esp], eax
call edi
mov dword [ebp - 0x384], eax
mov ecx, eax
test eax, eax
je 0x406881
xor eax, eax
nop
movzx edx, word [ebx + eax]
mov word [ecx + eax], dx
add eax, 2
test dx, dx
jne 0x4066e0
mov edx, dword [ebp - 0x384]
cmp word [edx], 0
je 0x406fd9
add edx, 2
cmp word [edx], 0
jne 0x406700
xor eax, eax
mov ecx, 0x5c
jmp 0x40671f
movzx ecx, word [eax + str.winedevice.exe]
mov word [edx + eax], cx
add eax, 2
test cx, cx
jne 0x406718
mov eax, dword [ebp - 0x36c]
mov ecx, dword [eax + 8]
mov edx, dword [eax + 0x44]
mov dword [ebp - 0x378], ecx
lea ebx, [ecx + 0x10]
test edx, edx
je 0x4068fd
mov esi, dword [ecx + 0x10]
cmp ebx, esi
je 0x4068fd
mov edi, dword [sym.imp.kernel32.dll_lstrcmpW]
mov ebx, eax
lea esi, [esi]
nop
mov eax, dword [esi + 0x18]
sub eax, 2
and eax, 0xfffffffd
jne 0x4068e8
mov eax, dword [esi + 0x68]
test eax, eax
je 0x4068e8
mov eax, dword [esi + 0x78]
test eax, eax
jne 0x4068e8
mov eax, dword [esi + 0x40]
test eax, eax
je 0x4068e8
mov edx, dword [ebp - 0x384]
mov dword [esp], eax
mov dword [esp + 4], edx
call edi
sub esp, 8
test eax, eax
jne 0x4068e0
mov eax, dword [esi + 0x44]
test eax, eax
je 0x4068e0
mov edx, dword [ebx + 0x44]
mov dword [esp], eax
mov dword [esp + 4], edx
call edi
sub esp, 8
test eax, eax
jne 0x4068e0
mov ebx, dword [esi + 0x68]
test ebx, ebx
je 0x406b6f
lea esi, [ebx + 0xc]
lock inc dword [esi]
mov eax, dword [ebp - 0x384]
mov dword [esp], eax
mov eax, dword [ebp - 0x374]
call eax
mov edi, dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov eax, dword [ebp - 0x36c]
mov dword [eax + 0x18], 2
mov dword [eax + 0x1c], 0
mov eax, dword [eax + 0x30]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_ResetEvent]
sub esp, 4
lock inc dword [esi]
mov eax, dword [ebp - 0x36c]
mov esi, dword [ebp - 0x37c]
mov dword [eax + 0x68], ebx
mov dword [esi], 1
mov dword [eax + 0x6c], 1
inc dword [ebx + 0x10]
mov eax, dword [eax + 8]
add eax, 0x18
mov dword [esp], eax
call edi
sub esp, 4
mov dword [esp + 4], 0x7530
mov eax, dword [ebx + 0x1c]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_WaitForSingleObject]
sub esp, 8
mov esi, eax
test eax, eax
jne 0x406d6b
mov eax, dword [ebp - 0x380]
mov dword [eax], ebx
jmp 0x40689e
mov eax, dword [ebp - 0x378]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_free]
mov eax, dword [ebp - 0x36c]
mov esi, 0x46a
mov eax, dword [eax + 8]
add eax, 0x18
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
sub esp, 4
lea esp, [ebp - 0xc]
mov eax, esi
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [ebp - 0x34c]
mov edx, dword [0x419240]
inc eax
cmp eax, edx
cmovb eax, edx
mov dword [0x419240], eax
jmp 0x40625e
mov eax, dword fs:[0x18]
mov esi, dword [eax + 0x34]
mov dword [esp], ebx
call sym._process_terminate
mov dword [esp], ebx
call sym._release_process
jmp 0x40689e
mov ecx, dword [ebx + 8]
lea esi, [esi]
nop
mov esi, dword [esi]
lea eax, [ecx + 0x10]
cmp esi, eax
jne 0x406760
mov dword [ebp - 0x378], ecx
mov ebx, eax
mov esi, dword [sym.imp.ucrtbase.dll__wcsicmp]
lea esi, [esi]
nop
mov eax, dword [0x41906c]
mov dword [esp + 8], str.Winedevice_u
mov dword [esp + 4], 0x17
inc eax
mov dword [esp], 0x4191e0
mov dword [esp + 0xc], eax
mov dword [0x41906c], eax
call sym._swprintf
mov eax, dword [ebp - 0x378]
mov edi, dword [eax + 0x10]
cmp ebx, edi
je 0x40695a
mov eax, dword [edi + 0x10]
mov dword [esp], 0x4191e0
mov dword [esp + 4], eax
call esi
test eax, eax
je 0x406908
mov edi, dword [edi]
cmp ebx, edi
jne 0x406940
lea eax, [ebp - 0x34c]
mov dword [esp], 0x4191e0
mov dword [esp + 4], eax
call sym._service_create
mov esi, eax
test eax, eax
je 0x406d80
mov eax, dword [ebp - 0x384]
mov dword [esp], eax
mov eax, dword [ebp - 0x374]
call eax
mov eax, dword [ebp - 0x36c]
mov eax, dword [eax + 8]
add eax, 0x18
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
sub esp, 4
jmp 0x40689e
mov eax, dword fs:[0x18]
mov esi, dword [eax + 0x34]
mov eax, dword [ebx + 0x24]
test eax, eax
je 0x4069cc
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CloseHandle]
sub esp, 4
mov dword [esp], ebx
mov eax, dword [ebp - 0x374]
call eax
test esi, esi
je 0x40639a
test byte [0x419030], 2
jne 0x406a82
mov eax, dword [ebp - 0x36c]
mov eax, dword [eax + 8]
add eax, 0x18
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov eax, dword [ebp - 0x378]
sub esp, 4
mov dword [esp], eax
mov eax, dword [ebp - 0x374]
call eax
lea esp, [ebp - 0xc]
mov eax, esi
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword fs:[0x18]
mov esi, dword [eax + 0x34]
mov eax, dword [ebx + 0x1c]
test eax, eax
je 0x4069cc
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CloseHandle]
sub esp, 4
jmp 0x4069b9
mov eax, dword [eax + 8]
mov esi, 0x420
add eax, 0x18
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
sub esp, 4
jmp 0x40689e
mov eax, dword [ebp - 0x36c]
mov esi, dword [sym.imp.ucrtbase.dll_free]
mov eax, dword [eax + 0x34]
mov dword [ebp - 0x374], esi
jmp 0x4061f0
mov eax, dword [ebp - 0x36c]
mov ebx, dword [eax + 0x10]
test ebx, ebx
je 0x4070cb
mov eax, ebx
shr eax, 0x10
je 0x406d25
mov dword [esp + 4], 0xffffffff
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, 0x41a579
sub esp, 8
test eax, eax
jne 0x406d3a
cmp word [ebx], 0
je 0x407166
lea esi, [esi]
mov edx, eax
lea eax, [eax + 1]
cmp word [ebx + edx*2 + 2], 0
jne 0x406ad0
mov ecx, 0x224c
lea edi, [ebp - 0x21e]
mov word [ebp - 0x220], cx
jmp 0x406b3b
cmp ax, 9
je 0x406fc8
cmp ax, 0xa
jne 0x406f59
mov eax, 0x6e5c
add edi, 2
mov word [edi - 2], ax
lea esi, [esi]
nop
lea eax, [edx - 1]
test edx, edx
jle 0x407043
lea ecx, [ebp - 0xfe]
cmp edi, ecx
ja 0x407043
mov edx, eax
movzx eax, word [ebx]
add ebx, 2
cmp ax, 0xd
je 0x406f3b
jbe 0x406af8
cmp ax, 0x22
je 0x406fb0
cmp ax, 0x5c
jne 0x406f4c
mov ecx, 0x5c5c
add edi, 2
mov word [edi - 2], cx
jmp 0x406b20
mov eax, dword [ebp - 0x36c]
mov eax, dword [eax + 8]
mov dword [ebp - 0x378], eax
lea ebx, [eax + 0x10]
jmp 0x4068fd
mov eax, dword fs:[0x18]
mov esi, dword [eax + 0x34]
mov eax, dword [ebx + 0x1c]
test eax, eax
jne 0x406a30
jmp 0x4069b9
lea eax, [ebp - 0x360]
mov dword [esp + 4], 0xa
mov dword [esp + 8], eax
mov dword [esp], 0xffffffff
call dword [sym.imp.advapi32.dll_OpenProcessToken]
sub esp, 0xc
test eax, eax
je 0x4063d9
mov eax, dword [ebp - 0x360]
mov dword [esp + 8], 0
mov dword [esp], 0x4190e0
mov dword [esp + 4], eax
call sym._CreateEnvironmentBlock_12
lea eax, [ebp - 0x34c]
sub esp, 0xc
mov dword [esp + 8], 0x10
mov dword [esp + 4], eax
mov dword [esp], str.WINEBOOTSTRAPMODE
call dword [sym.imp.kernel32.dll_GetEnvironmentVariableW]
sub esp, 0xc
test eax, eax
jne 0x4071eb
mov eax, dword [ebp - 0x360]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CloseHandle]
sub esp, 4
jmp 0x4063d9
mov eax, ebx
shr eax, 0x10
je 0x407187
mov dword [esp + 4], 0xffffffff
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, eax
sub esp, 8
mov eax, 0x41a579
test edx, edx
jne 0x407016
movzx eax, word [ebx]
test ax, ax
je 0x4071a7
mov ecx, edx
lea edx, [edx + 1]
cmp word [ebx + ecx*2 + 2], 0
jne 0x406c66
mov edx, 0x224c
mov dword [ebp - 0x378], ebx
lea esi, [ebp - 0x34a]
mov word [ebp - 0x34c], dx
jmp 0x406ccb
cmp ax, 9
je 0x4070d5
cmp ax, 0xa
jne 0x4070f3
mov eax, 0x6e5c
add esi, 2
mov word [esi - 2], ax
lea edx, [ecx - 1]
test ecx, ecx
jle 0x406fe4
lea eax, [ebp - 0x22a]
cmp esi, eax
ja 0x406fe4
movzx eax, word [ebx]
mov ecx, edx
add ebx, 2
cmp ax, 0xd
je 0x407155
jbe 0x406c8d
cmp ax, 0x22
je 0x407144
cmp ax, 0x5c
jne 0x4070e6
mov eax, 0x5c5c
add esi, 2
mov word [esi - 2], ax
jmp 0x406cad
mov dword [esp + 0xc], str.Could_not_add_object_to_job._n
mov dword [esp + 8], str.service_start_process
mov dword [esp + 4], 0x419030
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x4064e1
movzx ebx, bx
mov dword [esp], 0x41a56c
mov dword [esp + 4], ebx
call sym._wine_dbg_sprintf.constprop.0_1
mov edx, eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], str.failed_to_create_process_object_for__s__error___lu_n
mov dword [esp + 8], str.service_start_process
mov dword [esp + 4], 0x419030
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x4069ec
mov dword [esp], ebx
mov esi, 0x41d
call sym._release_process
jmp 0x40689e
mov edx, dword [ebp - 0x34c]
mov eax, dword [ebp - 0x384]
mov esi, dword [sym.imp.ucrtbase.dll__wcsdup]
mov dword [edx + 0x78], 0
mov dword [edx + 0x34], 0x10
mov dword [edx + 0x38], 3
mov dword [edx + 0x14], 0x10
mov dword [ebp - 0x38c], edx
mov dword [esp], eax
call esi
mov edx, dword [ebp - 0x38c]
mov dword [edx + 0x40], eax
test eax, eax
je 0x407076
mov edx, dword [ebp - 0x34c]
mov dword [esp], str.LocalSystem
mov dword [ebp - 0x38c], edx
call esi
mov edx, dword [ebp - 0x38c]
mov dword [edx + 0x50], eax
test eax, eax
je 0x407076
mov edx, dword [ebp - 0x34c]
mov dword [esp], 0x4191e0
mov dword [ebp - 0x38c], edx
call esi
mov edx, dword [ebp - 0x38c]
mov dword [edx + 0x54], eax
test eax, eax
je 0x407076
mov eax, dword [ebp - 0x36c]
mov eax, dword [eax + 0x44]
test eax, eax
je 0x406e45
mov edx, dword [ebp - 0x34c]
mov dword [esp], eax
mov dword [ebp - 0x38c], edx
call esi
mov edx, dword [ebp - 0x38c]
mov dword [edx + 0x44], eax
test eax, eax
je 0x407076
mov eax, dword [ebp - 0x34c]
mov ecx, dword [ebp - 0x378]
mov dword [eax], ebx
mov dword [eax + 8], ecx
mov edx, dword [ecx + 0x14]
mov dword [eax + 4], edx
mov dword [edx], eax
mov dword [ecx + 0x14], eax
mov eax, dword [ebp - 0x384]
mov ebx, dword [ebp - 0x34c]
mov dword [ebx + 0x74], 1
mov dword [esp], eax
mov eax, dword [ebp - 0x374]
call eax
mov eax, dword [ebx + 0x44]
mov dword [esp], eax
call esi
mov esi, dword [ebp - 0x36c]
mov edi, dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov dword [ebp - 0x220], eax
mov esi, dword [esi + 8]
lea eax, [esi + 0x18]
mov dword [ebp - 0x378], esi
mov dword [esp], eax
call edi
mov edx, dword [ebp - 0x220]
xor eax, eax
mov esi, dword [ebp - 0x370]
sub esp, 4
test edx, edx
mov dword [esp + 8], esi
setne al
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x34c]
mov dword [esp], eax
call sym._service_start
mov esi, eax
mov eax, dword [ebp - 0x220]
mov dword [esp], eax
mov eax, dword [ebp - 0x374]
call eax
test esi, esi
jne 0x40709f
mov eax, dword [ebp - 0x36c]
mov eax, dword [eax + 8]
mov dword [ebp - 0x370], eax
add eax, 0x18
mov dword [esp], eax
mov eax, dword [ebp - 0x388]
call eax
mov eax, dword [ebp - 0x34c]
sub esp, 4
mov ebx, dword [eax + 0x68]
test ebx, ebx
je 0x4071c5
lea esi, [ebx + 0xc]
lock inc dword [esi]
mov eax, dword [ebp - 0x34c]
mov dword [esp], eax
call sym._release_service
jmp 0x4067f4
mov eax, 0x725c
add edi, 2
mov word [edi - 2], ax
jmp 0x406b20
lea ecx, [eax - 0x20]
cmp cx, 0x5e
jbe 0x4070b2
mov ecx, eax
mov byte [edi], 0x5c
add edi, 5
shr cx, 0xc
movzx ecx, cx
movzx ecx, byte [ecx + 0x41c46c]
mov byte [edi - 4], cl
mov ecx, eax
shr cx, 8
and ecx, 0xf
movzx ecx, byte [ecx + 0x41c46c]
mov byte [edi - 3], cl
mov ecx, eax
and eax, 0xf
shr cx, 4
movzx eax, byte [eax + 0x41c46c]
and ecx, 0xf
movzx ecx, byte [ecx + 0x41c46c]
mov byte [edi - 1], al
mov byte [edi - 2], cl
jmp 0x406b20
mov eax, 0x225c
add edi, 2
mov word [edi - 2], ax
jmp 0x406b20
mov eax, 0x745c
add edi, 2
mov word [edi - 2], ax
jmp 0x406b20
mov edx, dword [ebp - 0x384]
jmp 0x406709
mov byte [esi], 0x22
mov ebx, dword [ebp - 0x378]
test edx, edx
jle 0x4071bd
mov ecx, 0x2e2e
mov byte [esi + 3], 0x2e
lea eax, [esi + 4]
mov word [esi + 1], cx
mov byte [eax], 0
lea eax, [ebp - 0x34c]
mov dword [esp], eax
call sym.___wine_dbg_strdup
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.redirected_to__s_n
mov dword [esp + 8], str.get_service_binary_path
mov dword [esp + 4], 0x419030
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x40667b
mov byte [edi], 0x22
test eax, eax
jle 0x40717f
mov edx, 0x2e2e
mov byte [edi + 3], 0x2e
lea eax, [edi + 4]
mov word [edi + 1], dx
mov byte [eax], 0
mov eax, dword [ebp - 0x370]
mov dword [esp], eax
call sym.___wine_dbg_strdup
mov edx, eax
jmp 0x406d3a
mov eax, dword [ebp - 0x34c]
mov esi, 0x46a
mov dword [esp], eax
call sym._free_service_entry
mov eax, dword [ebp - 0x384]
mov dword [esp], eax
mov eax, dword [ebp - 0x374]
call eax
jmp 0x40698b
mov eax, dword [ebp - 0x34c]
mov dword [esp], eax
call sym._release_service
jmp 0x40689e
mov byte [edi], al
inc edi
jmp 0x406b20
mov dword [ebp - 0x374], 0
xor eax, eax
jmp 0x406589
mov edx, 0x41a572
jmp 0x406d3a
mov eax, 0x745c
add esi, 2
mov word [esi - 2], ax
jmp 0x406cad
lea edx, [eax - 0x20]
cmp dx, 0x5e
jbe 0x40719f
mov edx, eax
mov byte [esi], 0x5c
add esi, 5
shr dx, 0xc
movzx edx, dx
movzx edx, byte [edx + 0x41c46c]
mov byte [esi - 4], dl
mov edx, eax
shr dx, 8
and edx, 0xf
movzx edx, byte [edx + 0x41c46c]
mov byte [esi - 3], dl
mov edx, eax
and eax, 0xf
shr dx, 4
movzx eax, byte [eax + 0x41c46c]
and edx, 0xf
movzx edx, byte [edx + 0x41c46c]
mov byte [esi - 1], al
mov byte [esi - 2], dl
jmp 0x406cad
mov eax, 0x225c
add esi, 2
mov word [esi - 2], ax
jmp 0x406cad
mov eax, 0x725c
add esi, 2
mov word [esi - 2], ax
jmp 0x406cad
mov ebx, 0x224c
mov byte [ebp - 0x21e], 0x22
lea edi, [ebp - 0x21e]
mov word [ebp - 0x220], bx
lea eax, [edi + 1]
jmp 0x40705e
movzx eax, bx
mov dword [esp], 0x41a56c
mov dword [esp + 4], eax
call sym._wine_dbg_sprintf.constprop.0_1
jmp 0x407016
mov byte [esi], al
inc esi
jmp 0x406cad
mov word [ebp - 0x34c], 0x224c
lea esi, [ebp - 0x34a]
mov byte [ebp - 0x34a], 0x22
lea eax, [esi + 1]
jmp 0x407005
mov dword [esp], eax
mov esi, 0x41d
call sym._release_service
mov eax, dword [ebp - 0x36c]
mov eax, dword [eax + 8]
add eax, 0x18
mov dword [esp], eax
call edi
sub esp, 4
jmp 0x40689e
mov dword [ebp - 0x35c], 0x240022
lea eax, [ebp - 0x34c]
mov dword [esp + 4], eax
lea eax, [ebp - 0x354]
mov dword [esp], eax
mov dword [ebp - 0x358], str.WINEBOOTSTRAPMODE
call dword [sym.imp.ntdll.dll_RtlInitUnicodeString]
lea eax, [ebp - 0x354]
sub esp, 8
mov dword [esp + 8], eax
lea eax, [ebp - 0x35c]
mov dword [esp + 4], eax
mov dword [esp], 0x4190e0
call dword [sym.imp.ntdll.dll_RtlSetEnvironmentVariable]
sub esp, 0xc
jmp 0x406c15
mov esi, 0x46a
jmp 0x4069df