Function at 0x413260
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x18
push ebx
push ebp
mov ebp, ecx
push esi
push edi
mov dword [esp + 0x10], ebp
cmp dword [ebp], 0
je 0x413282
pop edi
pop esi
pop ebp
mov eax, 0xfffffffb
pop ebx
add esp, 0x18
ret 0xc
mov eax, dword [ebp + 8]
test eax, eax
je 0x413298
pop edi
pop esi
pop ebp
mov eax, 0xfffffffb
pop ebx
add esp, 0x18
ret 0xc
mov esi, dword [esp + 0x2c]
test esi, esi
je 0x413462
mov ecx, dword [esp + 0x30]
test ecx, ecx
jbe 0x413462
mov eax, dword [ebp + 4]
mov edi, ecx
shr edi, 4
sub eax, 0
je 0x4133ce
dec eax
je 0x4132d1
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x18
ret 0xc
test edi, edi
lea eax, [ebp + 0xc]
jle 0x4133c5
mov ebx, dword [esp + 0x34]
mov dword [esp + 0x2c], edi
mov ecx, dword [esi]
mov edx, dword [eax]
xor ecx, edx
mov edx, dword [eax + 4]
mov dword [esp + 0x18], ecx
mov ecx, dword [esi + 4]
xor edx, ecx
mov ecx, dword [eax + 8]
mov dword [esp + 0x1c], edx
mov edx, dword [esi + 8]
xor ecx, edx
mov edx, dword [eax + 0xc]
mov dword [esp + 0x20], ecx
mov ecx, dword [esi + 0xc]
lea eax, [esp + 0x18]
xor edx, ecx
push ebx
push eax
mov ecx, ebp
mov dword [esp + 0x2c], edx
call fcn.004139e0
mov ecx, dword [esp + 0x2c]
mov eax, ebx
add esi, 0x10
add ebx, 0x10
dec ecx
mov dword [esp + 0x2c], ecx
jne 0x4132e4
mov ecx, dword [esp + 0x30]
mov dword [esp + 0x34], ebx
lea ebp, [edi + 1]
mov edi, 0x10
shl ebp, 4
mov edx, ebp
sub edx, ecx
sub edi, edx
test edi, edi
jle 0x413388
mov ebx, eax
mov ecx, esi
sub ebx, esi
mov dword [esp + 0x30], edi
mov dword [esp + 0x2c], ebx
lea ebx, [esp + 0x18]
sub ebx, esi
mov dword [esp + 0x14], ebx
mov esi, dword [esp + 0x2c]
mov bl, byte [esi + ecx]
mov esi, dword [esp + 0x14]
xor bl, byte [ecx]
inc ecx
mov byte [esi + ecx - 1], bl
mov esi, dword [esp + 0x30]
dec esi
mov dword [esp + 0x30], esi
jne 0x413367
mov ebx, dword [esp + 0x34]
mov ecx, edi
cmp ecx, 0x10
jge 0x4133aa
mov esi, eax
lea eax, [esp + 0x18]
sub esi, eax
lea eax, [esi + ecx]
mov al, byte [esp + eax + 0x18]
xor al, dl
mov byte [esp + ecx + 0x18], al
inc ecx
cmp ecx, 0x10
jl 0x413397
lea ecx, [esp + 0x18]
push ebx
push ecx
mov ecx, dword [esp + 0x18]
call fcn.004139e0
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x18
ret 0xc
mov ebx, dword [esp + 0x34]
jmp 0x41333a
test edi, edi
jle 0x41345c
mov ebx, dword [esp + 0x34]
mov dword [esp + 0x2c], edi
push ebx
push esi
mov ecx, ebp
call fcn.004139e0
mov eax, dword [esp + 0x2c]
add esi, 0x10
add ebx, 0x10
dec eax
mov dword [esp + 0x2c], eax
jne 0x4133de
mov ecx, dword [esp + 0x30]
lea ebp, [edi + 1]
lea edi, [esp + 0x18]
shl ebp, 4
mov edx, ebp
push ebx
sub edx, ecx
mov ecx, 0x10
sub ecx, edx
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov al, dl
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x2c]
mov ecx, edx
sub edi, edx
mov dh, dl
mov eax, edx
mov esi, ecx
shl eax, 0x10
mov ax, dx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, esi
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x1c]
push eax
call fcn.004139e0
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x18
ret 0xc
mov ebx, dword [esp + 0x34]
jmp 0x4133fc
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x18
ret 0xc