Function at 0x4015d0
Capabilities:
Check if file exists
Encode data using xor
Get file size
Hash data with crc32
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1280
call fcn.00403c10
mov eax, dword [0x41e014]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 0x10]
xorps xmm0, xmm0
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, dword [ebp + 0xc]
push edi
mov dword [ebp - 0x127c], ebx
mov dword [ebp - 0x1278], esi
mov dword [ebp - 0x1274], edx
movlpd qword [ebp - 0x1270], xmm0
mov dword [ebp - 0x1268], 0
movlpd qword [ebp - 0x1260], xmm0
call fcn.004014a0
test ebx, ebx
je 0x401b46
test esi, esi
je 0x401b46
mov edi, dword [ebp + 0x14]
test edx, edx
je 0x40164a
cmp edi, 0x80000000
ja 0x401b46
push 0x248
lea eax, [ebp - 0x124c]
push 0
push eax
call fcn.00404e70
add esp, 0xc
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
xor ecx, ecx
test eax, eax
sete cl
mov dword [ebp - 0x1280], ecx
test eax, eax
je 0x401ada
lea eax, [ebp - 0x124c]
push eax
push esi
push ebx
call section..text
add esp, 0xc
test eax, eax
jne 0x401b46
lea eax, [ebp - 0x124c]
push eax
push 0xffffffffffffffff
push ebx
call fcn.00401120
add esp, 0xc
test eax, eax
je 0x4016b8
mov eax, dword [ebp - 0x123c]
inc eax
mov dword [ebp - 0x1268], eax
push 0
push 0
push 3
push 0
push 3
push 8
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x1254], eax
cmp eax, 0xffffffff
je 0x40171f
lea ecx, [ebp - 0x1270]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x40171f
mov eax, dword [ebp - 0x1270]
mov dword [ebp - 0x125c], eax
mov eax, dword [ebp - 0x126c]
mov dword [ebp - 0x1264], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x1258], 1
call eax
mov ecx, dword [ebp - 0x1254]
mov dword [ebp - 0x1250], eax
jmp 0x401764
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov ecx, dword [ebp - 0x1254]
xorps xmm0, xmm0
movlpd qword [ebp - 0x1260], xmm0
mov dword [ebp - 0x1250], eax
mov eax, dword [ebp - 0x125c]
mov dword [ebp - 0x1264], eax
mov eax, dword [ebp - 0x1260]
mov dword [ebp - 0x1258], 0
mov dword [ebp - 0x125c], eax
cmp ecx, 0xffffffff
je 0x40176b
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x1250]
call dword [sym.imp.KERNEL32.dll_SetLastError]
cmp dword [ebp - 0x1258], 0
je 0x401b4e
mov eax, dword [ebp - 0x125c]
mov edx, eax
mov ecx, dword [ebp - 0x1264]
add edx, 0xfff
mov dword [ebp - 0x1250], ecx
adc dword [ebp - 0x1250], 0
and edx, 0xfffff000
mov dword [ebp - 0x1254], edx
sub dword [ebp - 0x1254], eax
mov eax, dword [ebp - 0x1250]
sbb eax, ecx
mov dword [ebp - 0x1258], edx
mov dword [ebp - 0x126c], eax
js 0x401818
jg 0x4017d8
cmp dword [ebp - 0x1254], 0
jbe 0x401818
push 0x1000
lea eax, [ebp - 0x1004]
push 0
push eax
call fcn.00404e70
mov eax, dword [ebp - 0x1258]
sub eax, dword [ebp - 0x125c]
push 1
push eax
lea eax, [ebp - 0x1004]
push eax
push ebx
call fcn.00401c40
add esp, 0x1c
test eax, eax
je 0x401b4e
mov edx, dword [ebp - 0x1258]
mov eax, dword [ebp - 0x125c]
movups xmm0, xmmword [0x41e8a0]
mov dword [ebp - 0x1234], eax
mov ecx, 0
mov eax, dword [ebp - 0x1264]
mov dword [ebp - 0x1230], eax
mov eax, edi
add eax, 0xfff
mov dword [ebp - 0x1224], edx
movups xmmword [ebp - 0x124c], xmm0
adc ecx, ecx
mov dword [ebp - 0x121c], edi
and eax, 0xfffff000
mov dword [ebp - 0x1258], ecx
mov ecx, eax
mov dword [ebp - 0x1254], eax
mov eax, dword [ebp - 0x1258]
add ecx, edx
mov edx, dword [ebp - 0x1274]
adc eax, dword [ebp - 0x1250]
add ecx, 0x1000
mov dword [ebp - 0x122c], ecx
adc eax, 0
mov dword [ebp - 0x1218], 0
mov dword [ebp - 0x1228], eax
mov eax, dword [ebp - 0x1268]
mov dword [ebp - 0x123c], eax
mov eax, dword [ebp - 0x1250]
mov dword [ebp - 0x1220], eax
test edx, edx
je 0x40198a
or edx, 0xffffffff
test edi, edi
jle 0x40197c
mov esi, dword [ebp - 0x1274]
xor ebx, ebx
movzx eax, byte [esi + ebx]
xor edx, eax
mov eax, edx
shr eax, 1
mov ecx, eax
xor ecx, 0xedb88320
and dl, 1
cmove ecx, eax
mov eax, ecx
shr eax, 1
mov edx, eax
xor edx, 0xedb88320
and cl, 1
cmove edx, eax
mov eax, edx
shr eax, 1
mov ecx, eax
xor ecx, 0xedb88320
and dl, 1
cmove ecx, eax
mov eax, ecx
shr eax, 1
mov edx, eax
xor edx, 0xedb88320
and cl, 1
cmove edx, eax
mov eax, edx
shr eax, 1
mov ecx, eax
xor ecx, 0xedb88320
and dl, 1
cmove ecx, eax
mov eax, ecx
shr eax, 1
mov edx, eax
xor edx, 0xedb88320
and cl, 1
cmove edx, eax
mov eax, edx
shr eax, 1
mov ecx, eax
xor ecx, 0xedb88320
and dl, 1
cmove ecx, eax
mov eax, ecx
shr eax, 1
mov edx, eax
xor edx, 0xedb88320
and cl, 1
cmove edx, eax
inc ebx
cmp ebx, edi
jl 0x4018d1
mov esi, dword [ebp - 0x1278]
mov ebx, dword [ebp - 0x127c]
not edx
mov dword [ebp - 0x1214], edx
mov edx, dword [ebp - 0x1274]
lea ecx, [ebp - 0x1210]
sub ecx, esi
movzx eax, word [esi]
lea esi, [esi + 2]
mov word [ecx + esi - 2], ax
test ax, ax
jne 0x401992
test edi, edi
je 0x4019c3
mov eax, dword [ebp - 0x1280]
xor eax, 1
push eax
push edi
push edx
push ebx
call fcn.00401c40
add esp, 0x10
test eax, eax
je 0x401b4e
mov eax, dword [ebp - 0x1254]
mov ecx, dword [ebp - 0x1258]
sub eax, edi
sbb ecx, 0
mov dword [ebp - 0x126c], ecx
js 0x401a1d
jg 0x4019e2
test eax, eax
je 0x401a1d
push 0x1000
lea eax, [ebp - 0x1004]
push 0
push eax
call fcn.00404e70
lea eax, [edi + 0xfff]
and eax, 0xfffff000
push 1
sub eax, edi
push eax
lea eax, [ebp - 0x1004]
push eax
push ebx
call fcn.00401c40
add esp, 0x1c
test eax, eax
je 0x401b4e
push 0xdb8
lea eax, [ebp - 0xdbc]
push 0
push eax
call fcn.00404e70
add esp, 0xc
mov dword [ebp - 0x1268], 0
mov ecx, 0x92
lea esi, [ebp - 0x124c]
lea edi, [ebp - 0x1004]
rep movsd dword es:[edi], dword [esi]
push 0
push 0
push 3
push 0
push 3
push 0x40000000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x401b0f
push 2
push 0
xorps xmm0, xmm0
movlpd qword [ebp - 0x1270], xmm0
push dword [ebp - 0x126c]
push dword [ebp - 0x1270]
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
cmp eax, 0xffffffff
je 0x401b0f
push 0
lea eax, [ebp - 0x1268]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x401b03
cmp dword [ebp - 0x1268], 0x1000
jne 0x401b03
push esi
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
mov ebx, 1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
jmp 0x401b1e
mov eax, dword [ebp - 0x126c]
mov edx, dword [ebp - 0x1270]
mov dword [ebp - 0x1250], eax
mov eax, dword [ebp - 0x125c]
mov dword [ebp - 0x1264], eax
mov eax, dword [ebp - 0x1260]
jmp 0x40181e
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
xor ebx, ebx
jmp 0x401b1e
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ebx, ebx
mov edi, eax
cmp esi, 0xffffffff
je 0x401b25
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
test ebx, ebx
je 0x401b4e
pop edi
pop esi
mov eax, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00403bfd
mov esp, ebp
pop ebp
ret
push 0x57
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00403bfd
mov esp, ebp
pop ebp
ret