Function at 0x6fa9e430
Capabilities:
Encode data using xor

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x3c
mov ebx, dword [esp + 0x50]
cmp dword [ebx + 0x240], 0x10
ja 0x6fa9e4a4
mov eax, dword [ebx + 0x234]
mov dword [esp], eax
call fcn.6fa1c390
test eax, eax
mov ebp, eax
jne 0x6fa9e4a9
mov edi, dword [ebx + 0x254]
mov esi, dword [ebx + 0x250]
mov eax, dword [ebx + 0x240]
shrd esi, edi, 3
cdq
shr edi, 3
add eax, esi
mov esi, dword [esp + 0x58]
adc edx, edi
xor edi, edi
add eax, esi
adc edx, edi
cmp edx, 0xf
ja 0x6fa9e4a4
jb 0x6fa9e48c
cmp eax, 0xffffffdf
ja 0x6fa9e4a4
mov eax, dword [ebx + 0x23c]
test eax, eax
je 0x6fa9e4b3
cmp eax, 1
je 0x6fa9e4e0
cmp eax, 2
je 0x6fa9e560
mov ebp, 0x10
add esp, 0x3c
mov eax, ebp
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], ebx
call fcn.6fa9e0f0
test eax, eax
jne 0x6fa9e559
mov eax, dword [ebx + 0x23c]
jmp 0x6fa9e496
mov eax, dword [ebx + 0x240]
test eax, eax
je 0x6fa9e516
mov edi, eax
sar edi, 0x1f
mov edx, edi
shld edx, eax, 3
shl eax, 3
add dword [ebx + 0x248], eax
lea eax, [ebx + 0x1f4]
adc dword [ebx + 0x24c], edx
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.6fa15fa0
lea eax, [ebx + 0x213]
lea ecx, [ebx + 0x20f]
movzx edi, byte [eax]
lea edx, [edi + 1]
test dl, dl
mov byte [eax], dl
jne 0x6fa9e535
sub eax, 1
cmp eax, ecx
jne 0x6fa9e522
lea eax, [ebx + 0x224]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
lea eax, [ebx + 0x204]
mov dword [esp], eax
call fcn.6fa14050
test eax, eax
je 0x6fa9e610
mov ebp, eax
jmp 0x6fa9e4a9
mov edi, dword [ebx + 0x240]
mov dword [esp + 0x14], 0
test edi, edi
je 0x6fa9e624
mov eax, dword [esp + 0x14]
cmp dword [esp + 0x58], eax
jbe 0x6fa9e4a9
lea edx, [ebx + 0x1f4]
mov ecx, dword [esp + 0x54]
add ecx, dword [esp + 0x58]
mov esi, dword [esp + 0x14]
mov edi, dword [esp + 0x54]
mov dword [esp + 0x14], edx
lea edx, [ebx + 0x20f]
mov dword [esp + 0x1c], ebp
mov eax, dword [ebx + 0x240]
add edi, esi
mov dword [esp + 0x18], edx
add esi, dword [esp + 0x5c]
mov ebp, ecx
jmp 0x6fa9e5ea
xor al, byte [edi]
mov ecx, eax
mov byte [esi], al
mov edx, dword [ebx + 0x240]
add edi, 1
add esi, 1
lea eax, [edx + 1]
mov dword [ebx + 0x240], eax
xor byte [ebx + edx + 0x1f4], cl
cmp ebp, edi
je 0x6fa9e7a0
cmp eax, 0x10
je 0x6fa9e730
mov edx, dword [esp + 0x60]
movzx eax, byte [ebx + eax + 0x224]
test edx, edx
je 0x6fa9e5c0
movzx ecx, byte [esi]
xor eax, ecx
mov byte [edi], al
jmp 0x6fa9e5c6
mov dword [ebx + 0x240], 0
mov dword [ebx + 0x23c], 2
mov eax, dword [esp + 0x58]
mov esi, dword [esp + 0x60]
and eax, 0xfffffff0
test esi, esi
mov dword [esp + 0x1c], eax
je 0x6fa9e7b0
test eax, eax
je 0x6fa9e892
lea eax, [ebx + 0x1f4]
mov esi, dword [esp + 0x5c]
mov edi, dword [esp + 0x54]
mov dword [esp + 0x2c], ebp
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], eax
lea eax, [ebx + 0x224]
mov dword [esp + 0x24], eax
lea eax, [ebx + 0x204]
mov dword [esp + 0x28], eax
lea eax, [ebx + 0x213]
mov dword [esp + 0x20], eax
lea eax, [ebx + 0x20f]
mov ebp, eax
mov esi, esi
lea edi, [edi]
mov edx, dword [esp + 0x18]
xor eax, eax
mov ecx, dword [esi + eax]
xor dword [edx], ecx
add edx, 4
mov ecx, dword [esi + eax]
xor ecx, dword [edx + 0x2c]
mov dword [edi + eax], ecx
add eax, 4
cmp eax, 0x10
jne 0x6fa9e696
add dword [ebx + 0x250], 0x80
mov eax, dword [esp + 0x18]
adc dword [ebx + 0x254], 0
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.6fa15fa0
mov eax, dword [esp + 0x20]
movzx ecx, byte [eax]
lea edx, [ecx + 1]
test dl, dl
mov byte [eax], dl
jne 0x6fa9e6e7
sub eax, 1
cmp eax, ebp
jne 0x6fa9e6d4
mov eax, dword [esp + 0x24]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
mov eax, dword [esp + 0x28]
mov dword [esp], eax
call fcn.6fa14050
test eax, eax
jne 0x6fa9e559
add dword [esp + 0x14], 0x10
add esi, 0x10
add edi, 0x10
mov eax, dword [esp + 0x14]
cmp eax, dword [esp + 0x1c]
jb 0x6fa9e690
mov ebp, dword [esp + 0x2c]
jmp 0x6fa9e576
add dword [ebx + 0x250], 0x80
mov eax, dword [esp + 0x14]
adc dword [ebx + 0x254], 0
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.6fa15fa0
mov ecx, dword [esp + 0x18]
lea eax, [ebx + 0x213]
add byte [eax], 1
jne 0x6fa9e767
sub eax, 1
cmp ecx, eax
jne 0x6fa9e75b
lea eax, [ebx + 0x224]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
lea eax, [ebx + 0x204]
mov dword [esp], eax
call fcn.6fa14050
test eax, eax
jne 0x6fa9e559
mov dword [ebx + 0x240], 0
jmp 0x6fa9e5f3
mov ebp, dword [esp + 0x1c]
jmp 0x6fa9e4a9
mov ecx, dword [esp + 0x1c]
test ecx, ecx
je 0x6fa9e892
lea eax, [ebx + 0x1f4]
mov edi, dword [esp + 0x54]
mov esi, dword [esp + 0x5c]
mov dword [esp + 0x2c], ebp
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], eax
lea eax, [ebx + 0x224]
mov dword [esp + 0x24], eax
lea eax, [ebx + 0x204]
mov dword [esp + 0x28], eax
lea eax, [ebx + 0x213]
mov dword [esp + 0x20], eax
lea eax, [ebx + 0x20f]
mov ebp, eax
mov edx, dword [esp + 0x18]
xor eax, eax
mov ecx, dword [edi + eax]
xor ecx, dword [edx + 0x30]
mov dword [esi + eax], ecx
add eax, 4
xor dword [edx], ecx
add edx, 4
cmp eax, 0x10
jne 0x6fa9e806
add dword [ebx + 0x250], 0x80
adc dword [ebx + 0x254], 0
mov eax, dword [esp + 0x18]
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.6fa15fa0
mov eax, dword [esp + 0x20]
movzx ecx, byte [eax]
lea edx, [ecx + 1]
test dl, dl
mov byte [eax], dl
jne 0x6fa9e854
sub eax, 1
cmp ebp, eax
jne 0x6fa9e841
mov eax, dword [esp + 0x24]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
mov eax, dword [esp + 0x28]
mov dword [esp], eax
call fcn.6fa14050
test eax, eax
jne 0x6fa9e559
add dword [esp + 0x14], 0x10
add edi, 0x10
add esi, 0x10
mov eax, dword [esp + 0x14]
cmp eax, dword [esp + 0x1c]
jb 0x6fa9e800
jmp 0x6fa9e720
mov dword [esp + 0x14], 0
jmp 0x6fa9e576