Function at 0x5e9170
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x38
mov esi, dword [ebp + 8]
movzx eax, byte [esi]
mov ecx, dword [esi + 0x28]
mov dword [esp + 0x18], ecx
mov ecx, dword [esi + 0x2c]
mov dword [esp + 0xc], ecx
mov byte [esp + 7], al
movzx ebx, al
test bl, 0x40
jne 0x5e91b4
lea eax, [esi + 0x10]
push dword [esp + 0xc]
push eax
push esi
call dword [esp + 0x24]
add esp, 0xc
add dword [esi + 0x20], 1
adc dword [esi + 0x24], 0
and ebx, 7
mov byte [esi], bl
mov eax, ebx
xor eax, 0xf
test ebx, ebx
mov dword [esp + 0x30], eax
je 0x5e9266
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 + 8], ecx
mov ecx, eax
cmp esi, 3
jb 0x5e9233
and ebx, 0xfffffffc
mov ecx, dword [esp + 0x30]
mov eax, dword [ebp + 8]
nop word cs:[eax + eax]
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 0x5e9200
shl edi, 0x10
shl edx, 8
or edx, edi
or edx, esi
shl edx, 8
mov edi, edx
mov eax, dword [esp + 8]
test eax, eax
mov esi, dword [ebp + 8]
je 0x5e9268
add ecx, esi
xor ebx, ebx
nop word cs:[eax + eax]
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 0x5e9250
jmp 0x5e9268
xor edx, edx
movzx ecx, byte [esi + 0xf]
or ecx, edx
mov byte [esi + 0xf], 1
mov eax, 0xffffffff
mov ebx, dword [ebp + 0x14]
cmp ecx, ebx
jne 0x5e95a8
lea ecx, [ebx + 0xf]
shr ecx, 3
or ecx, 1
mov edx, dword [esi + 0x24]
add ecx, dword [esi + 0x20]
adc edx, 0
mov dword [esi + 0x20], ecx
mov dword [esi + 0x24], edx
mov eax, 0xfffffffe
neg ecx
mov ecx, 0x20000000
sbb ecx, edx
jb 0x5e95a8
mov edx, dword [ebp + 0x10]
mov edi, dword [ebp + 0xc]
cmp ebx, 0x10
jb 0x5e93a2
lea eax, [esi + 0x10]
mov dword [esp + 0x14], eax
jmp 0x5e9314
mov edi, dword [esp + 0x10]
mov eax, dword [edi]
mov ecx, dword [edi + 4]
xor eax, dword [esp + 0x20]
xor ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x1c]
mov dword [edx + 4], ecx
mov dword [edx], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi + 0xc]
xor eax, dword [esp + 0x28]
xor ecx, dword [esp + 0x2c]
mov dword [edx + 0xc], ecx
mov dword [edx + 8], eax
add edi, 0x10
add edx, 0x10
mov ebx, dword [esp + 8]
add ebx, 0xfffffff0
cmp ebx, 0xf
jbe 0x5e93a2
mov dword [esp + 0x1c], edx
mov dword [esp + 8], ebx
mov eax, dword [edi]
mov ecx, dword [edi + 4]
xor dword [esi + 0x10], eax
xor dword [esi + 0x14], ecx
mov eax, dword [edi + 8]
mov dword [esp + 0x10], edi
mov ecx, dword [edi + 0xc]
xor dword [esi + 0x18], eax
xor dword [esi + 0x1c], ecx
mov edi, esi
mov esi, dword [esp + 0xc]
push esi
mov eax, dword [esp + 0x18]
push eax
push eax
mov ebx, dword [esp + 0x24]
call ebx
add esp, 0xc
push esi
mov esi, edi
lea eax, [esp + 0x24]
push eax
push edi
call ebx
add esp, 0xc
inc byte [edi + 0xf]
jne 0x5e92d0
inc byte [esi + 0xe]
jne 0x5e92d0
inc byte [esi + 0xd]
jne 0x5e92d0
inc byte [esi + 0xc]
jne 0x5e92d0
inc byte [esi + 0xb]
jne 0x5e92d0
inc byte [esi + 0xa]
jne 0x5e92d0
inc byte [esi + 9]
jne 0x5e92d0
inc byte [esi + 8]
jmp 0x5e92d0
test ebx, ebx
je 0x5e9561
mov dword [esp + 0x1c], edx
mov eax, dword [ebp + 8]
lea edx, [eax + 0x10]
cmp ebx, 8
mov dword [esp + 0x10], edx
jae 0x5e93c1
xor edx, edx
jmp 0x5e940f
lea ecx, [edi + ebx]
cmp edx, ecx
lea ecx, [eax + ebx + 0x10]
setb dl
cmp edi, ecx
setb cl
test dl, cl
mov edx, 0
jne 0x5e940f
mov edx, ebx
and edx, 8
xor ecx, ecx
mov eax, dword [esp + 0x10]
nop word cs:[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 0x5e93f0
cmp ebx, edx
mov esi, dword [ebp + 8]
je 0x5e947a
mov ecx, ebx
mov dword [esp + 0x14], edx
and ecx, 3
mov esi, dword [esp + 0x10]
je 0x5e943b
mov edx, dword [esp + 0x14]
nop word cs:[eax + eax]
movzx eax, byte [edi + edx]
xor byte [esi + edx], al
inc edx
dec ecx
jne 0x5e9430
mov eax, dword [esp + 0x14]
sub eax, ebx
cmp eax, 0xfffffffc
mov esi, dword [ebp + 8]
ja 0x5e947a
nop dword [eax]
movzx eax, byte [edi + edx]
xor byte [esi + edx + 0x10], al
movzx eax, byte [edi + edx + 1]
xor byte [esi + edx + 0x11], al
movzx eax, byte [edi + edx + 2]
xor byte [esi + edx + 0x12], al
movzx eax, byte [edi + edx + 3]
xor byte [esi + edx + 0x13], al
add edx, 4
cmp ebx, edx
jne 0x5e9450
push dword [esp + 0xc]
mov eax, dword [esp + 0x14]
push eax
push eax
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 0x24]
call ebx
add esp, 0xc
push dword [esp + 0xc]
lea eax, [esp + 0x24]
push eax
push esi
call ebx
mov edx, dword [esp + 0x14]
add esp, 0xc
xor esi, esi
cmp edx, 8
jae 0x5e951b
mov eax, dword [esp + 0x1c]
mov ebx, eax
mov ecx, esi
and edx, 3
je 0x5e94cf
mov ecx, esi
nop word [eax + eax]
movzx eax, byte [edi + ecx]
xor al, byte [esp + ecx + 0x20]
mov byte [ebx + ecx], al
inc ecx
dec edx
jne 0x5e94c0
mov edx, dword [esp + 8]
sub esi, edx
cmp esi, 0xfffffffc
ja 0x5e9561
nop
movzx eax, byte [edi + ecx]
xor al, byte [esp + ecx + 0x20]
mov byte [ebx + ecx], al
movzx eax, byte [edi + ecx + 1]
xor al, byte [esp + ecx + 0x21]
mov byte [ebx + ecx + 1], al
movzx eax, byte [edi + ecx + 2]
xor al, byte [esp + ecx + 0x22]
mov byte [ebx + ecx + 2], al
movzx eax, byte [edi + ecx + 3]
xor al, byte [esp + ecx + 0x23]
mov byte [ebx + ecx + 3], al
add ecx, 4
cmp edx, ecx
jne 0x5e94e0
jmp 0x5e9561
mov eax, dword [esp + 0x1c]
mov ecx, eax
lea ebx, [esp + 0x20]
sub ecx, ebx
cmp ecx, 0x20
jb 0x5e94af
mov ecx, eax
sub ecx, edi
cmp ecx, 0x20
jb 0x5e94af
mov esi, edx
and esi, 8
xor ecx, ecx
movsd xmm0, qword [esp + ecx + 0x20]
movsd xmm1, qword [edi + ecx]
xorps xmm1, xmm0
movlps qword [eax + ecx], xmm1
add ecx, 8
cmp esi, ecx
jne 0x5e9540
cmp edx, esi
jne 0x5e94af
mov esi, dword [ebp + 8]
mov edx, dword [esp + 0x30]
lea eax, [esi + edx]
mov ecx, 0x10
sub ecx, edx
push ecx
push 0
push eax
call fcn.00786b68
add esp, 0xc
push dword [esp + 0xc]
lea eax, [esp + 0x24]
push eax
push esi
call dword [esp + 0x24]
add esp, 0xc
movups xmm0, xmmword [esp + 0x20]
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