Function at 0x404330
Capabilities:
Accept command line arguments
Check if file exists
Extract resource via kernel32 functions
Get common file path
Move file
Print debug messages
Terminate process

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x8c
push ebx
push esi
push edi
push str.kernel32.dll
xor ebx, ebx
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov edi, eax
cmp edi, ebx
je 0x404372
push 0x10
push 1
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
cmp eax, ebx
je 0x404372
push eax
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, ebx
je 0x404372
mov esi, dword [eax + 0x30]
push 0x7fff
shr esi, 0x10
cmp si, 5
push 0x41a568
seta al
push ebx
mov byte [0x40a34c], al
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0x104
push 0x41a358
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
call fcn.00405f50
mov esi, eax
cmp esi, ebx
je 0x4043c0
push esi
call fcn.00402909
pop ecx
push esi
mov dword [0x42a568], eax
call fcn.004023f0
pop ecx
cmp dword [str.wRBny], 0x100007f
jne 0x404415
movzx eax, word [0x40a21e]
push eax
movzx eax, word [0x40a21c]
push eax
movzx eax, word [0x40a21a]
push eax
movzx eax, word [0x40a218]
push eax
lea eax, [esp + 0x40]
push str._d._d._d._d
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x18
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov esi, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push eax
call esi
lea eax, [esp + 0x30]
push eax
call esi
lea eax, [esp + 0x14]
push eax
push 8
mov byte [esp + 0x1b], bl
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov esi, str.shit
test eax, eax
je 0x404481
push dword [esp + 0x14]
call fcn.00405271
mov edi, eax
pop ecx
cmp edi, ebx
je 0x40445e
push 0x16
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_IsWellKnownSid]
test eax, eax
push edi
setne byte [esp + 0x17]
call fcn.004023f0
pop ecx
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp byte [esp + 0x13], bl
je 0x404481
push esi
push ecx
push 1
call fcn.00403a42
pop ecx
pop ecx
push eax
call fcn.00404e86
pop ecx
pop ecx
mov dword [esp + 0x20], esi
push 1
mov esi, 0x42a780
push esi
mov dword [esp + 0x2c], 0x404c11
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
push ebx
push ebx
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
lea eax, [esp + 0x20]
push eax
mov dword [0x42a794], 0xc
mov dword [0x42a798], esi
call dword [sym.imp.ADVAPI32.dll_StartServiceCtrlDispatcherW]
test eax, eax
jne 0x404536
push ebx
call dword [sym.imp.ole32.dll_CoInitialize]
call fcn.00405da4
mov byte [esp + 0x18], al
lea eax, [esp + 0x14]
push eax
mov dword [esp + 0x18], ebx
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov edi, eax
xor eax, eax
inc eax
cmp dword [esp + 0x14], eax
jle 0x40459d
mov esi, dword [sym.imp.KERNEL32.dll_lstrcmpiW]
push 0x407bcc
push dword [edi + 4]
call esi
test eax, eax
jne 0x40453d
push dword [edi + 8]
push ebx
push 2
call dword [sym.imp.KERNEL32.dll_OpenEventW]
mov esi, eax
cmp esi, ebx
je 0x404536
push esi
call dword [sym.imp.KERNEL32.dll_SetEvent]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push 0x407bd4
push dword [edi + 4]
call esi
test eax, eax
jne 0x4045cf
mov dword [esp + 0x1c], ebx
mov esi, dword [edi + 8]
call fcn.0040582e
test eax, eax
jne 0x404580
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x404580
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
inc dword [esp + 0x1c]
cmp dword [esp + 0x1c], 0xa
jl 0x404553
push 4
push ebx
push dword [edi + 8]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
cmp byte [esp + 0x18], bl
je 0x4045cf
call fcn.00404fe1
test al, al
je 0x4045cf
jmp 0x404536
jne 0x4045cf
cmp byte [esp + 0x18], bl
jne 0x4045ac
call fcn.00405568
jmp 0x4045cf
push str.ChangeMeToSomeThingBetter1122334
push eax
push eax
push 0x42a794
call dword [sym.imp.KERNEL32.dll_CreateEventW]
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov bl, byte [esp + 0x18]
call fcn.00403afc
test al, al
jne 0x4045e3
push 0
call fcn.0040333d
cmp byte [esp + 0x18], 0
je 0x4045fa
call fcn.00404fe1
test al, al
je 0x4045fa
push 0
jmp 0x404537
push dword [esp + 0x18]
call fcn.0040411d
pop ecx
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
xor ebx, ebx
jmp 0x404536