Function at 0x476360
Capabilities:
Acquire debug privileges
Copy file
Delete file
Delete registry key
Get common file path
Persist via windows service
Query environment variable
Set file attributes
Set registry value

Disassembly:
sub esp, 0xd7c
push ebx
push ebp
push esi
push edi
mov esi, ecx
push str.ntdll.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov edi, eax
xor ebx, ebx
cmp edi, ebx
jne 0x47638f
pop edi
pop esi
pop ebp
mov eax, 0x20
pop ebx
add esp, 0xd7c
ret
mov ebp, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.RtlAnsiStringToUnicodeString
push edi
call ebp
push str.RtlFreeUnicodeString
push edi
mov dword [0x4faf5c], eax
call ebp
push str.NtLoadDriver
push edi
mov dword [0x4faf60], eax
call ebp
mov dword [0x4faf64], eax
call dword [sym.imp.KERNEL32.dll_GetVersion]
cmp eax, 0x80000000
setb al
cmp al, bl
mov byte [esi + 0xd], al
jne 0x4763e1
pop edi
pop esi
pop ebp
mov eax, 0x60
pop ebx
add esp, 0xd7c
ret
lea eax, [esp + 0x138]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
push str.FILEM701.SYS
lea ecx, [esp + 0x13c]
push 0x4ee128
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea edx, [esp + eax + 0x140]
push edx
call fcn.00467d68
add esp, 0xc
lea eax, [esp + 0x444]
lea ecx, [esp + 0x138]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
jne 0x47646a
lea edx, [esp + 0x34]
lea eax, [esp + 0x138]
push edx
push eax
push 0x104
push ebx
push str.FILEM701.SYS
push ebx
call dword [sym.imp.KERNEL32.dll_SearchPathA]
test eax, eax
jne 0x476471
pop edi
pop esi
pop ebp
mov eax, 0x20
pop ebx
add esp, 0xd7c
ret
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
lea ecx, [esp + 0x340]
push 0x104
push ecx
push str.SYSTEMROOT
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
test eax, eax
jne 0x47649d
pop edi
pop esi
pop ebp
mov eax, 0x20
pop ebx
add esp, 0xd7c
ret
lea edx, [esp + 0x340]
push str.FILEM701.SYS
push edx
lea eax, [esp + 0x244]
push str._s_system32drivers_s
push eax
call fcn.00467d68
add esp, 0x10
lea ecx, [esp + 0x23c]
lea edx, [esp + 0x138]
push ebx
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
jne 0x4764ea
pop edi
pop esi
pop ebp
mov eax, 0x10
pop ebx
add esp, 0xd7c
ret
lea eax, [esp + 0x23c]
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push str.SeDebugPrivilege
mov ecx, esi
call fcn.00476d40
push str.SeLoadDriverPrivilege
mov ecx, esi
call fcn.00476d40
push str.FILEMON701
lea ecx, [esp + 0x3c]
push str.SystemCurrentControlSetServices_s
push ecx
call fcn.00467d68
add esp, 0xc
mov byte [esp + eax + 0x38], bl
lea edx, [esp + 0x14]
lea eax, [esp + 0x38]
push edx
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
mov edx, dword [esp + 0x14]
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
lea ecx, [esp + 0x10]
push 4
push ecx
push 4
push ebx
mov ebp, 1
push str.Type
push edx
mov dword [esp + 0x28], ebp
call edi
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x10]
push 4
push eax
push 4
push ebx
push str.ErrorControl
push ecx
mov dword [esp + 0x28], ebp
call edi
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x10]
push 4
push edx
push 4
push ebx
push str.Start
push eax
mov dword [esp + 0x28], 3
call edi
lea ecx, [esp + 0x340]
push str.FILEM701.SYS
push ecx
lea edx, [esp + 0x40]
push str.___s_system32Drivers_s
push edx
call fcn.00467d68
add esp, 0x10
mov ecx, dword [esp + 0x14]
mov byte [esp + eax + 0x38], bl
push eax
lea eax, [esp + 0x3c]
push eax
push ebp
push ebx
push str.ImagePath
push ecx
call edi
mov edx, dword [esp + 0x14]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push str.FILEMON701
lea eax, [esp + 0x3c]
push str.RegistryMachineSystemCurrentControlSetServices_s
push eax
call fcn.00467d68
add esp, 0xc
mov byte [esp + eax + 0x38], bl
mov word [esp + 0x24], ax
lea edx, [esp + 0x24]
push ebp
lea eax, [esp + 0x30]
lea ecx, [esp + 0x3c]
push edx
push eax
mov dword [esp + 0x34], ecx
call dword [0x4faf5c]
lea ecx, [esp + 0x2c]
push ecx
call dword [0x4faf64]
lea edx, [esp + 0x2c]
mov edi, eax
push edx
call dword [0x4faf60]
cmp edi, ebx
je 0x476659
cmp edi, 0xc000010e
je 0x476659
cmp edi, 0xc0000035
je 0x476659
pop edi
pop esi
pop ebp
mov eax, 0x65
pop ebx
add esp, 0xd7c
ret
push str.FILEMON701
lea eax, [esp + 0x3c]
push str.SystemCurrentControlSetServices_sENUM
push eax
call fcn.00467d68
mov edi, dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
add esp, 0xc
lea ecx, [esp + 0x38]
mov byte [esp + eax + 0x38], bl
push ecx
push 0x80000002
call edi
push str.FILEMON701
lea edx, [esp + 0x3c]
push str.SystemCurrentControlSetServices_sSecurity
push edx
call fcn.00467d68
add esp, 0xc
mov byte [esp + eax + 0x38], bl
lea eax, [esp + 0x38]
push eax
push 0x80000002
call edi
push str.FILEMON701
lea ecx, [esp + 0x3c]
push str.SystemCurrentControlSetServices_s
push ecx
call fcn.00467d68
add esp, 0xc
lea edx, [esp + 0x38]
mov byte [esp + eax + 0x38], bl
push edx
push 0x80000002
call edi
push str.FILEMON701
lea eax, [esp + 0x3c]
push str.._s
push eax
call fcn.00467d68
add esp, 0xc
mov edi, dword [sym.imp.KERNEL32.dll_CreateFileA]
lea ecx, [esp + 0x38]
mov byte [esp + eax + 0x38], bl
push ebx
push 0x80
push 3
push ebx
push ebx
push 0xc0000000
push ecx
call edi
cmp eax, 0xffffffff
mov dword [esi + 0x10008], eax
jne 0x476762
push str.FILEMON701
lea edx, [esp + 0x3c]
push str..Global_s
push edx
call fcn.00467d68
add esp, 0xc
mov byte [esp + eax + 0x38], bl
lea eax, [esp + 0x38]
push ebx
push 0x80
push 3
push ebx
push ebx
push 0xc0000000
push eax
call edi
cmp eax, 0xffffffff
mov dword [esi + 0x10008], eax
jne 0x476762
pop edi
pop esi
pop ebp
mov eax, 0x63
pop ebx
add esp, 0xd7c
ret
lea ecx, [esp + 0x23c]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ecx, dword [esi + 0x10008]
lea edx, [esp + 0x18]
mov ebp, dword [sym.imp.KERNEL32.dll_DeviceIoControl]
push ebx
push edx
lea eax, [esp + 0x24]
push 4
push eax
push ebx
push ebx
push 0x8300001c
push ecx
call ebp
test eax, eax
je 0x4768b2
cmp dword [esp + 0x1c], 0x384
jne 0x4768b2
mov eax, dword [esi + 0x10008]
lea edx, [esp + 0x18]
push ebx
push edx
push ebx
push ebx
push ebx
push ebx
push 0x83000004
push eax
call ebp
test eax, eax
jne 0x4767d5
pop edi
pop esi
pop ebp
mov eax, 0x10
pop ebx
add esp, 0xd7c
ret
mov ecx, 0x100
xor eax, eax
lea edi, [esp + 0x584]
lea edx, [esp + 0x18]
rep stosd dword es:[edi], eax
mov ecx, 0x100
lea edi, [esp + 0x984]
rep stosd dword es:[edi], eax
mov ecx, 0x1010101
push ebx
mov dword [esp + 0xd88], ecx
push edx
mov word [esp + 0xd90], cx
push ebx
push ebx
lea eax, [esp + 0x594]
mov byte [esp + 0xd9a], cl
mov ecx, dword [esi + 0x10008]
push 0x807
push eax
push 0x83000018
push ecx
mov byte [esp + 0x5a4], 0x2a
call ebp
test eax, eax
jne 0x47684d
pop edi
pop esi
pop ebp
mov eax, 0x66
pop ebx
add esp, 0xd7c
ret
mov eax, dword [esi + 0x10008]
lea edx, [esp + 0x18]
push ebx
push edx
push ebx
push ebx
push ebx
push ebx
push 0x83000014
push eax
call ebp
test eax, eax
jne 0x476879
pop edi
pop esi
pop ebp
mov eax, 0x66
pop ebx
add esp, 0xd7c
ret
mov eax, dword [esi + 0x10008]
lea ecx, [esp + 0x18]
push ebx
push ecx
push ebx
push ebx
lea edx, [esp + 0x30]
push 4
push edx
push 0x83000020
push eax
mov dword [esp + 0x40], 4
call ebp
neg eax
sbb eax, eax
pop edi
and al, 0xe3
pop esi
pop ebp
add eax, 0x1d
pop ebx
add esp, 0xd7c
ret
pop edi
pop esi
pop ebp
mov eax, 0x64
pop ebx
add esp, 0xd7c
ret