Function at 0x6b49e1
Capabilities:
Encode data using xor

Disassembly:
push ebp
push edi
mov edi, edx
push esi
push ebx
sub esp, 0x5c
mov dword [esp + 4], edx
mov esi, dword [esp + 0x74]
mov dword [esp], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x48], edx
mov dword [esp + 0x38], ecx
call fcn.006b8b21
test eax, eax
je 0x6b4bf2
cmp esi, 3
jg 0x6b4aa9
test edi, edi
jle 0x6b4a8c
mov ecx, esi
mov eax, 4
mov esi, dword [esp + 0x48]
mov edi, 1
shl eax, cl
shl edi, cl
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x4c]
mov eax, dword [eax]
mov dword [esp + 0x10], eax
lea eax, [eax + esi*4]
mov dword [esp + 0x18], eax
lea esi, [esi]
nop
mov ebx, dword [esp + 0x38]
xor esi, esi
xor ecx, ecx
mov edx, dword [esp + 0x70]
mov ebp, dword [ebx]
add ebx, 4
xor edx, ecx
add ecx, 1
lea eax, [edx - 1]
not edx
and edx, eax
sar edx, 0x1f
and ebp, edx
or esi, ebp
cmp edi, ecx
jne 0x6b4a51
mov eax, dword [esp + 0x10]
mov ebx, dword [esp + 0x14]
add dword [esp + 0x38], ebx
mov dword [eax], esi
add eax, 4
mov dword [esp + 0x10], eax
cmp dword [esp + 0x18], eax
jne 0x6b4a49
mov eax, dword [esp + 0x4c]
mov esi, dword [esp + 0x48]
mov dword [eax + 4], esi
add esp, 0x5c
mov eax, 1
pop ebx
pop esi
pop edi
pop ebp
ret
lea ebx, [esi - 2]
mov eax, 1
mov edi, dword [esp + 0x48]
mov ecx, ebx
shl eax, cl
mov dword [esp + 0x14], eax
sub eax, 1
and eax, dword [esp + 0x70]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x70]
sar eax, cl
mov ecx, eax
not eax
lea edx, [ecx - 1]
and eax, edx
cdq
mov eax, ecx
mov dword [esp + 0x1c], edx
xor eax, 1
mov edx, ecx
xor edx, 0xfffffffe
sub eax, 1
and eax, edx
cdq
mov eax, ecx
mov dword [esp + 0x20], edx
xor eax, 2
mov edx, ecx
xor edx, 0xfffffffd
sub eax, 1
and eax, edx
cdq
mov eax, ecx
mov dword [esp + 0x24], edx
mov edx, ecx
xor eax, 0xfffffffc
xor edx, 3
sub edx, 1
and eax, edx
cdq
mov dword [esp + 0x28], edx
test edi, edi
jle 0x6b4a8c
mov eax, 4
mov ecx, esi
mov esi, dword [esp + 0x4c]
mov edx, eax
shl edx, cl
mov ecx, ebx
mov esi, dword [esi]
shl eax, cl
mov dword [esp + 0x40], edx
mov dword [esp + 0x34], eax
mov eax, 8
shl eax, cl
mov dword [esp + 0x3c], esi
lea esi, [esi + edi*4]
mov dword [esp + 0x30], eax
mov eax, 0xc
shl eax, cl
mov dword [esp + 0x44], esi
mov dword [esp + 0x2c], eax
lea esi, [esi]
mov dword [esp + 0x10], 0
mov edx, dword [esp + 0x38]
xor esi, esi
nop
mov edi, dword [esp + 0x34]
mov eax, dword [edx]
and eax, dword [esp + 0x1c]
lea ecx, [edi + edx]
mov edi, dword [esp + 0x30]
mov ebp, dword [ecx]
and ebp, dword [esp + 0x20]
lea ecx, [edi + edx]
mov edi, dword [esp + 0x2c]
mov ecx, dword [ecx]
and ecx, dword [esp + 0x24]
lea ebx, [edi + edx]
or ecx, ebp
add edx, 4
mov edi, dword [ebx]
mov ebx, dword [esp + 0x18]
or eax, ecx
and edi, dword [esp + 0x28]
xor ebx, esi
or eax, edi
add esi, 1
mov ecx, ebx
sub ebx, 1
not ecx
and ebx, ecx
sar ebx, 0x1f
mov ecx, ebx
and ecx, eax
or dword [esp + 0x10], ecx
cmp dword [esp + 0x14], esi
jne 0x6b4b71
mov eax, dword [esp + 0x3c]
mov esi, dword [esp + 0x10]
mov edi, dword [esp + 0x40]
add dword [esp + 0x38], edi
mov dword [eax], esi
add eax, 4
mov dword [esp + 0x3c], eax
cmp dword [esp + 0x44], eax
jne 0x6b4b61
jmp 0x6b4a8c
add esp, 0x5c
xor eax, eax
pop ebx
pop esi
pop edi
pop ebp
ret