Function at 0x41caa0
Capabilities:
Encode data using xor

Disassembly:
push esi
push edi
push ebx
push ebp
sub esp, 0x54
mov esi, eax
movzx eax, word [esp + 0x74]
mov ebx, ecx
mov dword [esp + 0x24], edx
mov dword [esp + 0x30], eax
mov ebp, dword [0x4f6e34]
xor ebp, esp
mov dword [esp + 0x50], ebp
mov ebp, dword [esi + 0x120]
mov edi, dword [esi + 0xa4]
mov ecx, dword [ebp + 0x14b1c]
mov dword [esp + 0x14], ecx
lea ecx, [edi + edi*8]
add ecx, edi
neg ecx
add ecx, 0x64
mov edx, dword [ebp + 0x14b18]
sub ecx, dword [esi + 0x2c]
mov dword [esp + 0x18], edx
mov dword [esp + 0x44], ecx
call fcn.0041d950
mov dword [esp + 0x28], eax
mov edi, dword [0x48aca0]
movzx eax, word [0x48aca4]
mov dl, byte [0x48aca6]
mov dword [esp + 0x34], edi
mov word [esp + 0x38], ax
mov byte [esp + 0x3a], dl
mov ecx, dword [ebp + 0x38]
xor eax, eax
cmp dword [ebp + 0x64], 0
mov edx, dword [esi + 0x4c]
mov dword [esp + 0x2c], ecx
seta al
mov ecx, dword [esi + 0x48]
mov edi, dword [ebp + 0x20]
movzx esi, byte [ebp + 0xd4]
mov dword [esp + 8], edx
mov edx, dword [ebp + 0x6c]
mov dword [esp + 0x10], edi
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], esi
cmp edx, 3
jne 0x41cb5e
mov eax, dword [ebp + 0x70]
mov dword [esp], eax
jmp 0x41cb7d
test edx, edx
jne 0x41cb6a
mov eax, dword [ebp + 0x7c]
mov dword [esp], eax
jmp 0x41cb7d
mov esi, dword [ebp + 0x14]
shl esi, 6
mov edi, dword [ebp + 0x74]
mov eax, dword [esi + edi*4 + 0x48c8e0]
mov dword [esp], eax
cmp edx, 7
jae 0x41cb8d
movzx eax, byte [esp + edx + 0x34]
mov dword [esp + 4], eax
jmp 0x41cb95
mov dword [esp + 4], 0
cmp dword [ebp + 0x84], 0
je 0x41cbde
mov edx, 0x1fe
cmp dword [ebp + 0x14eb8], 0x1fe
cmovl edx, dword [ebp + 0x14eb8]
mov esi, 0xfffffe02
cmp edx, 0xfffffe02
cmovge esi, edx
mov eax, esi
mov edi, esi
neg eax
or edi, 0xffff2c00
or eax, 0xffff2e00
test esi, esi
cmovge eax, edi
mov dword [esp + 0x38], eax
jmp 0x41cbe6
mov dword [esp + 0x38], 0
cmp dword [ebp + 0x88], 0
je 0x41cc22
pxor xmm0, xmm0
cvtss2sd xmm0, dword [ebp + 0x14eb4]
divsd xmm0, qword [0x48b138]
mulsd xmm0, qword [0x48b130]
addsd xmm0, qword [0x48b128]
cvttsd2si eax, xmm0
cdq
xor eax, edx
sub eax, edx
mov dword [esp + 0x40], eax
jmp 0x41cc2a
mov dword [esp + 0x40], 0
cmp ecx, 0xffffffff
je 0x41cc51
mov esi, dword [esp + 8]
xor eax, eax
mov edi, 1
xor edx, edx
test esi, esi
cmovg edx, edi
dec ecx
cmp esi, ecx
mov dword [esp + 0x34], edx
cmovge edi, eax
mov dword [esp + 0x3c], edi
jmp 0x41cc5b
xor eax, eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0x34], eax
mov eax, dword [ebp + 0xb8]
cmp eax, 3
je 0x41cf23
test eax, eax
je 0x41cc9f
cmp eax, 2
jne 0x41cc7d
mov dword [esp + 0xc], 2
jmp 0x41cca7
cmp eax, 1
jne 0x41cc95
xor eax, eax
mov edx, 3
cmp eax, dword [ebp + 0x54]
adc edx, 0
mov dword [esp + 0xc], edx
jmp 0x41cca7
mov dword [esp + 0xc], 7
jmp 0x41cca7
mov dword [esp + 0xc], 1
mov ecx, dword [ebp + 0x40]
cmp ecx, 0x7d00
jg 0x41ccbc
mov dword [esp + 8], 0
jmp 0x41ccdf
cmp ecx, 0xbb80
je 0x41ccd7
mov eax, 3
mov edx, 1
cmovg edx, eax
mov dword [esp + 8], edx
jmp 0x41ccdf
mov dword [esp + 8], 2
mov eax, dword [ebp + 0xbc]
and eax, 0xfffffffe
cmp eax, 2
je 0x41cd35
cmp dword [esp + 0x2c], 0xffffffff
je 0x41cf14
cmp dword [ebp + 0x94], 0
je 0x41cd0a
cmp dword [ebp + 0x7c], 0x140
jl 0x41cd35
cmp dword [ebp + 0xe0], 0
jne 0x41cd35
cmp dword [ebp + 0xd8], 0
jne 0x41cd35
cmp dword [esp + 0x20], 0
je 0x41cd35
cmp ecx, 0x7d00
jle 0x41cd35
mov dword [esp + 0x4c], 0
jmp 0x41cd3d
mov dword [esp + 0x4c], 1
push 9
push dword [esp + 0x2c]
xor ecx, ecx
lea esi, [ebx + 4]
mov eax, dword [esp + 0x4c]
test eax, eax
movzx edx, word [ebp + 0x14efc]
cmovle eax, ecx
mov dword [esp + 0x50], edx
mov edx, eax
shr edx, 0x18
mov ecx, eax
mov byte [ebx], dl
mov edx, eax
shr ecx, 0x10
shr edx, 8
push esi
mov byte [ebx + 1], cl
mov byte [ebx + 2], dl
mov byte [ebx + 3], al
call fcn.0046cb40
add esp, 0xc
pxor xmm0, xmm0
cvtsi2sd xmm0, dword [esp + 0x2c]
divsd xmm0, qword [0x48b148]
movsd xmm1, qword [0x48b128]
movsd xmm2, qword [0x48b140]
addsd xmm1, xmm0
mov ecx, dword [esp + 0x40]
minsd xmm2, xmm1
cvttsd2si edx, xmm2
mov byte [ebx + 0xe], dl
mov edx, ecx
mov eax, dword [esp + 4]
shr edx, 0x10
mov byte [ebx + 0x10], dl
xor edx, edx
mov byte [ebx + 0x15], dl
mov byte [ebx + 0x16], dl
mov edx, dword [esp + 0x1c]
shl edx, 5
mov byte [ebx + 0xd], al
mov eax, ecx
mov esi, dword [esp + 0x3c]
add edx, dword [esp + 0x20]
shl esi, 6
shr eax, 0x18
add edx, esi
mov byte [ebx + 0xf], al
mov eax, ecx
mov edi, dword [esp + 0x34]
mov esi, 0xff
shl edi, 7
shr eax, 8
mov byte [ebx + 0x11], al
mov eax, dword [esp + 0x38]
mov byte [ebx + 0x14], al
mov byte [ebx + 0x12], cl
mov ecx, eax
mov eax, dword [esp]
cmp eax, 0xff
mov byte [ebx + 0x1d], 0
cmovg eax, esi
shr ecx, 8
mov byte [ebx + 0x13], cl
lea ecx, [edx + edi + 0x10]
mov byte [ebx + 0x17], cl
mov ecx, dword [esp + 0x14]
mov esi, ecx
mov byte [ebx + 0x18], al
mov eax, dword [esp + 0x18]
mov edx, eax
shl eax, 4
shr esi, 8
mov edi, dword [esp + 0x10]
add eax, esi
mov esi, dword [esp + 0xc]
mov byte [ebx + 0x1b], cl
shr edx, 4
mov ecx, dword [esp + 8]
mov byte [ebx + 0x19], dl
lea edx, [edi + esi*4]
shl ecx, 6
mov esi, dword [esp + 0x4c]
add edx, ecx
shl esi, 5
add edx, esi
mov byte [ebx + 0x1a], al
mov byte [ebx + 0x1c], dl
mov edx, dword [ebp + 0x68]
mov eax, edx
shr eax, 8
mov byte [ebx + 0x1e], al
mov eax, dword [esp + 0x24]
mov ecx, eax
mov byte [ebx + 0x1f], dl
mov edx, eax
shr edx, 0x10
mov byte [ebx + 0x21], dl
shr ecx, 0x18
mov edx, dword [esp + 0x48]
mov byte [ebx + 0x20], cl
mov ecx, eax
mov byte [ebx + 0x23], al
mov eax, edx
shr ecx, 8
shr eax, 8
mov byte [ebx + 0x25], dl
mov byte [ebx + 0x22], cl
mov byte [ebx + 0x24], al
xor eax, eax
mov edx, dword [esp + 0x30]
movzx ecx, byte [ebx + eax*2]
mov ebp, edx
xor edx, ecx
movzx edx, dl
shr ebp, 8
movzx esi, byte [ebx + eax*2 + 1]
inc eax
xor ebp, dword [edx*4 + 0x48acc0]
movzx edi, bp
mov edx, edi
xor edi, esi
and edi, 0xff
shr edx, 8
xor edx, dword [edi*4 + 0x48acc0]
movzx edx, dx
cmp eax, 0x13
jb 0x41cea8
mov dword [esp + 0x30], edx
mov eax, edx
shr eax, 8
mov byte [ebx + 0x26], al
mov byte [ebx + 0x27], dl
mov ecx, dword [esp + 0x50]
mov dword [esp + 0x50], 0
xor ecx, esp
cmp ecx, dword [0x4f6e34]
jne 0x41cf0f
add esp, 0x54
pop ebp
pop ebx
pop edi
pop esi
ret
call fcn.00466f40
cmp dword [ebp + 0x3c], 0xffffffff
je 0x41cd35
jmp 0x41ccf8
mov dword [esp + 0xc], 0
jmp 0x41cca7