Function at 0x403d54
Capabilities:
Encode data using xor
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffd0
push ebx
push esi
push edi
mov dword [ebp - 4], ecx
mov ebx, edx
mov byte [ebp - 5], 1
push 0
push 0
push 3
push 0
push 0
push 0x80000000
push eax
call sub.kernel32.dll_CreateFileA_1
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0xffffffff
je 0x403f5f
xor edx, edx
push ebp
push 0x403f58
push dword fs:[edx]
mov dword fs:[edx], esp
push 0
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_GetFileSize_1
mov esi, eax
lea eax, [esi + 4]
call fcn.00402480
mov dword [ebp - 0x2c], eax
xor edx, edx
push ebp
push 0x403f3a
push dword fs:[edx]
mov dword fs:[edx], esp
push 0
lea eax, [ebp - 0x24]
push eax
push esi
mov eax, dword [ebp - 0x2c]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_ReadFile_1
test eax, eax
je 0x403f24
cmp esi, dword [ebp - 0x24]
jne 0x403f24
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x10]
mov edx, ebx
call fcn.00403d4c
mov eax, dword [ebp - 0x10]
mov bl, byte [eax]
lea eax, [ebp - 0x10]
mov edx, 1
call fcn.00403d4c
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x1c], eax
xor eax, eax
mov al, bl
mov edx, eax
shl edx, 2
lea eax, [ebp - 0x10]
call fcn.00403d4c
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x10]
sub eax, dword [ebp - 0x2c]
push eax
mov eax, esi
pop edx
sub eax, edx
shr eax, 2
xor edx, edx
mov dword [ebp - 0x14], edx
test eax, eax
jb 0x403e64
inc eax
mov dword [ebp - 0x30], eax
xor ecx, ecx
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x14]
mov eax, dword [eax + edx*4]
mov edx, dword [ebp - 0x20]
xor dword [edx + ecx*4], eax
xor eax, eax
mov al, bl
push eax
mov eax, ecx
pop edx
mov edi, edx
xor edx, edx
div edi
mov dword [ebp - 0x14], edx
inc ecx
dec dword [ebp - 0x30]
jne 0x403e3e
mov eax, dword [ebp - 0x10]
mov al, byte [eax]
mov byte [ebp - 0x15], al
lea eax, [ebp - 0x10]
mov edx, 1
call fcn.00403d4c
mov eax, dword [ebp - 0x10]
mov bl, byte [eax]
lea eax, [ebp - 0x10]
mov edx, 1
call fcn.00403d4c
mov eax, dword [ebp - 0x2c]
add eax, esi
add eax, 4
xor edx, edx
mov dl, bl
mov edi, edx
mov edx, edi
add edx, dword [ebp - 0x10]
cmp eax, edx
jae 0x403ea8
mov byte [ebp - 5], 0
jmp 0x403f24
xor eax, eax
mov al, bl
call fcn.00402480
mov dword [ebp - 0x28], eax
mov ecx, edi
mov edx, dword [ebp - 0x28]
mov eax, dword [ebp - 0x10]
call fcn.004025a4
mov edx, edi
lea eax, [ebp - 0x10]
call fcn.00403d4c
mov eax, dword [ebp - 0x10]
mov ebx, dword [eax]
lea eax, [ebp - 0x10]
mov edx, 4
call fcn.00403d4c
mov edi, dword [ebp - 0x10]
lea eax, [ebp - 0x10]
mov edx, ebx
call fcn.00403d4c
mov eax, dword [ebp - 0x2c]
add eax, esi
add eax, 4
cmp eax, dword [ebp - 0x10]
jae 0x403efd
mov byte [ebp - 5], 0
jmp 0x403f24
cmp dword [ebp - 4], 0
je 0x403f0f
push ebx
mov ecx, edi
mov edx, dword [ebp - 0x28]
mov eax, dword [ebp + 8]
call dword [ebp - 4]
mov eax, dword [ebp - 0x28]
call fcn.004024a0
dec byte [ebp - 0x15]
cmp byte [ebp - 0x15], 0
jne 0x403e79
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x403f41
mov eax, dword [ebp - 0x2c]
call fcn.004024a0
ret
mov byte [ebp - 5], 0
mov al, byte [ebp - 5]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4