Function at 0x597ea0
Capabilities:
Encrypt data using rc4 ksa
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x5c
push ebx
mov ebx, dword [esp + 0x64]
push ebp
push esi
mov esi, dword [esp + 0x70]
mov byte [esi + 4], 1
mov eax, dword [ebx]
mov edx, dword [eax + 0x7c]
push edi
mov edi, dword [esp + 0x7c]
mov ecx, ebx
call edx
push 0
push 0x6a5660
push 0x6a5a0c
push 0
push esi
call fcn.0061eefc
mov esi, eax
add esp, 0x14
test esi, esi
je 0x5992f8
mov ebp, dword [esi + 0x48]
test ebp, ebp
mov dword [esp + 0x30], ebp
jne 0x5988e0
mov eax, dword [esi]
mov edx, dword [eax + 0x7c]
mov ecx, esi
call edx
mov dword [esp + 0x38], eax
mov eax, dword [ebx]
mov edx, dword [eax + 0x7c]
mov ecx, ebx
call edx
mov dword [esp + 0x50], eax
mov eax, esi
call fcn.00588a10
fld qword [edi]
sub esp, 8
fstp qword [esp]
mov dword [esp + 0x24], eax
call fcn.00639dc0
call fcn.006397d0
fld qword [edi + 8]
mov esi, eax
fstp qword [esp]
mov dword [esp + 0x30], esi
call fcn.00639dc0
call fcn.006397d0
fild dword [esp + 0x30]
mov ebx, eax
mov dword [esp + 0x20], ebx
fsubr qword [edi]
fadd qword [edi + 0x10]
fstp qword [esp]
call fcn.0061f440
call fcn.006397d0
fild dword [esp + 0x20]
mov ebp, eax
mov dword [esp + 0x2c], ebp
fsubr qword [edi + 8]
fadd qword [edi + 0x18]
fstp qword [esp]
call fcn.0061f440
add esp, 8
call fcn.006397d0
test esi, esi
mov dword [esp + 0x14], eax
jge 0x597f87
xor esi, esi
mov dword [esp + 0x28], esi
test ebx, ebx
jge 0x597f91
xor ebx, ebx
mov dword [esp + 0x18], ebx
mov ecx, dword [esp + 0x74]
mov ecx, dword [ecx + 0x24]
lea edx, [esi + ebp]
cmp edx, ecx
jle 0x597fa7
sub ecx, esi
mov ebp, ecx
mov dword [esp + 0x24], ecx
mov ecx, dword [esp + 0x74]
mov ecx, dword [ecx + 0x28]
lea edx, [eax + ebx]
cmp edx, ecx
jle 0x597fbd
sub ecx, ebx
mov eax, ecx
mov dword [esp + 0x14], ecx
test ebp, ebp
jle 0x5992f8
test eax, eax
jle 0x5992f8
mov ebx, dword [esp + 0x78]
mov ebp, dword [ebx + 8]
mov eax, dword [ebx + 0xc]
add ebp, 4
mov esi, ebp
imul esi, dword [esp + 0x14]
add eax, 4
mov dword [esp + 0x48], eax
xor ecx, ecx
lea eax, [esi*4]
mov edx, 4
mul edx
seto cl
mov dword [esp + 0x34], ebp
neg ecx
or ecx, eax
push ecx
call fcn.0060ae9b
shl esi, 4
push esi
push 0
push eax
mov dword [esp + 0x84], eax
call fcn.00626020
mov ecx, dword [ebx + 8]
mov dword [esp + 0x3c], ecx
fild dword [esp + 0x3c]
add esp, 0x10
fcom qword [edi + 0x10]
fnstsw ax
test ah, 0x41
jp 0x598241
cmp dword [esp + 0x24], 0
fdiv qword [edi + 0x10]
mov dword [esp + 0x2c], 0
fild dword [esp + 0x28]
fsub qword [edi]
fmul st(1)
fadd qword [0x65b8f8]
jle 0x5983b5
mov eax, dword [esp + 0x18]
fld qword [0x679468]
imul eax, dword [esp + 0x1c]
add eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x38]
lea edx, [ecx + eax*4]
mov dword [esp + 0x28], edx
fild dword [esp + 0x2c]
fmul st(3)
fadd st(2)
fld st(0)
fadd st(4)
fld st(1)
call fcn.006397d0
fld st(0)
mov ebx, eax
call fcn.006397d0
cmp ebx, eax
mov edi, dword [esp + 0x28]
mov dword [esp + 0x38], eax
mov dword [esp + 0x20], edi
jne 0x598132
fstp st(1)
shl ebx, 4
add ebx, dword [esp + 0x74]
fstp st(0)
fld st(2)
fmul st(1)
mov esi, ebx
call fcn.006397d0
cmp dword [esp + 0x14], 0
jle 0x598216
mov edx, dword [esp + 0x1c]
mov ecx, ebp
shl ecx, 4
add ecx, 0xfffffff4
mov dword [esp + 0x30], ecx
lea ecx, [edx*4]
mov edx, dword [esp + 0x14]
mov dword [esp + 0x38], ecx
mov ecx, dword [edi]
movzx ebx, cl
imul ebx, eax
add dword [esi], ebx
movzx ebx, ch
imul ebx, eax
add dword [esi + 4], ebx
add edi, dword [esp + 0x38]
add esi, 4
mov ebx, ecx
shr ebx, 0x10
and ebx, 0xff
imul ebx, eax
add dword [esi + 4], ebx
shr ecx, 0x18
imul ecx, eax
add esi, 4
add dword [esi + 4], ecx
add esi, 4
add esi, dword [esp + 0x30]
sub edx, 1
jne 0x5980ea
jmp 0x598216
fild dword [esp + 0x38]
fld st(0)
fsubrp st(3)
fxch st(2)
fmul st(3)
call fcn.006397d0
fsubrp st(1)
mov esi, eax
mov dword [esp + 0x30], esi
fmul st(1)
call fcn.006397d0
shl ebx, 4
add ebx, dword [esp + 0x74]
cmp dword [esp + 0x14], 0
mov ecx, ebx
jle 0x598216
mov edx, dword [esp + 0x14]
shl ebp, 4
add ebp, 0xffffffe4
mov dword [esp + 0x40], ebp
mov dword [esp + 0x38], edx
jmp 0x59817e
mov esi, dword [esp + 0x30]
mov ebx, dword [edi]
mov edi, ebx
and edi, 0xff
mov edx, edi
imul edi, eax
imul edx, esi
add dword [ecx], edx
mov edx, ebx
shr edx, 8
and edx, 0xff
mov ebp, edx
imul edx, eax
imul ebp, esi
add dword [ecx + 4], ebp
add ecx, 4
mov esi, ebx
shr esi, 0x10
and esi, 0xff
mov ebp, esi
imul esi, eax
imul ebp, dword [esp + 0x30]
add dword [ecx + 4], ebp
add ecx, 4
shr ebx, 0x18
mov ebp, ebx
imul ebx, eax
imul ebp, dword [esp + 0x30]
add dword [ecx + 4], ebp
add ecx, 4
add dword [ecx + 4], edi
mov edi, dword [esp + 0x20]
add ecx, 4
add dword [ecx + 4], edx
mov edx, dword [esp + 0x1c]
add ecx, 4
add dword [ecx + 4], esi
add ecx, 4
add dword [ecx + 4], ebx
add ecx, 4
add ecx, dword [esp + 0x40]
add edx, edx
add edx, edx
add edi, edx
sub dword [esp + 0x38], 1
mov dword [esp + 0x20], edi
jne 0x59817a
mov ebp, dword [esp + 0x34]
mov eax, dword [esp + 0x2c]
add dword [esp + 0x28], 4
add eax, 1
cmp eax, dword [esp + 0x24]
mov dword [esp + 0x2c], eax
jl 0x59807a
mov edi, dword [esp + 0x7c]
fstp st(2)
mov ebx, dword [esp + 0x78]
fstp st(1)
jmp 0x5983bb
cmp ecx, 1
fld qword [0x65b8f8]
je 0x598262
fstp st(1)
add ecx, 0xffffffff
fld qword [edi + 0x10]
mov dword [esp + 0x40], ecx
fsub st(1)
fild dword [esp + 0x40]
fdivp st(1)
jmp 0x598269
fld qword [edi + 0x10]
fdivrp st(2)
fxch st(1)
lea eax, [ebp - 1]
cmp eax, 1
mov dword [esp + 0x2c], 1
jle 0x5983b9
mov eax, dword [esp + 0x18]
fld qword [0x679468]
imul eax, dword [esp + 0x1c]
mov esi, dword [esp + 0x74]
add esi, 0x10
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], esi
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x7c]
add eax, 0xffffffff
mov dword [esp + 0x40], eax
fild dword [esp + 0x40]
fmul st(2)
fadd qword [ecx]
fld st(0)
call fcn.006397d0
mov ebx, eax
mov dword [esp + 0x40], ebx
fisub dword [esp + 0x40]
fsubr st(3)
fmul st(1)
call fcn.006397d0
mov edx, dword [esp + 0x20]
mov ecx, dword [esp + 0x38]
mov edi, 0x101
add edx, ebx
sub edi, eax
cmp dword [esp + 0x14], 0
lea ecx, [ecx + edx*4]
jle 0x598386
mov edx, dword [esp + 0x14]
shl ebp, 4
add ebp, 0xfffffff4
mov dword [esp + 0x30], ebp
mov dword [esp + 0x28], edx
mov edx, dword [ecx]
add ecx, 4
mov dword [esp + 0x40], ecx
mov ecx, dword [ecx]
movzx ebx, cl
imul ebx, edi
movzx ebp, dl
imul ebp, eax
add ebx, ebp
mov dword [esi], ebx
movzx ebx, ch
movzx ebp, dh
imul ebx, edi
imul ebp, eax
add ebx, ebp
mov dword [esi + 4], ebx
add esi, 4
mov ebx, ecx
mov ebp, edx
shr ebx, 0x10
shr ebp, 0x10
and ebx, 0xff
and ebp, 0xff
imul ebx, edi
shr ecx, 0x18
imul ebp, eax
shr edx, 0x18
imul ecx, edi
imul edx, eax
add esi, 4
add ecx, edx
mov edx, dword [esp + 0x1c]
add ebx, ebp
mov dword [esi], ebx
add esi, 4
mov dword [esi], ecx
mov ecx, dword [esp + 0x40]
add esi, dword [esp + 0x30]
lea edx, [edx*4 - 4]
add ecx, edx
sub dword [esp + 0x28], 1
jne 0x5982fd
mov ebp, dword [esp + 0x34]
mov ecx, dword [esp + 0x2c]
mov esi, dword [esp + 0x24]
add ecx, 1
add esi, 0x10
lea eax, [ebp - 1]
cmp ecx, eax
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x24], esi
jl 0x59829b
mov ebx, dword [esp + 0x78]
fstp st(1)
mov edi, dword [esp + 0x7c]
fstp st(1)
jmp 0x5983bb
fstp st(1)
jmp 0x5983bb
fstp st(0)
mov esi, dword [esp + 0x48]
fstp st(0)
imul esi, ebp
xor ecx, ecx
lea eax, [esi*4]
mov edx, 4
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0060ae9b
shl esi, 4
push esi
push 0
push eax
mov dword [esp + 0x30], eax
call fcn.00626020
mov ebx, dword [ebx + 0xc]
mov dword [esp + 0x3c], ebx
fild dword [esp + 0x3c]
add esp, 0x10
fcom qword [edi + 0x18]
fnstsw ax
test ah, 0x41
jp 0x5985e5
cmp dword [esp + 0x14], 0
fdiv qword [edi + 0x18]
mov dword [esp + 0x7c], 0
fst qword [esp + 0x60]
fild dword [esp + 0x18]
fsub qword [edi + 8]
fmul st(1)
fadd qword [0x65b8f8]
fstp qword [esp + 0x48]
jle 0x59876b
mov eax, ebp
shl eax, 4
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x30], eax
fild dword [esp + 0x7c]
sub esp, 8
fmul st(1)
fadd qword [esp + 0x50]
fst qword [esp + 0x48]
fld st(0)
faddp st(2)
fxch st(1)
fstp qword [esp + 0x60]
fstp qword [esp]
call fcn.00639dc0
call fcn.006397d0
fld qword [esp + 0x60]
fstp qword [esp]
mov edi, eax
call fcn.00639dc0
add esp, 8
call fcn.006397d0
cmp edi, eax
mov esi, dword [esp + 0x30]
mov dword [esp + 0x38], eax
jne 0x5984fe
fld qword [esp + 0x60]
imul edi, ebp
fld qword [0x679460]
fmul st(1)
shl edi, 4
add edi, dword [esp + 0x20]
call fcn.006397d0
test ebp, ebp
jle 0x5985c3
mov ecx, ebp
mov edx, dword [esi]
imul edx, eax
add dword [edi], edx
mov edx, dword [esi + 4]
add esi, 4
imul edx, eax
add dword [edi + 4], edx
mov edx, dword [esi + 4]
add edi, 4
imul edx, eax
add dword [edi + 4], edx
add esi, 4
mov edx, dword [esi + 4]
add edi, 4
imul edx, eax
add dword [edi + 4], edx
add esi, 4
add edi, 4
add esi, 4
add edi, 4
sub ecx, 1
jne 0x5984ba
jmp 0x5985c3
fild dword [esp + 0x38]
fld qword [esp + 0x40]
fsubr st(1)
fld qword [0x679460]
fmul st(1), st(0)
fxch st(1)
call fcn.006397d0
fld qword [esp + 0x58]
fsubrp st(2)
mov ebx, eax
fmulp st(1)
call fcn.006397d0
imul edi, ebp
mov edx, dword [esp + 0x20]
shl edi, 4
add edi, edx
mov ecx, edi
mov edi, dword [esp + 0x38]
imul edi, ebp
shl edi, 4
add edi, edx
test ebp, ebp
mov edx, edi
jle 0x5985bf
mov dword [esp + 0x38], ebp
lea ebx, [ebx]
mov edi, dword [esi]
imul edi, ebx
add dword [ecx], edi
mov edi, dword [esi]
imul edi, eax
add dword [edx], edi
mov edi, dword [esi + 4]
imul edi, ebx
add dword [ecx + 4], edi
mov edi, dword [esi + 4]
add esi, 4
imul edi, eax
add dword [edx + 4], edi
mov edi, dword [esi + 4]
add ecx, 4
imul edi, ebx
add dword [ecx + 4], edi
mov edi, dword [esi + 4]
add edx, 4
imul edi, eax
add dword [edx + 4], edi
add esi, 4
mov edi, dword [esi + 4]
add ecx, 4
imul edi, ebx
add dword [ecx + 4], edi
mov edi, dword [esi + 4]
add edx, 4
imul edi, eax
add dword [edx + 4], edi
add esi, 4
add ecx, 4
add edx, 4
add ecx, 4
add esi, 4
add edx, 4
sub dword [esp + 0x38], 1
jne 0x598550
fld qword [esp + 0x60]
mov eax, dword [esp + 0x7c]
mov ecx, dword [esp + 0x1c]
add dword [esp + 0x30], ecx
add eax, 1
cmp eax, dword [esp + 0x14]
mov dword [esp + 0x7c], eax
jl 0x59844b
jmp 0x59876b
cmp ebx, 1
je 0x598606
fstp st(0)
lea edx, [ebx - 1]
fld qword [edi + 0x18]
mov dword [esp + 0x48], edx
fld qword [0x65b8f8]
fsub st(1), st(0)
fild dword [esp + 0x48]
fdivp st(2)
jmp 0x59860f
fdivr qword [edi + 0x18]
fld qword [0x65b8f8]
add ebx, 1
cmp ebx, 1
mov dword [esp + 0x30], 1
jle 0x5988d9
mov eax, dword [esp + 0x14]
fld qword [0x679460]
mov ecx, dword [esp + 0x20]
add eax, 0xffffffff
mov dword [esp + 0x40], eax
mov eax, ebp
shl eax, 4
lea esi, [eax + ecx + 0x10]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x2c], esi
jmp 0x59864f
mov edi, dword [esp + 0x7c]
fld qword [edi + 8]
fld st(0)
call fcn.006397d0
mov edx, dword [esp + 0x30]
mov dword [esp + 0x48], eax
fild dword [esp + 0x48]
add edx, 0xffffffff
mov dword [esp + 0x48], edx
fsubp st(1)
fild dword [esp + 0x48]
fmul st(4)
faddp st(1)
fld st(0)
call fcn.006397d0
mov ebx, eax
mov dword [esp + 0x48], ebx
fisub dword [esp + 0x48]
fsubr st(2)
fmul st(1)
call fcn.006397d0
mov ecx, ebx
imul ecx, ebp
add ecx, 1
shl ecx, 4
add ecx, dword [esp + 0x74]
mov edi, 0x100
sub edi, eax
cmp ebx, dword [esp + 0x40]
jne 0x5986b0
mov edx, ecx
jmp 0x5986c0
lea edx, [ebx + 1]
imul edx, ebp
add edx, 1
shl edx, 4
add edx, dword [esp + 0x74]
lea ebx, [ebp - 1]
cmp ebx, 1
jle 0x59873e
add ebx, 0xffffffff
mov dword [esp + 0x38], ebx
mov ebx, dword [edx]
mov ebp, dword [ecx]
imul ebx, edi
imul ebp, eax
add ebx, ebp
mov dword [esi], ebx
mov ebx, dword [edx + 4]
mov ebp, dword [ecx + 4]
imul ebx, edi
add edx, 4
imul ebp, eax
add ecx, 4
add ebx, ebp
mov dword [esi + 4], ebx
mov ebx, dword [edx + 4]
mov ebp, dword [ecx + 4]
imul ebx, edi
add esi, 4
imul ebp, eax
add edx, 4
add ecx, 4
add ebx, ebp
mov dword [esi + 4], ebx
mov ebx, dword [edx + 4]
mov ebp, dword [ecx + 4]
imul ebx, edi
add esi, 4
imul ebp, eax
add edx, 4
add ecx, 4
add esi, 4
add ebx, ebp
mov dword [esi], ebx
add esi, 4
add edx, 4
add ecx, 4
sub dword [esp + 0x38], 1
jne 0x5986cf
mov ebp, dword [esp + 0x34]
mov ecx, dword [esp + 0x78]
mov eax, dword [esp + 0x30]
mov esi, dword [esp + 0x2c]
mov edx, dword [ecx + 0xc]
add esi, dword [esp + 0x1c]
add eax, 1
add edx, 1
cmp eax, edx
mov dword [esp + 0x30], eax
mov dword [esp + 0x2c], esi
jl 0x59864b
fstp st(2)
fstp st(0)
mov ecx, dword [esp + 0x78]
fstp st(0)
xor edx, edx
cmp dword [ecx + 0xc], edx
mov dword [esp + 0x30], edx
jle 0x5988c5
mov eax, dword [esp + 0x20]
shl ebp, 4
lea ebx, [eax + ebp + 0x18]
mov dword [esp + 0x1c], ebp
mov dword [esp + 0x2c], ebx
mov eax, dword [ecx + 4]
mov esi, dword [esp + 0x70]
add eax, edx
imul eax, dword [esi + 0x24]
add eax, dword [ecx]
cmp dword [ecx + 8], 0
mov esi, dword [esp + 0x50]
lea eax, [esi + eax*4]
mov dword [esp + 0x7c], eax
mov dword [esp + 0x38], 0
jle 0x5988ab
mov dword [esp + 0x34], ebx
movzx ebp, word [ebx + 6]
test ebp, ebp
movzx edx, word [ebx - 6]
mov dword [esp + 0x48], edx
je 0x598881
mov ecx, dword [eax]
mov edi, ecx
shr edi, 0x18
mov esi, 0xff
sub esi, edi
imul esi, ebp
mov eax, 0x80808081
imul esi
add edx, esi
sar edx, 7
mov eax, ebp
mov esi, edx
imul eax, eax, 0xff
shr esi, 0x1f
add esi, edx
add esi, edi
cdq
idiv esi
movzx ebp, word [ebx + 2]
mov edx, ecx
and edx, 0xff0000
mov edi, 0x100
shl esi, 0x18
sub edi, eax
imul ebp, eax
imul edx, edi
shr edx, 8
and ebp, 0xffffff00
and edx, 0xff0000
shl ebp, 8
add ebp, edx
movzx edx, cl
imul edx, edi
mov ebx, eax
imul ebx, dword [esp + 0x48]
movzx edx, dh
sar ebx, 8
add edx, ebx
mov ebx, dword [esp + 0x34]
and ecx, 0xff00
or ebp, edx
imul ecx, edi
movzx edx, word [ebx - 2]
imul eax, edx
shr ecx, 8
and ecx, 0xff00
and eax, 0xffffff00
add ecx, eax
mov eax, dword [esp + 0x7c]
or ebp, ecx
mov ecx, dword [esp + 0x78]
or ebp, esi
mov dword [eax], ebp
mov edx, dword [esp + 0x38]
add edx, 1
add eax, 4
add ebx, 0x10
cmp edx, dword [ecx + 8]
mov dword [esp + 0x7c], eax
mov dword [esp + 0x38], edx
mov dword [esp + 0x34], ebx
jl 0x5987c3
mov ebp, dword [esp + 0x1c]
mov edx, dword [esp + 0x30]
mov ebx, dword [esp + 0x2c]
add edx, 1
add ebx, ebp
cmp edx, dword [ecx + 0xc]
mov dword [esp + 0x30], edx
mov dword [esp + 0x2c], ebx
jl 0x598793
mov eax, dword [esp + 0x20]
push eax
call fcn.0061c19f
mov ecx, dword [esp + 0x78]
push ecx
jmp 0x5992e5
fstp st(1)
jmp 0x59876b
mov edx, dword [esi + 0x4c]
mov eax, dword [ebx]
mov dword [esp + 0x38], edx
mov edx, dword [eax + 0x7c]
mov ecx, ebx
call edx
mov dword [esp + 0x60], eax
mov eax, esi
call fcn.00588a10
fld qword [edi]
sub esp, 8
fstp qword [esp]
mov dword [esp + 0x30], eax
call fcn.00639dc0
call fcn.006397d0
fld qword [edi + 8]
mov esi, eax
fstp qword [esp]
mov dword [esp + 0x28], esi
call fcn.00639dc0
call fcn.006397d0
fild dword [esp + 0x28]
mov dword [esp + 0x24], eax
fsubr qword [edi]
fadd qword [edi + 0x10]
fstp qword [esp]
call fcn.0061f440
call fcn.006397d0
fild dword [esp + 0x24]
mov dword [esp + 0x2c], eax
fsubr qword [edi + 8]
fadd qword [edi + 0x18]
fstp qword [esp]
call fcn.0061f440
add esp, 8
call fcn.006397d0
test esi, esi
mov dword [esp + 0x14], eax
jge 0x59896f
mov dword [esp + 0x20], 0
mov edx, dword [esp + 0x1c]
test edx, edx
jge 0x59897d
xor edx, edx
mov dword [esp + 0x1c], edx
mov esi, dword [esp + 0x74]
mov ecx, dword [esp + 0x20]
mov ebx, dword [esp + 0x24]
mov eax, dword [esi + 0x24]
add ebx, ecx
cmp ebx, eax
jle 0x598998
sub eax, ecx
mov dword [esp + 0x24], eax
mov eax, dword [esi + 0x28]
mov ecx, dword [esp + 0x14]
lea esi, [ecx + edx]
cmp esi, eax
jle 0x5989ae
sub eax, edx
mov ecx, eax
mov dword [esp + 0x14], ecx
cmp dword [esp + 0x24], 0
jle 0x5992f8
test ecx, ecx
jle 0x5992f8
mov ebx, dword [esp + 0x78]
mov esi, dword [ebx + 8]
mov eax, dword [ebx + 0xc]
add esi, 4
mov dword [esp + 0x74], esi
imul esi, ecx
add eax, 4
mov dword [esp + 0x58], eax
xor ecx, ecx
lea eax, [esi*4]
mov edx, 4
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0060ae9b
shl esi, 4
push esi
push 0
push eax
mov dword [esp + 0x28], eax
call fcn.00626020
mov ebx, dword [ebx + 8]
mov dword [esp + 0x3c], ebx
fild dword [esp + 0x3c]
add esp, 0x10
fcom qword [edi + 0x10]
fnstsw ax
test ah, 0x41
jp 0x598c26
cmp dword [esp + 0x24], 0
fdiv qword [edi + 0x10]
mov dword [esp + 0x2c], 0
fild dword [esp + 0x20]
fsub qword [edi]
fmul st(1)
fadd qword [0x65b8f8]
jle 0x598da5
mov eax, dword [esp + 0x1c]
fld qword [0x679468]
imul eax, dword [esp + 0x28]
add eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x38]
add eax, ecx
mov dword [esp + 0x50], eax
fild dword [esp + 0x2c]
fmul st(3)
fadd st(2)
fld st(0)
fadd st(4)
fld st(1)
call fcn.006397d0
fld st(0)
mov esi, eax
call fcn.006397d0
cmp esi, eax
mov edx, dword [esp + 0x2c]
mov ecx, dword [esp + 0x50]
lea edi, [edx + ecx]
mov dword [esp + 0x48], eax
mov dword [esp + 0x38], edi
jne 0x598b17
fstp st(1)
shl esi, 4
add esi, dword [esp + 0x18]
fstp st(0)
fld st(2)
fmul st(1)
call fcn.006397d0
cmp dword [esp + 0x14], 0
jle 0x598c04
mov edx, dword [esp + 0x74]
shl edx, 4
add edx, 0xfffffff4
mov dword [esp + 0x34], edx
mov edx, dword [esp + 0x14]
movzx ecx, byte [edi]
mov ecx, dword [ebp + ecx*4]
movzx ebx, cl
imul ebx, eax
add dword [esi], ebx
movzx ebx, ch
imul ebx, eax
add dword [esi + 4], ebx
add edi, dword [esp + 0x28]
add esi, 4
mov ebx, ecx
shr ebx, 0x10
and ebx, 0xff
imul ebx, eax
add dword [esi + 4], ebx
shr ecx, 0x18
imul ecx, eax
add esi, 4
add dword [esi + 4], ecx
add esi, 4
add esi, dword [esp + 0x34]
sub edx, 1
jne 0x598aca
jmp 0x598c04
fild dword [esp + 0x48]
fld st(0)
fsubrp st(3)
fxch st(2)
fmul st(3)
call fcn.006397d0
fsubrp st(1)
mov ebx, eax
fmul st(1)
call fcn.006397d0
shl esi, 4
add esi, dword [esp + 0x18]
cmp dword [esp + 0x14], 0
mov ecx, esi
jle 0x598c04
mov edx, dword [esp + 0x74]
shl edx, 4
add edx, 0xffffffe4
mov dword [esp + 0x20], edx
mov edx, dword [esp + 0x14]
mov dword [esp + 0x34], edx
movzx edx, byte [edi]
mov edi, dword [ebp + edx*4]
mov edx, edi
and edx, 0xff
mov esi, ebx
imul esi, edx
add dword [ecx], esi
mov dword [esp + 0x48], edx
mov edx, edi
shr edx, 8
and edx, 0xff
mov esi, ebx
imul esi, edx
add dword [ecx + 4], esi
add ecx, 4
mov esi, edi
shr esi, 0x10
and esi, 0xff
mov ebp, ebx
imul ebp, esi
add dword [ecx + 4], ebp
add ecx, 4
shr edi, 0x18
mov dword [esp + 0x40], edi
mov ebp, ebx
imul ebp, edi
add dword [ecx + 4], ebp
mov edi, eax
imul edi, dword [esp + 0x48]
add ecx, 4
add dword [ecx + 4], edi
add ecx, 4
mov edi, eax
imul edi, edx
add dword [ecx + 4], edi
mov edi, dword [esp + 0x38]
add edi, dword [esp + 0x28]
mov ebp, dword [esp + 0x30]
mov edx, eax
imul edx, esi
add ecx, 4
add dword [ecx + 4], edx
add ecx, 4
mov edx, eax
imul edx, dword [esp + 0x40]
add dword [ecx + 4], edx
add ecx, 4
add ecx, dword [esp + 0x20]
sub dword [esp + 0x34], 1
mov dword [esp + 0x38], edi
jne 0x598b5d
mov eax, dword [esp + 0x2c]
add eax, 1
cmp eax, dword [esp + 0x24]
mov dword [esp + 0x2c], eax
jl 0x598a66
mov edi, dword [esp + 0x7c]
fstp st(2)
fstp st(1)
jmp 0x598dab
cmp ebx, 1
fld qword [0x65b8f8]
je 0x598c47
fstp st(1)
add ebx, 0xffffffff
fld qword [edi + 0x10]
mov dword [esp + 0x50], ebx
fsub st(1)
fild dword [esp + 0x50]
fdivp st(1)
jmp 0x598c4e
fld qword [edi + 0x10]
fdivrp st(2)
fxch st(1)
mov eax, dword [esp + 0x74]
mov ebx, 1
add eax, 0xffffffff
cmp eax, ebx
mov dword [esp + 0x2c], ebx
jle 0x598da9
mov eax, dword [esp + 0x1c]
fld qword [0x679468]
imul eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x38]
mov esi, dword [esp + 0x18]
add eax, ecx
add esi, 0x10
mov dword [esp + 0x48], eax
mov dword [esp + 0x24], esi
mov eax, dword [esp + 0x7c]
lea edx, [ebx - 1]
mov dword [esp + 0x50], edx
fild dword [esp + 0x50]
fmul st(2)
fadd qword [eax]
fld st(0)
call fcn.006397d0
mov dword [esp + 0x38], eax
fisub dword [esp + 0x38]
fsubr st(3)
fmul st(1)
call fcn.006397d0
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x48]
mov edi, 0x101
sub edi, eax
add ecx, edx
cmp dword [esp + 0x14], 0
jle 0x598d7a
mov edx, dword [esp + 0x74]
shl edx, 4
add edx, 0xfffffff4
mov dword [esp + 0x34], edx
mov edx, dword [esp + 0x14]
mov dword [esp + 0x38], edx
movzx edx, byte [ecx]
mov edx, dword [ebp + edx*4]
add ecx, 1
mov dword [esp + 0x50], ecx
movzx ecx, byte [ecx]
mov ecx, dword [ebp + ecx*4]
movzx ebx, cl
imul ebx, edi
movzx ebp, dl
imul ebp, eax
add ebx, ebp
mov dword [esi], ebx
movzx ebx, ch
movzx ebp, dh
imul ebx, edi
imul ebp, eax
add ebx, ebp
mov dword [esi + 4], ebx
add esi, 4
mov ebx, ecx
mov ebp, edx
shr ebx, 0x10
shr ebp, 0x10
and ebx, 0xff
and ebp, 0xff
imul ebx, edi
shr ecx, 0x18
imul ebp, eax
shr edx, 0x18
imul ecx, edi
imul edx, eax
add esi, 4
add ebx, ebp
mov ebp, dword [esp + 0x30]
add ecx, edx
mov edx, dword [esp + 0x28]
mov dword [esi], ebx
add esi, 4
mov dword [esi], ecx
mov ecx, dword [esp + 0x50]
add esi, dword [esp + 0x34]
add edx, 0xffffffff
add ecx, edx
sub dword [esp + 0x38], 1
jne 0x598ce7
mov ebx, dword [esp + 0x2c]
mov esi, dword [esp + 0x24]
mov eax, dword [esp + 0x74]
add ebx, 1
add esi, 0x10
add eax, 0xffffffff
cmp ebx, eax
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x24], esi
jl 0x598c8a
mov edi, dword [esp + 0x7c]
fstp st(1)
fstp st(1)
jmp 0x598dab
fstp st(1)
jmp 0x598dab
fstp st(0)
mov esi, dword [esp + 0x58]
fstp st(0)
imul esi, dword [esp + 0x74]
xor ecx, ecx
lea eax, [esi*4]
mov edx, 4
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0060ae9b
shl esi, 4
push esi
mov ebx, eax
push 0
push ebx
mov dword [esp + 0x40], ebx
call fcn.00626020
mov eax, dword [esp + 0x88]
mov ecx, dword [eax + 0xc]
mov dword [esp + 0x3c], ecx
fild dword [esp + 0x3c]
add esp, 0x10
fcom qword [edi + 0x18]
fnstsw ax
test ah, 0x41
jp 0x598fe3
cmp dword [esp + 0x14], 0
fdiv qword [edi + 0x18]
mov dword [esp + 0x7c], 0
fst qword [esp + 0x50]
fild dword [esp + 0x1c]
fsub qword [edi + 8]
fmul st(1)
fadd qword [0x65b8f8]
fstp qword [esp + 0x40]
jle 0x599167
mov eax, dword [esp + 0x74]
mov ecx, dword [esp + 0x18]
shl eax, 4
mov dword [esp + 0x28], eax
mov dword [esp + 0x34], ecx
fild dword [esp + 0x7c]
sub esp, 8
fmul st(1)
fadd qword [esp + 0x48]
fst qword [esp + 0x40]
fld st(0)
faddp st(2)
fxch st(1)
fstp qword [esp + 0x50]
fstp qword [esp]
call fcn.00639dc0
call fcn.006397d0
fld qword [esp + 0x50]
fstp qword [esp]
mov edi, eax
call fcn.00639dc0
add esp, 8
call fcn.006397d0
mov esi, dword [esp + 0x34]
mov ebp, eax
cmp edi, ebp
mov dword [esp + 0x58], ebp
jne 0x598f01
mov ebx, dword [esp + 0x74]
fld qword [esp + 0x50]
fld qword [0x679460]
imul edi, ebx
fmul st(1)
shl edi, 4
add edi, dword [esp + 0x30]
call fcn.006397d0
test ebx, ebx
jle 0x598fc1
mov ecx, ebx
mov edx, dword [esi]
imul edx, eax
add dword [edi], edx
mov edx, dword [esi + 4]
add esi, 4
imul edx, eax
add dword [edi + 4], edx
mov edx, dword [esi + 4]
add edi, 4
imul edx, eax
add dword [edi + 4], edx
add esi, 4
mov edx, dword [esi + 4]
add edi, 4
imul edx, eax
add dword [edi + 4], edx
add esi, 4
add edi, 4
add esi, 4
add edi, 4
sub ecx, 1
jne 0x598ebd
jmp 0x598fc1
fild dword [esp + 0x58]
fld qword [esp + 0x38]
fsubr st(1)
fld qword [0x679460]
fmul st(1), st(0)
fxch st(1)
call fcn.006397d0
fld qword [esp + 0x48]
fsubrp st(2)
mov ebx, eax
fmulp st(1)
call fcn.006397d0
imul edi, dword [esp + 0x74]
imul ebp, dword [esp + 0x74]
mov edx, dword [esp + 0x30]
shl edi, 4
shl ebp, 4
add edi, edx
add ebp, edx
cmp dword [esp + 0x74], 0
mov ecx, edi
mov edx, ebp
jle 0x598fbd
mov edi, dword [esp + 0x74]
mov ebp, dword [esi]
imul ebp, ebx
add dword [ecx], ebp
mov ebp, dword [esi]
imul ebp, eax
add dword [edx], ebp
mov ebp, dword [esi + 4]
imul ebp, ebx
add dword [ecx + 4], ebp
mov ebp, dword [esi + 4]
add esi, 4
imul ebp, eax
add dword [edx + 4], ebp
mov ebp, dword [esi + 4]
add ecx, 4
imul ebp, ebx
add dword [ecx + 4], ebp
mov ebp, dword [esi + 4]
add edx, 4
imul ebp, eax
add dword [edx + 4], ebp
add esi, 4
mov ebp, dword [esi + 4]
add ecx, 4
imul ebp, ebx
add dword [ecx + 4], ebp
mov ebp, dword [esi + 4]
add edx, 4
imul ebp, eax
add dword [edx + 4], ebp
add esi, 4
add ecx, 4
add edx, 4
add ecx, 4
add esi, 4
add edx, 4
sub edi, 1
jne 0x598f50
fld qword [esp + 0x50]
mov eax, dword [esp + 0x7c]
mov ecx, dword [esp + 0x28]
add dword [esp + 0x34], ecx
add eax, 1
cmp eax, dword [esp + 0x14]
mov dword [esp + 0x7c], eax
jl 0x598e48
jmp 0x599167
cmp ecx, 1
je 0x599004
fstp st(0)
lea edx, [ecx - 1]
fld qword [edi + 0x18]
mov dword [esp + 0x58], edx
fld qword [0x65b8f8]
fsub st(1), st(0)
fild dword [esp + 0x58]
fdivp st(2)
jmp 0x59900d
fdivr qword [edi + 0x18]
fld qword [0x65b8f8]
add ecx, 1
cmp ecx, 1
mov dword [esp + 0x34], 1
jle 0x599302
mov eax, dword [esp + 0x14]
fld qword [0x679460]
add eax, 0xffffffff
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0x74]
shl eax, 4
lea esi, [ebx + eax + 0x10]
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], esi
jmp 0x59904b
mov edi, dword [esp + 0x7c]
fld qword [edi + 8]
fld st(0)
call fcn.006397d0
mov ecx, dword [esp + 0x34]
mov dword [esp + 0x58], eax
fild dword [esp + 0x58]
add ecx, 0xffffffff
mov dword [esp + 0x58], ecx
fsubp st(1)
fild dword [esp + 0x58]
fmul st(4)
faddp st(1)
fld st(0)
call fcn.006397d0
mov ebp, eax
mov dword [esp + 0x58], ebp
fisub dword [esp + 0x58]
fsubr st(2)
fmul st(1)
call fcn.006397d0
mov ebx, dword [esp + 0x74]
mov ecx, ebp
imul ecx, ebx
add ecx, 1
shl ecx, 4
add ecx, dword [esp + 0x18]
mov edi, 0x100
sub edi, eax
cmp ebp, dword [esp + 0x50]
jne 0x5990b0
mov edx, ecx
jmp 0x5990c0
lea edx, [ebp + 1]
imul edx, ebx
add edx, 1
shl edx, 4
add edx, dword [esp + 0x18]
add ebx, 0xffffffff
cmp ebx, 1
jle 0x59913a
add ebx, 0xffffffff
mov dword [esp + 0x38], ebx
mov ebx, dword [ecx]
mov ebp, dword [edx]
imul ebx, eax
imul ebp, edi
add ebx, ebp
mov dword [esi], ebx
mov ebx, dword [ecx + 4]
mov ebp, dword [edx + 4]
imul ebx, eax
add edx, 4
imul ebp, edi
add ecx, 4
add ebx, ebp
mov dword [esi + 4], ebx
mov ebx, dword [ecx + 4]
mov ebp, dword [edx + 4]
imul ebx, eax
add esi, 4
imul ebp, edi
add edx, 4
add ecx, 4
add ebx, ebp
mov dword [esi + 4], ebx
mov ebx, dword [ecx + 4]
mov ebp, dword [edx + 4]
imul ebx, eax
add esi, 4
imul ebp, edi
add edx, 4
add ecx, 4
add esi, 4
add ebx, ebp
mov dword [esi], ebx
add esi, 4
add edx, 4
add ecx, 4
sub dword [esp + 0x38], 1
jne 0x5990cf
mov edx, dword [esp + 0x78]
mov eax, dword [esp + 0x34]
mov esi, dword [esp + 0x2c]
mov ecx, dword [edx + 0xc]
add esi, dword [esp + 0x28]
add eax, 1
add ecx, 1
cmp eax, ecx
mov dword [esp + 0x34], eax
mov dword [esp + 0x2c], esi
jl 0x599047
fstp st(2)
fstp st(0)
mov eax, dword [esp + 0x78]
fstp st(0)
xor edx, edx
cmp dword [eax + 0xc], edx
mov dword [esp + 0x34], edx
jle 0x5992d6
mov eax, dword [esp + 0x74]
mov ecx, dword [esp + 0x30]
shl eax, 4
mov esi, eax
lea ebx, [ecx + esi + 0x18]
mov dword [esp + 0x28], esi
mov dword [esp + 0x2c], ebx
mov ecx, dword [esp + 0x78]
mov eax, dword [ecx + 4]
mov edi, dword [esp + 0x70]
add eax, edx
imul eax, dword [edi + 0x24]
add eax, dword [ecx]
cmp dword [ecx + 8], 0
mov edi, dword [esp + 0x60]
lea eax, [edi + eax*4]
mov dword [esp + 0x7c], eax
mov dword [esp + 0x74], 0
jle 0x5992b8
mov dword [esp + 0x38], ebx
lea esp, [esp]
movzx ebp, word [ebx + 6]
test ebp, ebp
movzx ecx, word [ebx - 6]
mov dword [esp + 0x58], ecx
je 0x59928a
mov ecx, dword [eax]
mov edi, ecx
shr edi, 0x18
mov esi, 0xff
sub esi, edi
imul esi, ebp
mov eax, 0x80808081
imul esi
add edx, esi
sar edx, 7
mov eax, ebp
mov esi, edx
imul eax, eax, 0xff
shr esi, 0x1f
add esi, edx
add esi, edi
cdq
idiv esi
movzx ebp, word [ebx + 2]
mov edx, ecx
and edx, 0xff0000
mov edi, 0x100
shl esi, 0x18
sub edi, eax
imul ebp, eax
imul edx, edi
shr edx, 8
and ebp, 0xffffff00
and edx, 0xff0000
shl ebp, 8
add ebp, edx
movzx edx, cl
imul edx, edi
mov ebx, eax
imul ebx, dword [esp + 0x58]
movzx edx, dh
sar ebx, 8
add edx, ebx
mov ebx, dword [esp + 0x38]
and ecx, 0xff00
or ebp, edx
imul ecx, edi
movzx edx, word [ebx - 2]
imul eax, edx
shr ecx, 8
and eax, 0xffffff00
and ecx, 0xff00
add ecx, eax
mov eax, dword [esp + 0x7c]
or ebp, ecx
or ebp, esi
mov dword [eax], ebp
mov ecx, dword [esp + 0x74]
mov edx, dword [esp + 0x78]
add ecx, 1
add eax, 4
add ebx, 0x10
cmp ecx, dword [edx + 8]
mov dword [esp + 0x7c], eax
mov dword [esp + 0x74], ecx
mov dword [esp + 0x38], ebx
jl 0x5991d0
mov edx, dword [esp + 0x34]
mov esi, dword [esp + 0x28]
mov ebx, dword [esp + 0x2c]
mov eax, dword [esp + 0x78]
add edx, 1
add ebx, esi
cmp edx, dword [eax + 0xc]
mov dword [esp + 0x34], edx
mov dword [esp + 0x2c], ebx
jl 0x599195
mov ecx, dword [esp + 0x30]
push ecx
call fcn.0061c19f
mov edx, dword [esp + 0x1c]
push edx
call fcn.0061c19f
mov ecx, dword [esp + 0x78]
mov eax, dword [ecx]
mov edx, dword [eax + 0x64]
add esp, 8
call edx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x5c
ret 0x10
fstp st(1)
jmp 0x599167