Function at 0x457080
Capabilities:
Create directory
Extract resource via kernel32 functions
Get common file path
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x521b88
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
push ebx
push esi
push edi
mov eax, dword [0x587978]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [0x587944]
mov edx, dword [eax + 0xc]
mov ecx, 0x587944
call edx
lea esi, [eax + 0x10]
mov dword [ebp - 0x10], esi
mov dword [ebp - 4], 2
mov eax, dword [0x587944]
mov edx, dword [eax + 0xc]
mov ecx, 0x587944
call edx
add eax, 0x10
mov dword [ebp - 0x14], eax
mov byte [ebp - 4], 4
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
mov ebx, 0x104
sub eax, ebx
or eax, ecx
jge 0x4570ff
push ebx
lea ecx, [ebp - 0x10]
call fcn.00406e00
mov esi, dword [ebp - 0x10]
cmp dword [esi - 8], ebx
jge 0x45710e
push 0x80070057
call fcn.00406170
push esi
xor eax, eax
mov dword [esi - 0xc], ebx
push ebx
mov word [esi + 0x208], ax
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov eax, dword [esi - 8]
push eax
push esi
call fcn.004eb8eb
add esp, 8
test eax, eax
js 0x457104
cmp eax, dword [esi - 8]
jg 0x457104
mov dword [esi - 0xc], eax
xor ecx, ecx
mov word [esi + eax*2], cx
mov edx, dword [0x587944]
mov eax, dword [edx + 0xc]
mov ecx, 0x587944
call eax
lea edi, [eax + 0x10]
mov dword [ebp - 0x18], edi
mov byte [ebp - 4], 6
mov eax, dword [edi - 8]
mov ecx, 1
sub ecx, dword [edi - 4]
sub eax, ebx
or eax, ecx
jge 0x457178
push ebx
lea ecx, [ebp - 0x18]
call fcn.00406e00
mov edi, dword [ebp - 0x18]
cmp dword [edi - 8], ebx
jge 0x457187
push 0x80070057
call fcn.00406170
push edi
xor ecx, ecx
mov dword [edi - 0xc], ebx
push ebx
mov word [edi + 0x208], cx
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov eax, dword [edi - 8]
push eax
push edi
call fcn.004eb8eb
add esp, 8
test eax, eax
js 0x457104
cmp eax, dword [edi - 8]
jg 0x457104
mov dword [edi - 0xc], eax
xor edx, edx
mov word [edi + eax*2], dx
lea eax, [ebp - 0x20]
push eax
call fcn.00455190
mov bl, 7
mov byte [ebp - 4], bl
push eax
lea ecx, [ebp - 0x18]
push ecx
lea edx, [ebp - 0x1c]
push edx
call fcn.0041f010
add esp, 0x10
mov byte [ebp - 4], 8
mov eax, dword [eax]
push eax
lea ecx, [ebp - 0x10]
call fcn.004113a0
mov byte [ebp - 4], bl
mov eax, dword [ebp - 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x457212
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x457235
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 0x1c], 0
call fcn.004ec8fe
cdq
mov ecx, 0x19
idiv ecx
mov eax, dword [ebp - 0x14]
mov ebx, dword [eax - 0xc]
lea esi, [ebx + 1]
add edx, 0x61
movzx edx, dx
mov dword [ebp - 0x20], edx
test esi, esi
js 0x457104
mov edx, eax
mov eax, dword [edx - 8]
mov ecx, 1
sub ecx, dword [edx - 4]
sub eax, esi
or eax, ecx
jge 0x457282
push esi
lea ecx, [ebp - 0x14]
call fcn.00406e00
mov edx, dword [ebp - 0x14]
mov cx, word [ebp - 0x20]
mov word [edx + ebx*2], cx
cmp esi, dword [edx - 8]
jg 0x457104
xor eax, eax
mov dword [edx - 0xc], esi
mov word [edx + esi*2], ax
mov eax, dword [ebp - 0x1c]
inc eax
mov dword [ebp - 0x1c], eax
cmp eax, 0xa
jb 0x45723c
mov ebx, dword [ebp - 0x10]
mov edx, dword [ebx - 0xc]
lea esi, [edx + 1]
mov dword [ebp - 0x20], edx
test esi, esi
jns 0x4572c2
push 0x80070057
call fcn.00406170
mov eax, dword [ebx - 8]
mov ecx, 1
sub ecx, dword [ebx - 4]
sub eax, esi
or eax, ecx
jge 0x4572e2
push esi
lea ecx, [ebp - 0x10]
call fcn.00406e00
mov ebx, dword [ebp - 0x10]
mov edx, dword [ebp - 0x20]
mov ecx, 0x5c
mov word [ebx + edx*2], cx
cmp esi, dword [ebx - 8]
jg 0x457104
push 0x5372b4
xor edx, edx
push 0xbbb
mov dword [ebx - 0xc], esi
push edx
mov word [ebx + esi*2], dx
call dword [sym.imp.KERNEL32.dll_FindResourceW]
push 0
push ebx
push 0
mov esi, eax
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
test esi, esi
je 0x4573d0
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x4573d0
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x24], eax
test eax, eax
je 0x4573d0
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [ebp - 0x1c], eax
test eax, eax
je 0x4573d0
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebp - 0x10]
push ecx
lea edx, [ebp - 0x20]
push edx
call fcn.0041f010
add esp, 0xc
mov byte [ebp - 4], 0xb
mov eax, dword [eax]
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4573ae
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x24]
push 0
lea ecx, [ebp - 0x28]
push ecx
add edx, 0xffffffca
push edx
add eax, 0x36
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 0x14]
push ecx
lea edx, [ebp - 0x10]
push edx
lea eax, [ebp - 0x24]
push eax
call fcn.0041f010
mov byte [ebp - 4], 0xd
mov eax, dword [eax]
push ebx
push eax
call fcn.0048e500
add esp, 0x14
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x457414
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], 4
add edi, 0xfffffff0
lea ecx, [edi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x457434
mov ecx, dword [edi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push edi
call edx
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x457457
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
add ebx, 0xfffffff0
lea ecx, [ebx + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x45747a
mov ecx, dword [ebx]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push ebx
call edx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret