Function at 0x5b4220
Capabilities:
Encode data using xor

Disassembly:
push ecx
push ebx
xor eax, eax
mov ax, word [0x7d3098]
push ebp
push esi
push edi
push eax
call fcn.00595370
mov ebx, dword [esp + 0x24]
mov ebp, dword [esp + 0x20]
add esp, 4
test ebx, ebx
mov esi, eax
je 0x5b42e8
mov al, byte [ebx + 0xdd]
cmp al, 0x13
je 0x5b42e8
cmp al, 0x12
je 0x5b42e8
mov ecx, ebp
call fcn.004e6ff0
test eax, eax
je 0x5b42e8
lea ecx, [esp + 0x10]
push ecx
push str.Companion
mov ecx, ebp
call fcn.004e6ff0
mov ecx, eax
call fcn.0050e7b0
cmp al, 0x73
jne 0x5b42e8
mov ecx, ebp
call fcn.004e7020
mov edx, dword [eax]
mov eax, dword [esp + 0x10]
movsx ecx, word [edx + eax*2]
mov dword [esp + 0x20], ecx
push 0
fild dword [esp + 0x24]
fstp dword [0x7d3184]
call fcn.00595230
add esp, 4
lea edx, [esp + 0x10]
push edx
push str.minimumProfit
mov ecx, ebp
call fcn.004e6ff0
mov ecx, eax
call fcn.0050e7b0
cmp al, 0x66
jne 0x5b42e8
mov ecx, ebp
call fcn.004e7020
mov eax, dword [eax + 8]
mov ecx, dword [esp + 0x10]
fld dword [eax + ecx*4]
mov byte [0x7d318c], 1
fstp dword [0x7d3188]
test esi, esi
jne 0x5b4394
xor edx, edx
mov dx, word [0x7d3098]
push edx
call fcn.00595400
mov esi, eax
push esi
call fcn.005b3d10
add esp, 8
push 0x20
push fcn.00649bb0
push 0xffff8036
mov ecx, esi
mov byte [0x7b5bd8], 1
mov dword [0x7d317c], 0
call fcn.00581f30
push fcn.00649bb0
push 0xffff8037
mov ecx, esi
call fcn.005b03e0
push fcn.005b4790
push 0xffff8044
mov ecx, esi
call fcn.005b03e0
push fcn.005b7330
push 0xffff8040
mov ecx, esi
call fcn.005b03e0
push 0x5b6fe0
push 0xffff8043
mov ecx, esi
call fcn.005b03e0
push 0x5a7780
push 0xffff8076
mov ecx, esi
call fcn.005b03e0
push fcn.00727b50
push 0xffff80ae
mov ecx, esi
call fcn.005b03e0
call fcn.005964b0
push 0
push esi
call fcn.005972c0
add esp, 8
mov ecx, esi
call fcn.00583b60
mov al, byte [esp + 0x24]
test al, al
je 0x5b4407
xor eax, eax
mov ax, word [0x7d3098]
push eax
call fcn.00595370
mov edi, eax
add esp, 4
test edi, edi
je 0x5b4407
xor ecx, ecx
mov cx, word [0x7d3120]
mov eax, 1
push eax
push eax
push ecx
mov ecx, edi
call fcn.00581f30
xor edx, edx
mov dx, word [0x7d3070]
mov ecx, edi
push edx
call fcn.00582de0
test eax, eax
je 0x5b4400
push 0
mov ecx, eax
call fcn.0057f2a0
mov byte [0x7b5bd8], 0
test ebx, ebx
je 0x5b4446
xor eax, eax
mov ax, word [0x7d3098]
push eax
call fcn.00595370
add esp, 4
test eax, eax
je 0x5b4446
xor ecx, ecx
mov cx, word [0x7d3024]
push 8
push ebx
push ecx
mov ecx, eax
call fcn.00581f30
mov ecx, ebx
call fcn.0050f6e0
test al, al
je 0x5b4446
mov byte [0x7b5bd8], 1
xor edx, edx
mov dx, word [0x7d3098]
push edx
call fcn.00595370
add esp, 4
test eax, eax
je 0x5b4470
xor ecx, ecx
mov cx, word [0x7d3048]
push 8
push ebp
push ecx
mov ecx, eax
call fcn.00581f30
mov edi, dword [esp + 0x18]
lea ebp, [edi + 4]
mov ecx, ebp
xor ebx, ebx
call fcn.004ee8b0
cmp eax, 0x41455243
je 0x5b4495
mov ecx, ebp
call fcn.004ee8b0
cmp eax, 0x5f43504e
jne 0x5b44d8
mov ecx, edi
call fcn.004957e0
xor edx, edx
mov dx, word [0x7d3072]
mov ebx, eax
push 8
lea eax, [edi + 0x3c]
push eax
mov ecx, esi
push edx
call fcn.00581f30
or eax, 0xffffffff
push 1
push eax
xor eax, eax
mov ax, word [0x7d2fac]
mov ecx, esi
push eax
call fcn.00581f30
mov ecx, dword [edi + 8]
shr ecx, 0xa
test cl, 1
je 0x5b4550
jmp 0x5b4549
mov ecx, ebp
call fcn.004ee8b0
cmp eax, 0x544e4f43
jne 0x5b4550
mov ecx, edi
call fcn.004957e0
xor edx, edx
mov dx, word [0x7d3072]
mov ebx, eax
push 8
lea eax, [edi + 0x3c]
push eax
mov ecx, esi
push edx
call fcn.00581f30
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 0x9c]
fstp dword [esp + 0x20]
mov ecx, dword [esp + 0x20]
xor edx, edx
mov dx, word [0x7d2fac]
push 2
push ecx
mov ecx, esi
push edx
call fcn.00581f30
xor eax, eax
mov ax, word [0x7d3070]
mov ecx, esi
push eax
call fcn.00582de0
test eax, eax
je 0x5b4549
push 0
mov ecx, eax
call fcn.0057f2a0
mov byte [0x7b5bd8], 0
xor ecx, ecx
mov cx, word [0x7d313c]
push 8
push edi
push ecx
mov ecx, esi
call fcn.00581f30
mov al, byte [esp + 0x24]
test al, al
je 0x5b45a8
xor edx, edx
mov dx, word [0x7d3120]
mov eax, 1
push eax
push eax
mov ecx, esi
push edx
call fcn.00581f30
xor eax, eax
mov ax, word [0x7d3070]
mov ecx, esi
push eax
call fcn.00582de0
test eax, eax
je 0x5b45a1
push 0
mov ecx, eax
call fcn.0057f2a0
mov byte [0x7b5bd8], 0
mov ecx, ebx
mov dword [esp + 0x24], 0
call fcn.0047e710
test eax, eax
je 0x5b45ec
mov ebp, dword [eax + 8]
mov ecx, dword [ebp + 4]
mov edx, dword [ecx]
call dword [edx + 0x9c]
mov eax, dword [ebp]
cdq
xor eax, edx
sub eax, edx
mov dword [esp + 0x20], eax
fimul dword [esp + 0x20]
mov ecx, ebx
fadd dword [esp + 0x24]
fstp dword [esp + 0x24]
call fcn.0047e720
test eax, eax
jne 0x5b45bb
mov eax, dword [esp + 0x24]
xor edx, edx
mov dx, word [0x7d30b8]
push 2
mov ecx, eax
push ecx
mov ecx, esi
mov dword [esp + 0x2c], eax
push edx
call fcn.00581f30
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 0x38]
push eax
mov ecx, esi
call fcn.0058ad30
mov ecx, dword [0x7c67dc]
mov edx, dword [ecx + 0x2e4]
mov eax, dword [edx + 0x10]
push 0x20
push 0x5b7b30
push 0xffff803e
mov ecx, esi
mov dword [eax + 0x88], esi
call fcn.00581f30
push 1
mov ecx, esi
call fcn.00583b70
call fcn.005b67e0
fld dword [0x7d3184]
fcomp dword [0x746468]
fnstsw ax
test ah, 0x40
jne 0x5b4667
call fcn.005b7830
push 1
mov ecx, esi
mov byte [0x7d3178], 1
call fcn.00583b70
mov ecx, dword [0x7c67dc]
mov edx, dword [ecx + 0x2e4]
mov ax, word [0x7d3098]
mov word [edx + 0x3c], ax
call fcn.005ca900
push 1
mov ecx, esi
call fcn.00582f20
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret