Function at 0x806000
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x80
mov dword [esp + 4], ecx
mov ebx, dword [ebp + 0x34]
mov edi, ebx
add edi, dword [ebp + 0x28]
jae 0x806028
push 0x75
push str.external_boringssl_src_crypto_cipher_extra_e_chacha20poly1305.c
push 0x75
jmp 0x806054
mov eax, dword [ebp + 0x10]
cmp edi, eax
jbe 0x80603a
push 0x79
push str.external_boringssl_src_crypto_cipher_extra_e_chacha20poly1305.c
push 0x67
jmp 0x806054
cmp dword [ebp + 0x18], 0xc
jne 0x80604b
cmp eax, ebx
jae 0x80606a
push 0x8e
jmp 0x806031
push 0x7d
push str.external_boringssl_src_crypto_cipher_extra_e_chacha20poly1305.c
push 0x79
push 0
push 0x1e
call sym.adb.exe_ERR_put_error
add esp, 0x14
xor eax, eax
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov esi, edx
mov edx, dword [ebp + 0x20]
mov ecx, dword [ebp + 8]
cmp dword [ebp + 0x28], 0
je 0x806230
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], edi
mov eax, dword [ebp + 0x24]
mov ebx, edx
and ebx, 0x3f
shr edx, 6
add ecx, 0x10
mov dword [esp + 0x1c], ecx
add eax, 0x10
mov dword [esp + 0x18], eax
xor esi, esi
mov edi, dword [ebp + 0x28]
jmp 0x8060be
xor ebx, ebx
cmp esi, edi
mov edx, dword [esp + 0x24]
jae 0x806222
inc edx
xorps xmm0, xmm0
movaps xmmword [esp + 0x60], xmm0
movaps xmmword [esp + 0x50], xmm0
movaps xmmword [esp + 0x40], xmm0
movaps xmmword [esp + 0x30], xmm0
mov dword [esp + 0x24], edx
push edx
push dword [ebp + 0x14]
push dword [esp + 0xc]
push 0x40
lea eax, [esp + 0x40]
push eax
push eax
call sym.adb.exe_CRYPTO_chacha_20
add esp, 0x18
cmp esi, edi
jae 0x8060b0
mov ecx, esi
not ecx
add ecx, edi
mov eax, ebx
xor eax, 0x3f
cmp ecx, eax
cmovb eax, ecx
cmp eax, 0xf
jb 0x8061f0
mov ecx, dword [ebp + 8]
add ecx, esi
mov edx, dword [ebp + 0x24]
add edx, esi
sub ecx, edx
cmp ecx, 0x10
jb 0x8061f0
lea ecx, [eax + 1]
mov dword [esp + 0x20], ecx
add eax, 0xfffffff1
mov ecx, eax
shr ecx, 4
inc ecx
mov dword [esp + 8], ecx
xor edx, edx
cmp eax, 0x10
jb 0x8061a9
mov ecx, dword [esp + 8]
and ecx, 0xfffffffe
mov eax, dword [esp + 0x1c]
add eax, esi
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x18]
add eax, esi
mov dword [esp + 0x28], eax
lea eax, [esp + 0x40]
add eax, ebx
mov dword [esp + 0xc], eax
xor edx, edx
nop word cs:[eax + eax]
mov eax, dword [esp + 0x28]
movups xmm0, xmmword [eax + edx - 0x10]
mov edi, dword [esp + 0xc]
movups xmm1, xmmword [edi + edx - 0x10]
xorps xmm1, xmm0
mov edi, dword [esp + 0x2c]
movups xmmword [edi + edx - 0x10], xmm1
movups xmm0, xmmword [eax + edx]
mov eax, dword [esp + 0xc]
movups xmm1, xmmword [eax + edx]
xorps xmm1, xmm0
movups xmmword [edi + edx], xmm1
add edx, 0x20
add ecx, 0xfffffffe
jne 0x806170
mov edi, dword [esp + 0x20]
mov eax, edi
and eax, 0xfffffff0
test byte [esp + 8], 1
je 0x8061d4
lea ecx, [esi + edx]
add edx, ebx
movups xmm0, xmmword [esp + edx + 0x30]
mov edx, dword [ebp + 0x24]
movups xmm1, xmmword [edx + ecx]
xorps xmm0, xmm1
mov edx, dword [ebp + 8]
movups xmmword [edx + ecx], xmm0
add esi, eax
cmp edi, eax
mov edi, dword [ebp + 0x28]
je 0x8060b0
add ebx, eax
nop word cs:[eax + eax]
mov ecx, dword [ebp + 8]
nop word cs:[eax + eax]
movzx eax, byte [esp + ebx + 0x30]
mov edx, dword [ebp + 0x24]
xor al, byte [edx + esi]
mov byte [ecx + esi], al
inc esi
cmp ebx, 0x3e
ja 0x8060b0
inc ebx
cmp esi, edi
jb 0x806200
jmp 0x8060b0
mov edi, dword [esp + 0x14]
mov ebx, dword [ebp + 0x34]
mov esi, dword [esp + 0x10]
mov edx, dword [ebp + 0x20]
xorps xmm0, xmm0
movaps xmmword [esp + 0x60], xmm0
movaps xmmword [esp + 0x50], xmm0
movaps xmmword [esp + 0x40], xmm0
movaps xmmword [esp + 0x30], xmm0
push 1
mov eax, dword [ebp + 0x14]
push eax
push dword [esp + 0xc]
push edx
push dword [ebp + 0x1c]
push esi
call sym.adb.exe_CRYPTO_chacha_20
add esp, 0x18
lea ecx, [esp + 0x30]
mov edx, dword [esp + 4]
mov eax, esi
mov esi, dword [ebp + 0x28]
push esi
push dword [ebp + 8]
push dword [ebp + 0x20]
push eax
push dword [ebp + 0x30]
push dword [ebp + 0x2c]
push dword [ebp + 0x14]
call fcn.008062b0
add esp, 0x1c
test ebx, ebx
je 0x80629d
mov esi, dword [ebp + 8]
add esi, dword [ebp + 0x28]
push ebx
lea eax, [esp + 0x34]
push eax
push esi
call sub.api_ms_win_crt_private_l1_1_0.dll_memcpy
add esp, 0xc
mov eax, dword [ebp + 0xc]
mov dword [eax], edi
mov eax, 1
jmp 0x806062