Function at 0x5911a0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 0xc]
sub esp, 0x18
shr edx, 2
push ebx
mov ebx, dword [ebp + 0x28]
push esi
mov esi, dword [ebp + 0x14]
shr esi, 2
push edi
cmp ebx, 2
je 0x5911cd
cmp ebx, 3
je 0x5911cd
mov ecx, dword [ebp + 0x10]
mov edi, dword [ebp + 8]
mov dword [ebp + 0x14], ecx
jmp 0x5911ee
mov eax, dword [ebp + 8]
cmp ebx, 2
mov edi, dword [ebp + 0x10]
mov ecx, 4
mov dword [ebp + 0x14], eax
mov eax, edx
mov edx, esi
mov esi, eax
mov eax, 1
cmove eax, ecx
mov ebx, eax
mov dword [ebp + 0xc], edi
cmp ebx, 1
je 0x591378
cmp ebx, 4
je 0x591378
test ebx, ebx
je 0x591210
cmp ebx, 5
jne 0x59149d
mov ecx, dword [ebp + 0x24]
neg ebx
sbb ebx, ebx
and ebx, 0xff
mov dword [ebp + 0x28], ebx
test ecx, ecx
je 0x59149d
mov eax, dword [ebp + 0x20]
add eax, 0xfffffffc
mov dword [ebp - 8], eax
lea eax, [edx*4]
mov dword [ebp - 0x10], eax
lea eax, [esi*4]
mov esi, dword [ebp + 0x18]
add esi, 2
mov dword [ebp - 0x14], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 4], esi
dec ecx
mov dword [ebp - 0x18], ecx
xor ecx, ecx
cmp dword [ebp - 8], ecx
jl 0x591316
mov edx, dword [ebp + 0xc]
lea esi, [eax + 4]
add edi, 0xc
sub edx, eax
mov dword [ebp - 0xc], edx
mov edi, edi
movss xmm0, dword [edi - 0xc]
ucomiss xmm0, dword [esi - 4]
lahf
test ah, 0x44
jp 0x591286
mov edx, 1
jmp 0x591288
xor edx, edx
mov eax, dword [ebp - 0xc]
neg edx
xor edx, ebx
movss xmm0, dword [eax + esi]
ucomiss xmm0, dword [esi]
lahf
test ah, 0x44
jp 0x5912a4
mov eax, 1
jmp 0x5912a6
xor eax, eax
mov ebx, dword [ebp - 4]
neg al
mov byte [ebx + ecx - 2], dl
mov edx, dword [ebp - 4]
mov ebx, dword [ebp + 0x28]
xor al, bl
mov byte [edx + ecx - 1], al
movss xmm0, dword [edi - 4]
ucomiss xmm0, dword [esi + 4]
lahf
test ah, 0x44
jp 0x5912d1
mov edx, 1
jmp 0x5912d3
xor edx, edx
movss xmm0, dword [edi]
neg edx
xor edx, ebx
ucomiss xmm0, dword [esi + 8]
lahf
test ah, 0x44
jp 0x5912ec
mov eax, 1
jmp 0x5912ee
xor eax, eax
mov ebx, dword [ebp - 4]
neg al
add esi, 0x10
add edi, 0x10
mov byte [ebx + ecx], dl
mov edx, dword [ebp - 4]
mov ebx, dword [ebp + 0x28]
xor al, bl
mov byte [edx + ecx + 1], al
add ecx, 4
cmp ecx, dword [ebp - 8]
jle 0x591270
mov esi, edx
cmp ecx, dword [ebp + 0x20]
jge 0x59134e
mov eax, dword [ebp + 0x14]
mov edi, dword [ebp + 0xc]
sub edi, eax
lea edx, [eax + ecx*4]
movss xmm0, dword [edx + edi]
ucomiss xmm0, dword [edx]
lahf
test ah, 0x44
jp 0x59133b
mov eax, 1
jmp 0x59133d
xor eax, eax
neg al
add edx, 4
xor al, bl
mov byte [esi + ecx - 2], al
inc ecx
cmp ecx, dword [ebp + 0x20]
jl 0x591326
mov edi, dword [ebp + 0xc]
mov eax, dword [ebp + 0x14]
add edi, dword [ebp - 0x10]
add eax, dword [ebp - 0x14]
add esi, dword [ebp + 0x1c]
mov ecx, dword [ebp - 0x18]
mov dword [ebp + 0xc], edi
mov dword [ebp + 0x14], eax
mov dword [ebp - 4], esi
test ecx, ecx
jne 0x591251
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 0x24]
dec ebx
neg ebx
sbb ebx, ebx
and ebx, 0xff
test ecx, ecx
je 0x59149d
mov edi, dword [ebp + 0x20]
lea eax, [edx*4]
mov dword [ebp - 0x14], eax
add edi, 0xfffffffc
lea eax, [esi*4]
mov dword [ebp - 4], edi
mov esi, dword [ebp + 0x18]
mov dword [ebp - 0x10], eax
add esi, 2
dec ecx
xor edx, edx
mov dword [ebp - 8], ecx
test edi, edi
js 0x59144f
mov eax, dword [ebp + 0xc]
mov edi, dword [ebp + 0x14]
add eax, 8
mov ecx, dword [ebp + 0xc]
add edi, 4
sub ecx, dword [ebp + 0x14]
mov dword [ebp + 0x28], eax
mov dword [ebp - 0x18], ecx
jmp 0x5913e0
movss xmm0, dword [ecx + edi]
lea edi, [edi + 0x10]
xor ecx, ecx
comiss xmm0, dword [edi - 0x10]
movss xmm0, dword [eax - 8]
seta cl
neg ecx
xor ecx, ebx
comiss xmm0, dword [edi - 0x14]
mov byte [esi + edx - 1], cl
seta al
xor ecx, ecx
neg al
xor al, bl
mov byte [esi + edx - 2], al
mov eax, dword [ebp + 0x28]
movss xmm0, dword [eax + 4]
comiss xmm0, dword [edi - 8]
movss xmm0, dword [eax]
seta cl
neg ecx
xor ecx, ebx
comiss xmm0, dword [edi - 0xc]
mov byte [esi + edx + 1], cl
mov ecx, dword [ebp - 0x18]
seta al
neg al
xor al, bl
mov byte [esi + edx], al
add edx, 4
mov eax, dword [ebp + 0x28]
add eax, 0x10
mov dword [ebp + 0x28], eax
cmp edx, dword [ebp - 4]
jle 0x5913e0
mov ecx, dword [ebp - 8]
cmp edx, dword [ebp + 0x20]
jge 0x591480
mov eax, dword [ebp + 0x14]
mov edi, dword [ebp + 0xc]
sub edi, eax
lea ecx, [eax + edx*4]
nop
movss xmm0, dword [edi + ecx]
lea ecx, [ecx + 4]
comiss xmm0, dword [ecx - 4]
seta al
neg al
xor al, bl
mov byte [esi + edx - 2], al
inc edx
cmp edx, dword [ebp + 0x20]
jl 0x591460
mov ecx, dword [ebp - 8]
mov eax, dword [ebp + 0xc]
add eax, dword [ebp - 0x14]
add esi, dword [ebp + 0x1c]
mov edi, dword [ebp - 4]
mov dword [ebp + 0xc], eax
mov eax, dword [ebp - 0x10]
add dword [ebp + 0x14], eax
test ecx, ecx
jne 0x5913b1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret