Function at 0x35afc0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x30
mov esi, dword [ebp + 8]
movzx eax, byte [esi]
mov edi, dword [esi + 0x28]
mov ecx, dword [esi + 0x2c]
mov dword [esp + 8], ecx
mov byte [esp + 7], al
movzx ebx, al
test bl, 0x40
jne 0x35affe
lea eax, [esi + 0x10]
push dword [esp + 8]
push eax
push esi
call edi
add esp, 0xc
add dword [esi + 0x20], 1
adc dword [esi + 0x24], 0
mov dword [esp + 0x10], edi
and ebx, 7
mov byte [esi], bl
mov eax, ebx
xor eax, 0xf
test ebx, ebx
mov dword [esp + 0x14], eax
je 0x35b096
xor edi, edi
mov esi, 0xe
sub esi, eax
cmovb esi, edi
lea ebx, [esi + 1]
mov ecx, ebx
and ecx, 3
mov dword [esp], ecx
mov ecx, eax
cmp esi, 3
jb 0x35b073
and ebx, 0xfffffffc
mov ecx, dword [esp + 0x14]
mov eax, dword [ebp + 8]
movzx edi, byte [eax + ecx + 1]
mov word [eax + ecx], 0
movzx edx, byte [eax + ecx + 2]
movzx esi, byte [eax + ecx + 3]
mov word [eax + ecx + 2], 0
add ecx, 4
add ebx, 0xfffffffc
jne 0x35b040
shl edi, 0x10
shl edx, 8
or edx, edi
or edx, esi
shl edx, 8
mov edi, edx
mov eax, dword [esp]
test eax, eax
je 0x35b098
add ecx, dword [ebp + 8]
xor ebx, ebx
nop
movzx edx, byte [ecx + ebx]
or edx, edi
mov byte [ecx + ebx], 0
shl edx, 8
inc ebx
mov edi, edx
cmp eax, ebx
jne 0x35b080
jmp 0x35b098
xor edx, edx
mov ebx, dword [ebp + 8]
movzx ecx, byte [ebx + 0xf]
or ecx, edx
mov byte [ebx + 0xf], 1
mov eax, 0xffffffff
mov edx, dword [ebp + 0x14]
cmp ecx, edx
jne 0x35b310
lea ecx, [edx + 0xf]
shr ecx, 3
or ecx, 1
mov edx, dword [ebx + 0x24]
add ecx, dword [ebx + 0x20]
adc edx, 0
mov dword [ebx + 0x20], ecx
mov dword [ebx + 0x24], edx
mov eax, 0xfffffffe
neg ecx
mov ecx, 0x20000000
sbb ecx, edx
mov edx, dword [ebp + 0x14]
jb 0x35b310
mov esi, dword [ebp + 0x10]
mov edi, dword [ebp + 0xc]
cmp edx, 0x10
jae 0x35b0f8
test edx, edx
jne 0x35b135
jmp 0x35b2c9
mov eax, dword [ebp + 0x18]
shr edx, 4
lea ecx, [ebx + 0x10]
push ecx
push ebx
push dword [esp + 0x10]
mov dword [esp + 0xc], edx
push edx
push esi
push edi
call eax
mov eax, dword [ebp + 0x14]
add esp, 0x18
mov ebx, eax
and ebx, 0xf
je 0x35b2c9
and eax, 0xfffffff0
add esi, eax
add edi, eax
mov ecx, dword [ebp + 8]
mov edx, dword [esp]
call fcn.0035b320
mov edx, ebx
mov ebx, dword [ebp + 8]
lea eax, [ebx + 0x10]
mov dword [esp + 0xc], 0
cmp edx, 8
mov dword [esp], edx
jb 0x35b191
lea ecx, [edi + edx]
cmp eax, ecx
lea ecx, [ebx + edx + 0x10]
setb dl
cmp edi, ecx
setb cl
test dl, cl
jne 0x35b191
mov edx, dword [esp]
and edx, 8
xor ecx, ecx
nop dword [eax + eax]
movsd xmm0, qword [edi + ecx]
movsd xmm1, qword [eax + ecx]
xorps xmm1, xmm0
movlps qword [eax + ecx], xmm1
add ecx, 8
cmp edx, ecx
jne 0x35b170
mov dword [esp + 0xc], edx
cmp dword [esp], edx
je 0x35b1fb
mov ecx, dword [esp]
mov edx, dword [esp + 0xc]
and ecx, 3
je 0x35b1bb
mov edx, dword [esp + 0xc]
nop word cs:[eax + eax]
movzx ebx, byte [edi + edx]
xor byte [eax + edx], bl
inc edx
dec ecx
jne 0x35b1b0
mov ecx, dword [esp + 0xc]
sub ecx, dword [esp]
cmp ecx, 0xfffffffc
mov ebx, dword [ebp + 8]
ja 0x35b1fb
nop word [eax + eax]
movzx ecx, byte [edi + edx]
xor byte [ebx + edx + 0x10], cl
movzx ecx, byte [edi + edx + 1]
xor byte [ebx + edx + 0x11], cl
movzx ecx, byte [edi + edx + 2]
xor byte [ebx + edx + 0x12], cl
movzx ecx, byte [edi + edx + 3]
xor byte [ebx + edx + 0x13], cl
add edx, 4
cmp dword [esp], edx
jne 0x35b1d0
push dword [esp + 8]
push eax
push eax
call dword [esp + 0x1c]
add esp, 0xc
lea eax, [esp + 0x18]
push dword [esp + 8]
push eax
push ebx
call dword [esp + 0x1c]
add esp, 0xc
xor eax, eax
mov edx, dword [esp]
cmp edx, 8
jb 0x35b25d
mov ecx, esi
sub ecx, edi
cmp ecx, 0x20
jb 0x35b25d
mov eax, edx
and eax, 8
xor ecx, ecx
nop word cs:[eax + eax]
movsd xmm0, qword [esp + ecx + 0x18]
movsd xmm1, qword [edi + ecx]
xorps xmm1, xmm0
movlps qword [esi + ecx], xmm1
add ecx, 8
cmp eax, ecx
jne 0x35b240
cmp edx, eax
je 0x35b2c9
mov ecx, eax
and edx, 3
je 0x35b27f
mov ecx, eax
nop word cs:[eax + eax]
movzx ebx, byte [edi + ecx]
xor bl, byte [esp + ecx + 0x18]
mov byte [esi + ecx], bl
inc ecx
dec edx
jne 0x35b270
mov edx, dword [esp]
sub eax, edx
cmp eax, 0xfffffffc
ja 0x35b2c9
nop dword [eax]
movzx eax, byte [edi + ecx]
xor al, byte [esp + ecx + 0x18]
mov byte [esi + ecx], al
movzx eax, byte [edi + ecx + 1]
xor al, byte [esp + ecx + 0x19]
mov byte [esi + ecx + 1], al
movzx eax, byte [edi + ecx + 2]
xor al, byte [esp + ecx + 0x1a]
mov byte [esi + ecx + 2], al
movzx eax, byte [edi + ecx + 3]
xor al, byte [esp + ecx + 0x1b]
mov byte [esi + ecx + 3], al
add ecx, 4
cmp edx, ecx
jne 0x35b290
mov esi, dword [ebp + 8]
mov edx, dword [esp + 0x14]
lea eax, [esi + edx]
mov ecx, 0x10
sub ecx, edx
push ecx
push 0
push eax
call fcn.004f8b70
add esp, 0xc
lea eax, [esp + 0x18]
push dword [esp + 8]
push eax
push esi
call dword [esp + 0x1c]
add esp, 0xc
movups xmm0, xmmword [esp + 0x18]
movups xmm1, xmmword [esi + 0x10]
xorps xmm1, xmm0
movups xmmword [esi + 0x10], xmm1
movzx eax, byte [esp + 7]
mov byte [esi], al
xor eax, eax
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret