Function at 0x402060
Capabilities:
Encode data using xor

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff0
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0xe8
mov eax, dword [section..data]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0xc]
push esi
mov esi, ecx
mov dword [ebp - 0x60], eax
xor ecx, ecx
mov dword [ebp - 0x64], edx
push edi
mov edi, dword [ebx + 8]
mov eax, dword [esi + 0x84]
lea edx, [esi + 0x40]
mov dword [ebp - 0xa4], eax
mov eax, dword [esi + 0x80]
mov dword [ebp - 0xe4], esi
mov dword [ebp - 0x58], ecx
mov dword [ebp - 0x5c], eax
test eax, eax
je 0x402103
cmp eax, edi
jae 0x4020fe
mov edx, dword [ebp - 0x60]
mov ecx, dword [ebp - 0x64]
sub ecx, edx
mov dword [ebp - 0x70], edx
mov dword [ebp - 0x74], ecx
mov ecx, dword [ebp - 0x58]
cmp eax, 0x40
jae 0x4020f8
mov eax, dword [ebp - 0x74]
inc ecx
mov al, byte [eax + edx]
mov edx, dword [ebp - 0x5c]
xor al, byte [edx + esi]
mov edx, dword [ebp - 0x70]
mov byte [edx], al
inc edx
mov eax, dword [ebp - 0x5c]
inc eax
mov dword [ebp - 0x70], edx
mov dword [ebp - 0x5c], eax
cmp eax, edi
jb 0x4020d2
mov dword [ebp - 0x58], ecx
lea edx, [esi + 0x40]
sub edi, ecx
mov dword [ebx + 8], edi
xor ecx, ecx
test edi, edi
cmove ecx, eax
cmp dword [0x41b3fc], 0
mov dword [ebp - 0x5c], ecx
je 0x40219a
mov eax, edi
mov dword [ebp - 0x54], edi
and eax, 0x3f
sub dword [ebp - 0x54], eax
mov dword [ebp - 0x74], eax
je 0x40215a
push dword [ebp - 0xa4]
mov edi, dword [ebp - 0x58]
mov eax, dword [ebp - 0x60]
mov ecx, dword [ebp - 0x54]
add eax, edi
push esi
push eax
mov eax, dword [ebp - 0x64]
add eax, edi
push eax
call fcn.004012b0
mov ecx, dword [ebp - 0x5c]
lea edx, [esi + 0x40]
add esp, 0x10
add edi, dword [ebp - 0x54]
mov dword [ebp - 0x58], edi
mov edi, dword [ebp - 0x74]
test edi, edi
je 0x402565
push dword [ebp - 0xa4]
mov eax, dword [ebp - 0x60]
mov ecx, edi
add eax, dword [ebp - 0x58]
push esi
push eax
mov eax, dword [ebp - 0x64]
add eax, dword [ebp - 0x58]
push eax
call fcn.004012b0
add esp, 0x10
mov dword [esi + 0x80], edi
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004079bd
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
test edi, edi
je 0x402565
mov dword [ebp - 0xe8], 0x40
nop dword [eax]
movups xmm2, xmmword [edx]
mov eax, dword [ebp - 0xa4]
movups xmm3, xmmword [edx + 0x10]
movaps xmmword [ebp - 0x50], xmm2
movaps xmmword [ebp - 0x40], xmm3
movups xmm4, xmmword [edx + 0x20]
movups xmm1, xmmword [edx + 0x30]
movaps xmmword [ebp - 0x30], xmm4
movaps xmmword [ebp - 0x20], xmm1
test eax, eax
jle 0x402441
mov esi, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x20]
mov dword [ebp - 0x74], eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x88], eax
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x7c], eax
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x80], eax
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x70], eax
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0xa0], eax
add eax, dword [ebp - 0x50]
mov edx, eax
xor edx, ecx
mov ecx, dword [ebp - 0x30]
rol edx, 0x10
add ecx, edx
mov edi, ecx
xor edi, dword [ebp - 0xa0]
rol edi, 0xc
add eax, edi
mov dword [ebp - 0xa0], eax
xor eax, edx
rol eax, 8
mov dword [ebp - 0xc0], eax
add eax, ecx
mov dword [ebp - 0xd4], eax
xor eax, edi
mov edi, dword [ebp - 0x7c]
rol eax, 7
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0xdc], eax
mov eax, dword [ebp - 0x54]
add eax, dword [ebp - 0x4c]
xor edi, eax
rol edi, 0x10
add ecx, edi
mov edx, ecx
xor edx, dword [ebp - 0x54]
rol edx, 0xc
add eax, edx
mov dword [ebp - 0xc4], eax
xor eax, edi
mov edi, dword [ebp - 0x88]
rol eax, 8
mov dword [ebp - 0xd0], eax
add eax, ecx
mov ecx, dword [ebp - 0x28]
mov dword [ebp - 0x78], eax
xor eax, edx
rol eax, 7
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x70]
add eax, dword [ebp - 0x48]
xor edi, eax
rol edi, 0x10
add ecx, edi
mov edx, ecx
xor edx, dword [ebp - 0x70]
rol edx, 0xc
add eax, edx
mov dword [ebp - 0xcc], eax
xor eax, edi
rol eax, 8
mov dword [ebp - 0xe0], eax
add eax, ecx
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x88], eax
xor eax, edx
rol eax, 7
mov dword [ebp - 0x7c], eax
mov eax, dword [ebp - 0x44]
add eax, dword [ebp - 0x80]
xor esi, eax
rol esi, 0x10
add ecx, esi
mov edx, ecx
xor edx, dword [ebp - 0x80]
rol edx, 0xc
add eax, edx
mov edi, eax
mov dword [ebp - 0xd8], eax
xor edi, esi
rol edi, 8
lea eax, [edi + ecx]
mov dword [ebp - 0x80], eax
xor eax, edx
rol eax, 7
mov dword [ebp - 0xc8], eax
mov eax, dword [ebp - 0x54]
add eax, dword [ebp - 0xa0]
mov ecx, eax
mov edx, dword [ebp - 0x88]
xor ecx, edi
rol ecx, 0x10
add edx, ecx
mov edi, edx
xor edi, dword [ebp - 0x54]
rol edi, 0xc
lea esi, [edi + eax]
mov dword [ebp - 0x50], esi
xor esi, ecx
mov ecx, dword [ebp - 0x80]
rol esi, 8
lea eax, [edx + esi]
mov edx, dword [ebp - 0x7c]
xor edi, eax
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0xc4]
add eax, edx
rol edi, 7
mov dword [ebp - 0x54], edi
mov dword [ebp - 0x3c], edi
mov edi, dword [ebp - 0xc0]
xor edi, eax
rol edi, 0x10
add ecx, edi
xor edx, ecx
rol edx, 0xc
add eax, edx
mov dword [ebp - 0x4c], eax
xor eax, edi
rol eax, 8
mov edi, dword [ebp - 0xd0]
mov dword [ebp - 0xc0], eax
mov dword [ebp - 0x20], eax
add eax, ecx
mov ecx, dword [ebp - 0xd4]
mov dword [ebp - 0x24], eax
xor eax, edx
mov edx, dword [ebp - 0xc8]
rol eax, 7
mov dword [ebp - 0x70], eax
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0xcc]
add eax, edx
xor edi, eax
rol edi, 0x10
add ecx, edi
xor edx, ecx
rol edx, 0xc
add eax, edx
mov dword [ebp - 0x48], eax
xor eax, edi
mov edi, dword [ebp - 0xdc]
rol eax, 8
mov dword [ebp - 0x7c], eax
mov dword [ebp - 0x1c], eax
add eax, ecx
mov ecx, dword [ebp - 0x78]
mov dword [ebp - 0x30], eax
xor eax, edx
mov edx, dword [ebp - 0xe0]
rol eax, 7
mov dword [ebp - 0x80], eax
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0xd8]
add eax, edi
xor edx, eax
rol edx, 0x10
add ecx, edx
xor edi, ecx
rol edi, 0xc
add eax, edi
mov dword [ebp - 0x44], eax
xor eax, edx
rol eax, 8
mov dword [ebp - 0x88], eax
mov dword [ebp - 0x18], eax
add eax, ecx
mov dword [ebp - 0x2c], eax
xor eax, edi
rol eax, 7
sub dword [ebp - 0x74], 1
mov ecx, dword [ebp - 0xc0]
mov dword [ebp - 0xa0], eax
mov dword [ebp - 0x40], eax
jne 0x402210
movaps xmm4, xmmword [ebp - 0x30]
movaps xmm3, xmmword [ebp - 0x40]
movaps xmm2, xmmword [ebp - 0x50]
mov ecx, dword [ebp - 0x5c]
mov dword [ebp - 0x14], esi
mov esi, dword [ebp - 0xe4]
movaps xmm1, xmmword [ebp - 0x20]
lea edx, [esi + 0x40]
lea eax, [ebp - 0x14]
xor edi, edi
cmp esi, eax
ja 0x402458
lea eax, [ebp - 0x50]
mov dword [ebp - 0x78], eax
lea eax, [esi + 0x3c]
cmp eax, dword [ebp - 0x78]
jae 0x402466
lea eax, [edx + 0x3c]
cmp esi, eax
ja 0x402478
lea eax, [esi + 0x3c]
cmp eax, edx
jb 0x402478
mov eax, dword [edx + edi*4]
add eax, dword [ebp + edi*4 - 0x50]
mov dword [esi + edi*4], eax
inc edi
cmp edi, 0x10
jl 0x402466
jmp 0x4024a6
movups xmm0, xmmword [edx]
paddd xmm0, xmm2
movups xmmword [esi], xmm0
movups xmm0, xmmword [edx + 0x10]
paddd xmm0, xmm3
movups xmmword [esi + 0x10], xmm0
movups xmm0, xmmword [edx + 0x20]
paddd xmm0, xmm4
movups xmmword [esi + 0x20], xmm0
movups xmm0, xmmword [edx + 0x30]
paddd xmm1, xmm0
movups xmmword [esi + 0x30], xmm1
add dword [edx + 0x30], 1
jne 0x4024af
inc dword [edx + 0x34]
mov edi, dword [ebx + 8]
cmp edi, 0x40
jb 0x40250f
mov eax, dword [ebp - 0x58]
mov ecx, dword [ebp - 0x64]
movups xmm0, xmmword [esi]
mov edx, dword [ebp - 0x64]
movups xmm2, xmmword [esi + 0x10]
movups xmm3, xmmword [eax + ecx + 0x10]
movups xmm1, xmmword [eax + ecx]
mov ecx, dword [ebp - 0x60]
xorps xmm2, xmm3
xorps xmm1, xmm0
movups xmmword [ecx + eax], xmm1
movups xmmword [ecx + eax + 0x10], xmm2
movups xmm1, xmmword [eax + edx + 0x20]
movups xmm3, xmmword [eax + edx + 0x30]
movups xmm0, xmmword [esi + 0x20]
movups xmm2, xmmword [esi + 0x30]
xorps xmm1, xmm0
movups xmmword [ecx + eax + 0x20], xmm1
xorps xmm2, xmm3
movups xmmword [ecx + eax + 0x30], xmm2
mov ecx, dword [ebp - 0x5c]
add eax, 0x40
mov dword [ebp - 0x58], eax
jmp 0x40254b
cmp ecx, edi
jae 0x40254e
mov eax, dword [ebp - 0x64]
sub eax, dword [ebp - 0x60]
mov edx, dword [ebx + 8]
mov edi, dword [ebp - 0x58]
add edi, dword [ebp - 0x60]
mov dword [ebp - 0x78], eax
mov eax, edx
sub eax, ecx
add dword [ebp - 0x58], eax
nop dword [eax]
mov eax, dword [ebp - 0x78]
lea edi, [edi + 1]
mov al, byte [edi + eax - 1]
xor al, byte [ecx + esi]
inc ecx
mov byte [edi - 1], al
cmp ecx, edx
jb 0x402530
mov edi, dword [ebx + 8]
mov dword [ebp - 0x5c], ecx
lea edx, [esi + 0x40]
cmp edi, 0x40
mov eax, edi
cmova eax, dword [ebp - 0xe8]
sub edi, eax
mov dword [ebx + 8], edi
jne 0x4021b0
mov dword [esi + 0x80], ecx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.004079bd
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret