Function at 0x6a2fa0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
mov eax, dword [0x6d7a68]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
mov ecx, dword [ebp + 8]
push edi
xor edi, edi
cmp dword [esi + 0x10], edi
mov dword [esi + 0x14], 4
jne 0x6a3263
lea eax, [esi + 8]
lea edx, [ebp - 0x2c]
cmp edx, eax
mov dword [esi + 0x10], 5
je 0x6a2fdf
mov dword [eax], edi
mov dword [eax + 4], edi
mov eax, dword [ecx]
mov eax, dword [eax + 0x28]
lea edx, [ebp - 0x2c]
push edx
mov dword [ebp - 0x2c], edi
mov dword [ebp - 0x28], edi
call eax
mov eax, dword [ebp - 0x2c]
shr eax, 2
cmp eax, 0x40000
mov dword [esi + 0x28], eax
jb 0x6a3007
mov dword [esi + 0x28], 0x3ffff
mov eax, dword [esi + 0x28]
cmp eax, edi
je 0x6a3263
push eax
call fcn.008f6480
add esp, 4
cmp eax, edi
mov dword [esi + 0x18], eax
jne 0x6a303b
pop edi
mov dword [esi + 0x10], 2
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0067de1d
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [esi + 0x28]
push ecx
push edi
push eax
call fcn.0067e0a0
add esp, 0xc
lea edx, [ebp - 0x1c]
push edx
mov ecx, esi
call fcn.006a2500
test eax, eax
je 0x6a3263
push ebx
lea ecx, [ecx]
mov ebx, dword [ebp - 0x1c]
test ebx, ebx
je 0x6a31f8
lea eax, [ebx + edi]
cmp eax, dword [esi + 0x28]
ja 0x6a3262
test ebx, ebx
mov dword [ebp - 0x18], 0
jbe 0x6a30a7
mov ecx, dword [ebp - 0x18]
add ecx, edi
add ecx, dword [esi + 0x18]
push ecx
mov ecx, esi
call fcn.006a2470
test eax, eax
je 0x6a3262
mov eax, dword [ebp - 0x18]
add eax, 1
cmp eax, ebx
mov dword [ebp - 0x18], eax
jb 0x6a3082
lea edx, [ebp - 0x20]
push edx
mov ecx, esi
call fcn.006a2470
test eax, eax
je 0x6a3262
xor ecx, ecx
cmp ebx, ecx
mov dword [ebp - 0x18], ecx
mov al, 0xd
jbe 0x6a30eb
mov ebx, dword [ebp - 0x1c]
mov dl, 0x3f
imul dl
mov edx, dword [esi + 0x18]
add edx, ecx
xor byte [edx + edi], al
add edx, edi
mov edx, dword [esi + 0x18]
add edx, ecx
movzx dx, byte [edx + edi]
add word [ebp - 0x18], dx
add ecx, 1
cmp ecx, ebx
jb 0x6a30c5
mov ax, word [ebp - 0x18]
cmp ax, word [ebp - 0x20]
jne 0x6a3227
lea eax, [esi + 0x24]
push eax
mov ecx, esi
call fcn.006a2470
test eax, eax
je 0x6a3262
lea ecx, [ebp - 0x24]
push ecx
mov ecx, esi
call fcn.006a2470
test eax, eax
je 0x6a3262
mov ecx, esi
call fcn.006a20f0
mov dx, word [ebp - 0x24]
cmp dx, word [esi + 0x2c]
jbe 0x6a31d4
movzx eax, word [esi + 0x24]
cmp ax, 0x100
ja 0x6a3241
cmp ax, 0x16
jb 0x6a3241
cmp ax, 0x100
jae 0x6a31c2
mov eax, 0x10
mov word [ebp - 0x12], ax
mov word [ebp - 0xe], ax
mov eax, dword [esi + 0x18]
add eax, edi
lea ecx, [ebx - 3]
push ecx
lea edx, [eax + 3]
push edx
add eax, 4
push eax
mov word [ebp - 0x14], 4
mov word [ebp - 0x10], 0x14
mov word [ebp - 0xc], 0x1c
mov word [ebp - 0xa], 1
mov word [ebp - 8], 2
mov word [ebp - 6], 3
call fcn.0067f500
mov eax, dword [esi + 0x18]
add byte [edi + eax + 1], 1
mov ecx, dword [esi + 0x18]
movzx edx, byte [edi + ecx + 4]
lea eax, [edi + eax + 1]
lea eax, [edi + ecx]
mov cx, word [ebp + edx*2 - 0x14]
add esp, 0xc
add ebx, 1
mov dword [ebp - 0x1c], ebx
mov word [eax + 3], cx
add dword [esi + 0x20], 1
mov eax, edi
add edi, ebx
cmp edi, eax
jb 0x6a3262
jmp 0x6a31e5
mov edx, dword [esi + 0x18]
push ebx
add edx, edi
push 0
push edx
call fcn.0067e0a0
add esp, 0xc
lea eax, [ebp - 0x1c]
push eax
mov ecx, esi
call fcn.006a2500
test eax, eax
jne 0x6a3060
test edi, edi
jne 0x6a325b
mov ecx, dword [esi + 0x28]
mov edx, dword [esi + 0x18]
push ecx
push edi
push edx
call fcn.0067e0a0
add esp, 0xc
pop ebx
pop edi
mov dword [esi + 0x10], 6
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0067de1d
mov esp, ebp
pop ebp
ret 4
pop ebx
pop edi
mov dword [esi + 0x10], 3
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0067de1d
mov esp, ebp
pop ebp
ret 4
pop ebx
pop edi
mov dword [esi + 0x10], 4
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0067de1d
mov esp, ebp
pop ebp
ret 4
mov dword [esi + 0x10], 0
pop ebx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0067de1d
mov esp, ebp
pop ebp
ret 4