Function at 0x59ef70
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x14
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x28]
mov esi, dword [ecx]
mov ecx, dword [ecx + 4]
mov edi, dword [eax]
mov edx, dword [eax + 4]
cmp ecx, edx
mov ebx, edx
cmovb ebx, ecx
test ebx, ebx
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], ecx
je 0x59efea
xor eax, eax
xor ebp, ebp
mov dword [esp + 8], esi
nop word cs:[eax + eax]
mov edx, dword [esi + ebp*4]
mov ecx, eax
mov eax, ebx
mov ebx, edi
mov edi, dword [edi + ebp*4]
mov esi, edx
sub esi, edi
xor edi, edx
xor esi, edx
or esi, edi
xor esi, edx
mov edx, esi
sar edx, 0x1f
not esi
shr esi, 0x1f
or esi, edx
test edi, edi
mov edi, ebx
mov ebx, eax
mov eax, ecx
cmovne eax, esi
mov esi, dword [esp + 8]
inc ebp
cmp ebx, ebp
jne 0x59efb0
jmp 0x59efec
xor eax, eax
mov ecx, dword [esp + 0xc]
mov ebp, ecx
mov edx, dword [esp + 0x10]
sub ebp, edx
jae 0x59f036
mov ebp, edx
sub ebp, ecx
xor esi, esi
cmp ebp, 8
jb 0x59f160
mov dword [esp], eax
lea esi, [ebp - 8]
mov ebx, esi
shr ebx, 3
inc ebx
mov eax, ebx
and eax, 3
cmp esi, 0x18
mov dword [esp + 4], eax
mov dword [esp + 8], ebp
jae 0x59f07c
pxor xmm0, xmm0
xor ebp, ebp
pxor xmm1, xmm1
jmp 0x59f0e7
jbe 0x59f268
xor ebx, ebx
cmp ebp, 8
jb 0x59f250
mov ecx, esi
mov esi, edx
mov dword [esp + 4], ebp
lea edx, [ebp - 8]
mov edi, edx
shr edi, 3
inc edi
mov ebx, edi
and ebx, 3
mov dword [esp], ebx
cmp edx, 0x18
mov edx, esi
mov esi, ecx
jae 0x59f17b
pxor xmm0, xmm0
xor ebp, ebp
pxor xmm1, xmm1
jmp 0x59f1e7
and ebx, 0xfffffffc
lea esi, [edi + ecx*4]
add esi, 0x70
pxor xmm0, xmm0
xor ebp, ebp
pxor xmm1, xmm1
nop
movdqu xmm2, xmmword [esi + ebp*4 - 0x70]
por xmm2, xmm0
movdqu xmm0, xmmword [esi + ebp*4 - 0x60]
por xmm0, xmm1
movdqu xmm1, xmmword [esi + ebp*4 - 0x50]
movdqu xmm3, xmmword [esi + ebp*4 - 0x40]
movdqu xmm4, xmmword [esi + ebp*4 - 0x30]
por xmm4, xmm1
por xmm4, xmm2
movdqu xmm2, xmmword [esi + ebp*4 - 0x20]
por xmm2, xmm3
por xmm2, xmm0
movdqu xmm0, xmmword [esi + ebp*4 - 0x10]
por xmm0, xmm4
movdqu xmm1, xmmword [esi + ebp*4]
por xmm1, xmm2
add ebp, 0x20
add ebx, 0xfffffffc
jne 0x59f090
mov ebx, dword [esp + 8]
and ebx, 0xfffffff8
mov eax, dword [esp + 4]
test eax, eax
je 0x59f12a
add ebp, ecx
lea esi, [edi + ebp*4]
add esi, 0x10
shl eax, 5
xor ebp, ebp
nop word cs:[eax + eax]
movdqu xmm2, xmmword [esi + ebp - 0x10]
por xmm0, xmm2
movdqu xmm2, xmmword [esi + ebp]
por xmm1, xmm2
add ebp, 0x20
cmp eax, ebp
jne 0x59f110
por xmm0, xmm1
pshufd xmm1, xmm0, 0xee
por xmm1, xmm0
pshufd xmm0, xmm1, 0x55
por xmm0, xmm1
movd esi, xmm0
cmp dword [esp + 8], ebx
jne 0x59f14f
mov eax, dword [esp]
jmp 0x59f168
add ecx, ebx
mov eax, dword [esp]
nop word cs:[eax + eax]
or esi, dword [edi + ecx*4]
inc ecx
cmp edx, ecx
jne 0x59f160
mov ecx, esi
not ecx
dec esi
and esi, ecx
sar esi, 0x1f
not esi
or eax, esi
jmp 0x59f268
and edi, 0xfffffffc
lea ebx, [esi + edx*4]
add ebx, 0x70
pxor xmm0, xmm0
xor ebp, ebp
pxor xmm1, xmm1
nop
movdqu xmm2, xmmword [ebx + ebp*4 - 0x70]
por xmm2, xmm0
movdqu xmm0, xmmword [ebx + ebp*4 - 0x60]
por xmm0, xmm1
movdqu xmm1, xmmword [ebx + ebp*4 - 0x50]
movdqu xmm3, xmmword [ebx + ebp*4 - 0x40]
movdqu xmm4, xmmword [ebx + ebp*4 - 0x30]
por xmm4, xmm1
por xmm4, xmm2
movdqu xmm2, xmmword [ebx + ebp*4 - 0x20]
por xmm2, xmm3
por xmm2, xmm0
movdqu xmm0, xmmword [ebx + ebp*4 - 0x10]
por xmm0, xmm4
movdqu xmm1, xmmword [ebx + ebp*4]
por xmm1, xmm2
add ebp, 0x20
add edi, 0xfffffffc
jne 0x59f190
mov edi, dword [esp + 4]
and edi, 0xfffffff8
mov ecx, dword [esp]
test ecx, ecx
je 0x59f22a
add ebp, edx
lea ebx, [esi + ebp*4]
add ebx, 0x10
shl ecx, 5
xor ebp, ebp
nop word cs:[eax + eax]
movdqu xmm2, xmmword [ebx + ebp - 0x10]
por xmm0, xmm2
movdqu xmm2, xmmword [ebx + ebp]
por xmm1, xmm2
add ebp, 0x20
cmp ecx, ebp
jne 0x59f210
por xmm0, xmm1
pshufd xmm1, xmm0, 0xee
por xmm1, xmm0
pshufd xmm0, xmm1, 0x55
por xmm0, xmm1
movd ebx, xmm0
cmp dword [esp + 4], edi
je 0x59f258
add edx, edi
mov ecx, dword [esp + 0xc]
or ebx, dword [esi + edx*4]
inc edx
cmp ecx, edx
jne 0x59f250
xor edx, edx
xor ecx, ecx
test ebx, ebx
cmove edx, eax
setne cl
or ecx, edx
mov eax, ecx
add esp, 0x14
pop esi
pop edi
pop ebx
pop ebp
ret