Function at 0x40a8d0
Capabilities:
Encode data using xor
Read file on windows

Disassembly:
sub esp, 0x324
mov eax, dword [0x4596ac]
xor eax, esp
mov dword [esp + 0x320], eax
mov ecx, dword [0x486344]
mov eax, dword [esp + 0x328]
push ebx
push ebp
push esi
push edi
xor edi, edi
push ecx
mov dword [esp + 0x1c], eax
xor esi, esi
xor ebp, ebp
mov dword [esp + 0x18], edi
call fcn.00435c4a
mov ebx, dword [esp + 0x340]
add ebx, 3
add esp, 4
and ebx, 0xfffffffc
mov dword [esp + 0x10], eax
mov dword [esp + 0x33c], ebx
jle 0x40a967
jmp 0x40a930
mov edx, dword [0x486344]
push edx
call fcn.004361ad
mov cl, al
and cl, 0xf
add esp, 4
mov byte [esp + edi + 0x2c], cl
cmp cl, 0xc
ja 0x40aa6e
shr al, 4
mov byte [esp + edi + 0x2d], al
cmp al, 0xc
ja 0x40aa6e
add edi, 2
cmp edi, ebx
jl 0x40a930
mov eax, ebx
and al, 7
cmp al, 4
jne 0x40a9a2
mov ecx, dword [0x486344]
push ecx
call fcn.004361ad
shl eax, 8
cdq
mov ebp, edx
mov edx, dword [0x486344]
add esp, 4
push edx
mov esi, eax
call fcn.004361ad
cdq
add esp, 4
add esi, eax
adc ebp, edx
mov dword [esp + 0x14], 0x10
mov dword [esp + 0x10], 0
test ebx, ebx
jle 0x40aa53
mov eax, dword [esp + 0x10]
movzx ebx, byte [esp + eax + 0x2c]
cmp dword [esp + 0x14], ebx
jge 0x40a9f2
xor edi, edi
mov ecx, dword [0x486344]
push ecx
call fcn.004361ad
mov ecx, edi
xor ecx, 8
add ecx, dword [esp + 0x18]
cdq
add esp, 4
call fcn.00447ef0
add esi, eax
adc ebp, edx
add edi, 8
cmp edi, 0x20
jl 0x40a9c3
add dword [esp + 0x14], 0x20
mov ecx, 0x10
sub ecx, ebx
mov edi, 0xffff
sar edi, cl
mov eax, esi
mov edx, ebp
mov ecx, ebx
and edi, esi
call fcn.00447f10
sub dword [esp + 0x14], ebx
mov ebp, edx
lea ecx, [ebx - 1]
mov edx, 1
shl edx, cl
mov esi, eax
test edi, edx
jne 0x40aa35
mov ecx, ebx
mov eax, 1
shl eax, cl
mov ecx, 1
sub ecx, eax
add edi, ecx
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x18]
mov word [edx + eax*2], di
inc eax
cmp eax, dword [esp + 0x33c]
mov dword [esp + 0x10], eax
jl 0x40a9b2
xor eax, eax
mov ecx, dword [esp + 0x330]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004334ab
add esp, 0x324
ret
mov eax, dword [esp + 0x10]
mov ecx, dword [0x486344]
push 0
push eax
push ecx
call fcn.00435f77
mov esi, dword [esp + 0x24]
lea eax, [ebx - 1]
shr eax, 3
add esp, 0xc
add esi, 4
inc eax
mov dword [esp + 0x10], eax
mov edx, dword [0x486344]
push edx
push 6
lea eax, [esp + 0x24]
push 2
push eax
call fcn.00435763
add esp, 0x10
cmp eax, 6
jae 0x40aab8
call fcn.004010f0
push 0x1234
call dword [sym.imp.WS2_32.dll_ntohs]
xor edx, edx
mov ecx, 0x1234
cmp ax, cx
sete dl
xor ecx, ecx
mov eax, 0x4949
cmp word [0x465c48], ax
sete cl
cmp ecx, edx
jne 0x40aaf7
lea edx, [esp + 0x1c]
push 0xc
push edx
mov eax, edx
push eax
call fcn.00446b03
add esp, 0xc
mov eax, dword [esp + 0x1c]
mov di, ax
shr di, 4
mov ecx, 0xffffff00
and di, cx
mov ecx, dword [esp + 0x20]
mov dx, cx
shr dx, 8
and dx, 0xfff0
or di, dx
mov edx, dword [esp + 0x24]
mov bx, dx
shr bx, 0xc
or di, bx
mov word [esi - 4], di
mov edi, dword [esp + 0x1e]
mov bx, di
shr bx, 4
mov ebp, 0xffffff00
and bx, bp
mov bp, word [esp + 0x22]
shr bp, 8
and bp, 0xfff0
or bx, bp
mov bp, word [esp + 0x26]
and eax, 0xfff
shr bp, 0xc
or bx, bp
mov word [esi - 2], bx
mov word [esi], ax
mov eax, dword [esp + 0x22]
and eax, 0xfff
mov word [esi + 6], ax
mov eax, dword [esp + 0x26]
and eax, 0xfff
and edi, 0xfff
and ecx, 0xfff
and edx, 0xfff
mov word [esi + 0xa], ax
mov word [esi + 2], di
mov word [esi + 4], cx
mov word [esi + 8], dx
mov eax, 1
add esi, 0x10
sub dword [esp + 0x10], eax
jne 0x40aa96
jmp 0x40aa55