Function at 0x4026f0
Capabilities:
Create service
Delete service
Get common file path
Persist via windows service
Print debug messages
Start service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x124
mov eax, dword [0x425a8c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
call fcn.00401230
cmp eax, 4
jl 0x402755
call fcn.00401360
cmp eax, 1
jne 0x402755
push 0x41e66c
mov dword [ebp - 0x108], 0
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov esi, eax
test esi, esi
je 0x402755
push str.Wow64DisableWow64FsRedirection
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x40274e
lea ecx, [ebp - 0x108]
push ecx
call eax
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
push 0x80
lea edx, [ebp - 0x84]
push edx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea eax, [ebp - 0x84]
dec eax
mov edi, edi
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x402770
mov ecx, dword [str.DriversSSPORT.sys]
mov edx, dword [0x41e724]
mov ebx, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov dword [eax], ecx
mov ecx, dword [0x41e728]
mov dword [eax + 4], edx
mov edx, dword [0x41e72c]
mov dword [eax + 8], ecx
mov ecx, dword [0x41e730]
mov dword [eax + 0xc], edx
push str.Port_Contetion_Driver_install_n
mov dword [eax + 0x10], ecx
call ebx
mov esi, dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
push 0xf003f
push 0
push 0
call esi
mov edi, eax
test edi, edi
jne 0x4027cf
push str.MDM_::_OpenSCManager_Error__n
call ebx
push ecx
lea edx, [ebp - 0x84]
mov ecx, esp
mov dword [ebp - 0x108], esp
push edx
call fcn.004019b0
call fcn.00401740
add esp, 4
test al, al
jne 0x402851
push str.Cant_find_ssport.sys_in_drivers_folder
call ebx
push 0xf003f
push 0
push 0
call esi
mov esi, eax
test esi, esi
jne 0x40280f
push str.MDM_::_OpenSCManager_Error__n
call ebx
push 0xf01ff
push str.SSPORT
push esi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push str.SYSTEMCurrentControlSetServicesSSPORT
push 0x80000002
call fcn.00401110
add esp, 8
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040ca0e
mov esp, ebp
pop ebp
ret
push 0xf01ff
push str.SSPORT
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
test esi, esi
jne 0x4028ef
push 0x80
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea eax, [ebp - 0x104]
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x402885
mov ecx, dword [str.DriversSSPORT.sys]
mov edx, dword [0x41e724]
push 0
push 0
push 0
mov dword [eax], ecx
mov ecx, dword [0x41e728]
push 0
mov dword [eax + 4], edx
mov edx, dword [0x41e72c]
push 0
mov dword [eax + 8], ecx
mov ecx, dword [0x41e730]
mov dword [eax + 0xc], edx
lea edx, [ebp - 0x104]
push edx
push 1
push 2
push 1
push 0xf01ff
push str.SSPORT
push str.SSPORT
push edi
mov dword [eax + 0x10], ecx
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
mov esi, eax
test esi, esi
jne 0x4028ef
push eax
jmp 0x40294e
lea eax, [ebp - 0x124]
push eax
push 4
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
cmp dword [ebp - 0x120], 4
je 0x40294d
push 0
push 0
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceA]
test eax, eax
jne 0x40291e
push str.SSPort_driver_could_not_start_Error__n
call ebx
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
xor edi, edi
push 0x64
call ebx
lea ecx, [ebp - 0x124]
push ecx
push 4
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x402947
cmp dword [ebp - 0x120], 4
je 0x40294d
inc edi
cmp edi, 0xa
jl 0x402926
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040ca0e
mov esp, ebp
pop ebp
ret