Function at 0x421ba0
Capabilities:
Extract resource via kernel32 functions
Get file attributes
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x478
mov eax, dword [0x479700]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov dword [ebp - 0x450], eax
mov eax, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x448], eax
call fcn.00420080
mov ecx, eax
test ecx, ecx
je 0x421edd
mov eax, dword [ecx]
call dword [eax + 0xc]
push 0x206
mov dword [ebp - 0x44c], 0
xor ebx, ebx
mov dword [ebp - 0x458], 0
lea esi, [eax + 0x10]
xor eax, eax
push eax
mov word [ebp - 0x414], ax
lea eax, [ebp - 0x412]
push eax
mov dword [ebp - 0x454], esi
call fcn.004469f0
mov eax, dword [ebp - 0x450]
add esp, 0xc
push dword [eax]
mov eax, dword [ebp - 0x448]
movzx eax, word [eax]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov dword [ebp - 0x448], eax
test eax, eax
je 0x421e75
push eax
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
test ebx, ebx
je 0x421e75
push dword [ebp - 0x448]
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push ebx
mov dword [ebp - 0x448], eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x450], eax
test eax, eax
je 0x421e75
push 0x80
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
test al, 0x10
je 0x421e08
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x20c], ax
lea eax, [ebp - 0x20a]
push eax
call fcn.004469f0
mov eax, dword [ebp + 0x14]
add esp, 0xc
cmp dword [eax - 4], 1
jle 0x421cd1
push dword [eax - 0xc]
lea ecx, [ebp + 0x14]
call fcn.0041fa10
mov eax, dword [ebp + 0x14]
push eax
lea ecx, [ebp - 0x42c]
call fcn.00403811
lea eax, [ebp - 0x42c]
push eax
lea eax, [ebp - 0x444]
push eax
call fcn.0040545f
mov ecx, eax
add esp, 8
cmp dword [ecx + 0x14], 8
jb 0x421cfd
mov ecx, dword [ecx]
lea edx, [ebp - 0x20c]
movzx eax, word [ecx]
lea ecx, [ecx + 2]
mov word [edx], ax
lea edx, [edx + 2]
test ax, ax
jne 0x421d03
lea ecx, [ebp - 0x444]
call fcn.00403a80
lea ecx, [ebp - 0x42c]
call fcn.00403888
mov eax, dword [ebp + 0x14]
push dword [eax - 8]
push eax
call fcn.0044430c
add esp, 8
test eax, eax
js 0x421ee7
mov ecx, dword [ebp + 0x14]
cmp eax, dword [ecx - 8]
jg 0x421ee7
mov dword [ecx - 0xc], eax
xorps xmm0, xmm0
mov ecx, dword [ebp + 0x14]
mov byte [eax + ecx], 0
mov eax, 0x414
movdqu xmmword [ebp - 0x474], xmm0
lea ecx, [ebp - 0x20c]
mov word [ebp - 0x45c], 0
movq qword [ebp - 0x464], xmm0
lea edx, [ecx + 2]
mov dword [ebp - 0x478], 0
mov dword [ebp - 0x474], 3
mov word [ebp - 0x468], ax
lea esp, [esp]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x421da0
sub ecx, edx
sar ecx, 1
lea edi, [ecx + 1]
cmp edi, 0x3fffffff
jle 0x421dc6
mov dword [ebp - 0x470], 0
jmp 0x421de7
add edi, edi
mov eax, edi
call fcn.00445f70
mov eax, esp
lea ecx, [ebp - 0x20c]
push 3
push edi
push ecx
push eax
call fcn.0040525f
mov dword [ebp - 0x470], eax
lea eax, [ebp - 0x478]
mov dword [ebp - 0x46c], 0
push eax
mov dword [ebp - 0x45e], 0
call dword [sym.imp.SHELL32.dll_SHFileOperationA]
push 0
push 0x80
push 2
push 0
push 1
push 0xc0000000
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
test edi, edi
je 0x421e7f
cmp edi, 0xffffffff
je 0x421e7f
push 0
lea eax, [ebp - 0x458]
push eax
push dword [ebp - 0x448]
push dword [ebp - 0x450]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea eax, [ebp - 0x414]
push eax
lea ecx, [ebp - 0x454]
call fcn.0041cf90
push edi
mov dword [ebp - 0x44c], 1
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [ebp - 0x454]
jmp 0x421e7f
mov dword [ebp - 0x44c], 0
test ebx, ebx
je 0x421e8a
push ebx
call dword [sym.imp.KERNEL32.dll_FreeResource]
lea edx, [esi - 0x10]
or esi, 0xffffffff
lea ecx, [edx + 0xc]
mov eax, esi
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x421ea6
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edi, dword [ebp + 0x14]
add edi, 0xfffffff0
lea eax, [edi + 0xc]
lock xadd dword [eax], esi
dec esi
test esi, esi
jg 0x421ec0
mov ecx, dword [edi]
push edi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x44c]
lea esp, [ebp - 0x484]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00445a5e
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.0041e250
push 0x80070057
call fcn.0041e250
int3