Function at 0x405ba0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
mov eax, dword [0x425024]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ecx], 0
push ebx
mov ebx, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x2c], ebx
je 0x405bdd
pop edi
mov eax, 0xfffffffb
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041a772
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ecx + 8], 0
jne 0x405bc6
test edi, edi
je 0x405ebe
mov eax, dword [ebp + 0xc]
test eax, eax
jle 0x405ebe
cdq
and edx, 0xf
add eax, edx
mov edx, dword [ecx + 4]
sar eax, 4
mov dword [ebp - 0x24], eax
push esi
sub edx, 0
je 0x405e45
sub edx, 1
je 0x405c2a
pop esi
pop edi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041a772
mov esp, ebp
pop ebp
ret 0xc
mov dword [ebp - 0x20], eax
lea esi, [ecx + 0xc]
mov dword [ebp - 0x38], esi
test eax, eax
jle 0x405c85
mov eax, dword [edi]
xor eax, dword [esi]
mov dword [ebp - 0x18], eax
mov eax, dword [edi + 4]
xor eax, dword [esi + 4]
mov dword [ebp - 0x14], eax
mov eax, dword [edi + 8]
xor eax, dword [esi + 8]
mov dword [ebp - 0x10], eax
mov eax, dword [edi + 0xc]
xor eax, dword [esi + 0xc]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x18]
push ebx
push eax
call fcn.00406510
mov eax, dword [ebp - 0x20]
mov esi, ebx
mov ecx, dword [ebp - 0x30]
dec eax
add edi, 0x10
mov dword [ebp - 0x20], eax
add ebx, 0x10
test eax, eax
jg 0x405c37
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x38], esi
mov dword [ebp - 0x34], edi
shl eax, 4
mov ecx, 0x10
mov dword [ebp - 0x24], eax
xor edx, edx
sub eax, dword [ebp + 0xc]
add eax, 0x10
mov dword [ebp - 0x1c], edx
sub ecx, eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x20], ecx
test ecx, ecx
jle 0x405d98
cmp ecx, 0x20
jb 0x405d65
mov dword [ebp - 0x1c], edx
lea eax, [esi - 1]
lea edx, [ebp - 0x18]
add eax, ecx
cmp edx, eax
mov edx, 0
ja 0x405cd4
lea eax, [ebp + ecx - 0x19]
cmp eax, esi
jae 0x405d65
lea eax, [edi - 1]
lea ebx, [ebp - 0x18]
add eax, ecx
cmp ebx, eax
mov ebx, dword [ebp - 0x2c]
ja 0x405ceb
lea eax, [ebp + ecx - 0x19]
cmp eax, edi
jae 0x405d65
mov eax, ecx
and eax, 0x8000001f
jns 0x405cf9
dec eax
or eax, 0xffffffe0
inc eax
mov dword [ebp - 0x1c], ecx
mov ebx, edi
sub dword [ebp - 0x1c], eax
lea ecx, [ebp - 0x18]
sub ecx, esi
sub ebx, esi
mov dword [ebp - 0x44], ecx
mov eax, esi
lea ecx, [ebp - 8]
mov dword [ebp - 0x40], ebx
sub ecx, esi
mov dword [ebp - 0x48], ecx
lea ecx, [edi + 0x10]
mov edi, dword [ebp - 0x44]
mov esi, dword [ebp - 0x48]
mov dword [ebp - 0x28], ecx
mov ecx, ebx
movups xmm0, xmmword [eax]
mov ebx, dword [ebp - 0x28]
lea eax, [eax + 0x20]
movups xmm1, xmmword [ecx + eax - 0x20]
pxor xmm1, xmm0
movups xmm0, xmmword [eax - 0x10]
movups xmmword [edi + eax - 0x20], xmm1
movups xmm1, xmmword [ebx + edx]
mov ebx, dword [ebp - 0x2c]
add edx, 0x20
pxor xmm1, xmm0
movups xmmword [esi + eax - 0x20], xmm1
cmp edx, dword [ebp - 0x1c]
jl 0x405d26
mov edi, dword [ebp - 0x34]
mov esi, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x20]
mov dword [ebp - 0x1c], edx
cmp edx, ecx
jge 0x405d98
lea ecx, [esi + edx]
sub edi, esi
mov edx, dword [ebp - 0x20]
lea eax, [ebp - 0x18]
sub eax, esi
sub edx, dword [ebp - 0x1c]
mov dword [ebp - 0x28], eax
mov ebx, eax
nop
mov al, byte [ecx + edi]
lea ecx, [ecx + 1]
xor al, byte [ecx - 1]
mov byte [ecx + ebx - 1], al
sub edx, 1
jne 0x405d80
mov ebx, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x20]
mov edi, 0x10
mov edx, ecx
sub edi, ecx
cmp ecx, 0x10
jge 0x405e26
cmp edi, 0x20
jb 0x405e26
lea eax, [ecx + esi]
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x18]
add ecx, eax
lea eax, [esi + 0xf]
cmp ecx, eax
ja 0x405dcd
lea eax, [ebp - 9]
cmp eax, dword [ebp - 0x28]
jae 0x405e26
and edi, 0x8000001f
jns 0x405dda
dec edi
or edi, 0xffffffe0
inc edi
mov eax, dword [ebp - 0x3c]
mov ecx, 0x10
movsx eax, al
sub ecx, edi
mov edi, esi
movd xmm0, eax
lea eax, [ebp - 0x18]
punpcklbw xmm0, xmm0
sub edi, eax
punpcklwd xmm0, xmm0
pshufd xmm1, xmm0, 0
nop
lea eax, [edi + edx]
movups xmm0, xmmword [ebp + eax - 0x18]
pxor xmm0, xmm1
movups xmmword [ebp + edx - 0x18], xmm0
movups xmm0, xmmword [esi + edx + 0x10]
pxor xmm0, xmm1
movups xmmword [ebp + edx - 8], xmm0
add edx, 0x20
cmp edx, ecx
jl 0x405e00
cmp edx, 0x10
jge 0x405e98
lea eax, [ebp - 0x18]
sub esi, eax
lea ecx, [ebp - 0x18]
add ecx, edx
inc edx
mov al, byte [ecx + esi]
xor al, byte [ebp - 0x3c]
mov byte [ecx], al
cmp edx, 0x10
jl 0x405e30
jmp 0x405e98
mov esi, eax
test eax, eax
jle 0x405e68
nop dword [eax + eax]
push ebx
push edi
call fcn.00406510
mov ecx, dword [ebp - 0x30]
dec esi
add edi, 0x10
add ebx, 0x10
test esi, esi
jg 0x405e50
mov eax, dword [ebp - 0x24]
shl eax, 4
mov esi, eax
mov dword [ebp - 0x24], eax
sub esi, dword [ebp + 0xc]
mov eax, 0x10
add esi, 0x10
sub eax, esi
push eax
lea eax, [ebp - 0x18]
push edi
push eax
call sub.VCRUNTIME140.dll_memcpy
push esi
lea eax, [ebp - 8]
sub eax, esi
push esi
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0x18
mov ecx, dword [ebp - 0x30]
lea eax, [ebp - 0x18]
push ebx
push eax
call fcn.00406510
mov eax, dword [ebp - 0x24]
pop esi
pop edi
add eax, 0x10
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041a772
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
xor ecx, ebp
pop ebx
call fcn.0041a772
mov esp, ebp
pop ebp
ret 0xc