Function at 0x594130
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov ebx, dword [esi + 0x34]
lea edi, [esi + 0x110]
mov dword [ebp - 0x10], edi
cmp dword [ebx + 0x64], 0
je 0x594181
mov eax, dword [ebx + 0x54]
mul dword [ebx]
mov dword [ebp + 8], eax
mov eax, dword [ebx + 0x50]
mul dword [ebx]
mov ecx, dword [ebp + 8]
add ecx, edx
add eax, dword [ebx + 0x60]
adc ecx, 0
cmp dword [edi], eax
jne 0x594184
cmp dword [edi + 4], ecx
jne 0x594184
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
mov dword [eax], 0xffffffff
xor eax, eax
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0x10], edi
mov ecx, dword [esi + 0x4c]
xor eax, eax
mov edi, dword [esi + 0xfc]
mov ebx, dword [esi + 8]
mov edx, dword [esi + 0xc]
shr ecx, 1
add ecx, edi
adc eax, eax
add ecx, ebx
adc eax, edx
shld edx, ebx, 1
mov dword [ebp - 0x14], eax
mov eax, edi
mov dword [ebp + 8], edx
add ebx, ebx
mov edx, 2
mul edx
add ebx, eax
mov eax, dword [ebp - 0x14]
mov dword [ebp - 8], ebx
adc dword [ebp + 8], edx
cmp dword [ebp + 8], eax
ja 0x5941ca
jb 0x5941d2
cmp ebx, ecx
jb 0x5941d2
mov ebx, ecx
mov dword [ebp + 8], eax
mov dword [ebp - 8], ebx
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
mov ecx, dword [eax]
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x14], edx
cmp edx, dword [ebp + 8]
jb 0x5941fd
ja 0x5941eb
cmp ecx, ebx
jbe 0x5941fd
mov eax, dword [ebp + 0xc]
sub edi, ebx
add edi, ecx
mov dword [eax], edi
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ebx, ecx
mov dword [ebp - 4], edx
cmp dword [esi + 0x154], edx
jb 0x594232
ja 0x594214
cmp dword [esi + 0x150], ecx
jbe 0x594232
mov edi, dword [esi + 0x154]
mov edx, edi
mov ebx, dword [esi + 0x150]
mov ecx, ebx
mov dword [eax], ebx
mov dword [eax + 4], edi
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x14], edx
mov dword [ebp - 4], edi
cmp dword [ebp + 8], edx
ja 0x594247
jb 0x594240
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x59424a
mov eax, ecx
mov dword [ebp + 8], edx
jmp 0x59424a
mov eax, dword [ebp - 8]
mov edi, dword [esi + 0x34]
add eax, dword [edi]
mov edi, dword [ebp + 8]
adc edi, 0
mov dword [ebp - 8], eax
mov dword [ebp + 8], edi
cmp edx, edi
mov edi, dword [ebp - 4]
ja 0x5943d3
jb 0x594270
cmp ecx, eax
jae 0x5943d3
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x20], edx
mov dword [ebp - 4], edi
nop dword [eax]
mov eax, dword [esi + 0x34]
cmp dword [eax + 0x64], 0
je 0x5942bd
mov ecx, dword [eax]
mov eax, dword [eax + 0x54]
mul ecx
mov edi, eax
mov eax, dword [esi + 0x34]
mov eax, dword [eax + 0x50]
mul ecx
add edi, edx
mov edx, eax
mov eax, dword [esi + 0x34]
add edx, dword [eax + 0x60]
adc edi, 0
cmp dword [ebp - 0x14], edi
ja 0x5943d3
mov ecx, dword [ebp - 0xc]
jb 0x5942bd
cmp ecx, edx
jae 0x5943d3
movd xmm0, dword [eax + 0x30]
movq xmm1, qword [ebp - 0x24]
mov eax, dword [eax + 0x34]
psrlq xmm1, xmm0
and eax, ecx
movq qword [ebp - 0x18], xmm1
mov edi, dword [ebp - 0x14]
mov ebx, dword [ebp - 0x18]
push edi
push ebx
push esi
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x14], ebx
call fcn.00593160
add esp, 0xc
test eax, eax
jne 0x594429
mov ecx, dword [esi + 0x34]
mov eax, ebx
cmp eax, dword [ecx + 0x50]
jne 0x594309
lea ebx, [ecx + 0x60]
cmp edi, dword [ecx + 0x54]
je 0x59430b
mov ebx, ecx
mov ebx, dword [ebx]
mov edx, dword [esi + 0x9c]
mov ecx, dword [ecx]
cmp ebx, edx
jge 0x59432d
add eax, 1
push 0
push ecx
adc edi, 0
push edi
push eax
call fcn.005bf350
mov edi, edx
jmp 0x59439f
push edi
push eax
push 0
push ecx
sub ebx, edx
call fcn.005bf350
mov edi, eax
mov dword [ebp - 0x28], edx
mov dword [ebp - 4], edi
mov eax, dword [esi + 0x34]
push dword [esi + 0x9c]
mov eax, dword [eax + 0x1c]
add eax, ebx
push eax
call fcn.00593950
mov ecx, dword [esi + 0xc0]
mov edx, eax
shr edx, cl
inc edi
mov ecx, dword [esi + 0xc4]
add edi, ebx
and ecx, eax
add esp, 8
mov eax, dword [esi + 0xb8]
xor edx, ecx
mov dword [eax + edx*4], edi
sub ebx, dword [esi + 0xa0]
mov edi, dword [ebp - 4]
cmp ebx, dword [ebp - 0xc]
jge 0x594341
mov ebx, dword [ebp - 0x14]
mov ecx, dword [esi + 0x34]
add ebx, 1
mov eax, dword [ebp - 0x1c]
adc eax, 0
mul dword [ecx]
mov edi, eax
mov eax, ebx
mul dword [ecx]
add edi, edx
mov ebx, eax
mov eax, dword [ebp - 0x10]
mov ecx, ebx
mov edx, edi
mov dword [ebp - 4], edi
mov dword [ebp - 0xc], ecx
mov dword [eax], ebx
mov dword [eax + 4], edi
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x20], edx
cmp edi, dword [ebp + 8]
jb 0x594280
ja 0x5943d0
cmp ebx, dword [ebp - 8]
jb 0x594280
mov dword [ebp - 4], edi
mov eax, dword [esi + 0x34]
mov edx, ebx
cmp dword [eax + 0x64], 0
je 0x59443d
mov ecx, dword [eax]
mov eax, dword [eax + 0x54]
mul ecx
mov edi, eax
mov eax, dword [esi + 0x34]
mov eax, dword [eax + 0x50]
mul ecx
mov ecx, eax
add edi, edx
mov eax, dword [esi + 0x34]
mov edx, ebx
add ecx, dword [eax + 0x60]
adc edi, 0
mov dword [ebp + 8], edi
cmp dword [ebp - 4], edi
jb 0x59443d
ja 0x59440c
cmp ebx, ecx
jb 0x59443d
mov edi, dword [ebp - 0x10]
mov eax, dword [ebp + 8]
mov dword [edi + 4], eax
mov eax, dword [ebp + 0xc]
mov dword [edi], ecx
pop edi
pop esi
mov dword [eax], 0xffffffff
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
cmp eax, 0xffffbad3
mov ecx, 0xffffbad2
pop esi
cmove eax, ecx
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [esi + 0xfc]
sub ecx, dword [ebp - 8]
mov eax, dword [ebp + 0xc]
inc ecx
pop edi
add ecx, edx
pop esi
mov dword [eax], ecx
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret