Function at 0x405220
Capabilities:
Check os version
Delete file
Extract resource via kernel32 functions
Get common file path
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x43fe9b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2ac
push ebx
push ebp
xor ebx, ebx
push esi
push edi
mov dword [esp + 0x14], ebx
mov dword [esp + 0x18], ebx
lea eax, [esp + 0x1b8]
mov dword [esp + 0x2c4], ebx
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
lea ecx, [esp + 0x20]
mov dword [esp + 0x20], 0x94
push ecx
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [esp + 0x24], 5
jne 0x405288
cmp dword [esp + 0x28], 2
je 0x405371
push ecx
mov dword [esp + 0x14], esp
mov eax, esp
push ecx
mov ecx, esp
mov dword [esp + 0x18], esp
push str.FIXREG
mov dword [eax], 0xde
call fcn.00402e90
lea ecx, [esp + 0x1c]
call fcn.00405640
mov edx, dword [esp + 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ecx, dword [esp + 0x18]
mov ebp, eax
mov eax, dword [0x47c550]
push ecx
mov eax, dword [eax + 8]
push eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
push edi
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
cmp edi, ebx
mov esi, eax
jbe 0x4052f0
mov ecx, ebp
mov ebp, edi
sub ecx, esi
mov dl, byte [ecx + eax]
mov byte [eax], dl
inc eax
dec ebp
jne 0x4052e7
lea eax, [esp + 0x10]
lea ecx, [esp + 0x1b8]
push eax
push 0x104
push ecx
call fcn.004054f0
test eax, eax
jl 0x405329
mov eax, dword [esp + 0x10]
mov edx, 0x104
sub edx, eax
push str.360fixreg.reg
lea eax, [esp + eax + 0x1bc]
push edx
push eax
call fcn.004054a0
push ebx
push 0x80
push 2
push ebx
push 2
lea ecx, [esp + 0x1cc]
push 0x40000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x405368
lea edx, [esp + 0x1c]
push ebx
push edx
push edi
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
push ebp
jne 0x405387
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
call fcn.0043fa08
add esp, 4
mov eax, dword [esp + 0x14]
cmp eax, ebx
je 0x405380
push eax
call dword [sym.imp.KERNEL32.dll_FreeResource]
xor eax, eax
jmp 0x405486
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x14]
mov edi, dword [sym.imp.KERNEL32.dll_FreeResource]
cmp eax, ebx
je 0x4053a6
push eax
call edi
mov dword [esp + 0x14], ebx
mov dword [esp + 0x18], ebx
push esi
call fcn.0043fa08
add esp, 4
lea eax, [esp + 0xb4]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
mov ecx, 0x104
lea eax, [esp + 0xb4]
cmp byte [eax], bl
je 0x4053d8
inc eax
dec ecx
jne 0x4053ce
jmp 0x40540b
cmp ecx, ebx
je 0x40540b
lea edx, [esp + 0x10]
test edx, edx
je 0x4053ed
mov eax, 0x104
sub eax, ecx
jmp 0x4053f1
mov eax, dword [esp + 0x10]
mov ecx, 0x104
push str._regedit.exe__s
sub ecx, eax
lea edx, [esp + eax + 0xb8]
push ecx
push edx
call fcn.004054a0
mov ecx, 0x104
lea eax, [esp + 0xb4]
cmp byte [eax], bl
je 0x405421
inc eax
dec ecx
jne 0x405417
jmp 0x405457
cmp ecx, ebx
je 0x405457
lea eax, [esp + 0x10]
test eax, eax
je 0x405436
mov eax, 0x104
sub eax, ecx
jmp 0x40543a
mov eax, dword [esp + 0x10]
mov edx, 0x104
lea ecx, [esp + 0x1b8]
sub edx, eax
push ecx
lea eax, [esp + eax + 0xb8]
push edx
push eax
call fcn.004054a0
lea ecx, [esp + 0xb4]
push ebx
push ecx
call fcn.0040f0c0
add esp, 8
lea edx, [esp + 0x1b8]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [esp + 0x14]
cmp eax, ebx
je 0x405481
push eax
call edi
mov eax, 1
mov ecx, dword [esp + 0x2bc]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x2b8
ret