Function at 0x100035c0
Capabilities:
Create service
Get common file path
Modify service
Persist via windows service

Disassembly:
sub esp, 0x630
mov eax, dword [0x1002b1c0]
xor eax, esp
mov dword [esp + 0x62c], eax
push ebx
push esi
push edi
xor esi, esi
push 0x206
mov edi, ecx
lea ecx, [esp + 0x436]
mov ebx, edx
xor eax, eax
push esi
push ecx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x1c], esi
mov dword [esp + 0x20], esi
mov dword [esp + 0x24], esi
mov dword [esp + 0x18], esi
mov word [esp + 0x43c], ax
call fcn.1000de50
add esp, 0xc
cmp edi, esi
je 0x1000387f
cmp ebx, esi
je 0x1000387f
lea ecx, [esp + 0x10]
call fcn.100040f0
test eax, eax
jne 0x1000385d
push 0x206
lea eax, [esp + 0x22e]
xor edx, edx
push esi
push eax
mov word [esp + 0x234], dx
call fcn.1000de50
add esp, 0xc
push 0x104
lea ecx, [esp + 0x22c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
push 0x206
lea eax, [esp + 0x26]
xor edx, edx
push esi
push eax
mov word [esp + 0x2c], dx
call fcn.1000de50
push edi
lea ecx, [esp + 0x238]
push ecx
push str._s_svchost.exe__k__s
mov ecx, 0x104
lea ebx, [esp + 0x38]
call fcn.10002680
mov eax, edi
add esp, 0x18
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, si
jne 0x100036a0
sub eax, edx
mov edx, dword [esp + 0x10]
sar eax, 1
push edi
lea ecx, [eax + eax + 2]
push edx
mov ebx, 7
call fcn.10004040
test eax, eax
jne 0x10003838
push ebp
push 0xf003f
push esi
push esi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov ebp, eax
cmp ebp, esi
je 0x1000382d
push esi
push esi
push esi
push esi
push esi
lea eax, [esp + 0x38]
push eax
push 1
push 2
push 0x10
push 0xf01ff
push esi
push edi
push ebp
call dword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov esi, eax
test esi, esi
jne 0x1000378e
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
mov dword [esp + 0x10], eax
cmp eax, 0x431
jne 0x10003733
push 0xf01ff
push edi
push ebp
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov esi, eax
test esi, esi
jne 0x10003766
call ebx
call ebx
mov dword [esp + 0x10], eax
push ebp
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov ecx, dword [esp + 0x14]
pop ebp
call fcn.10003f00
mov eax, dword [esp + 0xc]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x62c]
xor ecx, esp
call fcn.1000c9db
add esp, 0x630
ret
push 0
push 0
push 0
push 0
push 0
push 0
lea ecx, [esp + 0x3c]
push ecx
push 1
push 2
push 0x10
push esi
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigW]
test eax, eax
jne 0x1000378e
call ebx
mov dword [esp + 0x10], eax
push edi
push 0x100270b8
push 0x100275e4
mov ecx, 0x104
lea ebx, [esp + 0x440]
call fcn.10002680
mov edi, ebx
add esp, 0xc
lea ecx, [esp + 0x18]
mov ebx, 0x80000002
call fcn.10003f90
test eax, eax
jne 0x10003821
mov ebx, dword [esp + 0x18]
lea ecx, [esp + 0x1c]
mov edi, str.Parameters
call fcn.10003f90
test eax, eax
jne 0x10003818
mov edi, dword [esp + 0x20]
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x100037e0
sub eax, edx
mov edx, dword [esp + 0x1c]
sar eax, 1
push str.ServiceDll
lea ecx, [eax + eax + 2]
push edx
mov ebx, 2
call fcn.10004040
test eax, eax
jne 0x1000380f
mov dword [esp + 0x10], eax
mov ecx, dword [esp + 0x1c]
call fcn.10003f00
mov ecx, dword [esp + 0x18]
call fcn.10003f00
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x10003739
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 0x10], eax
pop ebp
mov ecx, dword [esp + 0x10]
call fcn.10003f00
mov eax, dword [esp + 0xc]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x62c]
xor ecx, esp
call fcn.1000c9db
add esp, 0x630
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
pop esi
mov dword [esp + 4], eax
pop ebx
mov ecx, dword [esp + 0x62c]
xor ecx, esp
call fcn.1000c9db
add esp, 0x630
ret
mov ecx, dword [esp + 0x638]
pop edi
pop esi
pop ebx
xor ecx, esp
mov eax, 0x57
call fcn.1000c9db
add esp, 0x630
ret