Function at 0x1006d610
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0xc]
sub esp, 0x24
push ebx
push esi
mov esi, dword [ebp + 8]
mov ebx, dword [esi + 0xc]
cmp ebx, ecx
je 0x1006d851
mov eax, dword [ebp + 0x10]
push edi
lea eax, [eax + eax*4]
add eax, eax
mov dword [ebp - 0x24], eax
mov ax, word [ecx]
sub ax, word [esi]
mov cx, word [ecx + 2]
sub cx, word [esi + 2]
movzx edx, ax
movzx edi, cx
test ax, ax
jne 0x1006d66a
test cx, cx
jne 0x1006d66a
mov ecx, dword [esi + 0x10]
movzx eax, word [ecx + 4]
neg ax
movzx edx, ax
movzx eax, word [ecx + 6]
neg ax
movzx edi, ax
movsx eax, dx
mov dword [ebp - 0x18], eax
cdq
mov ecx, eax
movsx edi, di
xor ecx, edx
sub ecx, edx
cmp edi, ecx
jle 0x1006d683
mov dword [ebp - 0x20], edi
jmp 0x1006d68f
mov eax, edi
neg eax
cmp eax, ecx
cmovg ecx, eax
mov dword [ebp - 0x20], ecx
movzx eax, word [esi + 4]
xor ecx, ecx
mov dword [ebp - 4], eax
movzx eax, word [esi + 6]
xor esi, esi
mov dword [ebp - 0xc], esi
xor edx, edx
mov si, word [ebp - 4]
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0x14], ebx
mov word [ebp - 6], ax
mov word [ebp - 2], si
movsx esi, si
cwde
imul eax, dword [ebp - 0x18]
imul esi, edi
sub esi, eax
je 0x1006d6ca
imul esi, esi
inc dword [ebp - 0xc]
add edx, esi
cmp byte [0x10292610], 0
mov dword [ebp - 0x1c], edx
je 0x1006d6ef
push esi
push str.Cutline:Final_perp_d_n
call sym.tesseract41.dll_void___cdecl_tprintf_char_const__
mov ecx, dword [ebp - 0x10]
add esp, 8
mov edx, dword [ebp - 0x1c]
cmp esi, ecx
mov eax, ebx
cmovle eax, dword [ebp - 0x14]
cmovle esi, ecx
mov ecx, esi
mov dword [ebp - 0x14], eax
mov si, word [ebp - 2]
mov ax, word [ebp - 6]
add si, word [ebx + 4]
add ax, word [ebx + 6]
mov ebx, dword [ebx + 0xc]
mov dword [ebp - 0x10], ecx
mov word [ebp - 2], si
mov word [ebp - 6], ax
cmp ebx, dword [ebp + 0xc]
jne 0x1006d6b8
mov eax, dword [ebp - 0x18]
imul edi, edi
imul eax, eax
add edi, eax
jne 0x1006d755
push 0x22f
push str.C:Code_tesseract_srcccstructpolyaprx.cpp
push str.in_file__s__line__d
push 2
push str.perp___0
push 0x101b9ab8
call sym.tesseract41.dll_public:_void___cdecl_ERRCODE::error_char_const___enum_TessErrorLogCode__char_const__const
mov ecx, dword [ebp - 0x10]
add esp, 0x18
cmp ecx, 0x7fff00
jge 0x1006d769
shl ecx, 8
mov eax, ecx
cdq
idiv edi
mov ebx, eax
jmp 0x1006d773
mov eax, ecx
cdq
idiv edi
mov ebx, eax
shl ebx, 8
mov eax, dword [ebp - 0x1c]
cmp eax, 0x7fff00
jge 0x1006d789
imul edi, dword [ebp - 0xc]
shl eax, 8
cdq
idiv edi
jmp 0x1006d793
cdq
idiv edi
shl eax, 8
cdq
idiv dword [ebp - 0xc]
cmp byte [0x10292610], 0
mov esi, eax
mov edi, dword [ebp + 0x10]
je 0x1006d809
sub esp, 0x20
vxorps xmm1, xmm1, xmm1
vcvtsi2sd xmm1, xmm1, esi
vmulsd xmm0, xmm1, qword [0x101b9c48]
vxorps xmm2, xmm2, xmm2
vcvtsi2sd xmm2, xmm2, edi
vdivsd xmm0, xmm0, xmm2
vmovsd qword [esp + 0x18], xmm0
vmulsd xmm0, xmm1, qword [0x101b9c38]
vmovsd qword [esp + 0x10], xmm0
vxorps xmm3, xmm3, xmm3
vcvtsi2sd xmm3, xmm3, ebx
vmulsd xmm0, xmm3, qword [0x101b9c40]
vdivsd xmm0, xmm0, xmm2
vmovsd qword [esp + 8], xmm0
vmulsd xmm0, xmm3, qword [0x101b9c38]
vmovsd qword [esp], xmm0
push edi
push str.Cutline:A_d__max_.2f__.2f_____msd_.2f__.2f____n
call sym.tesseract41.dll_void___cdecl_tprintf_char_const__
add esp, 0x28
mov ecx, dword [ebp - 0x24]
lea eax, [ebx + ebx*4]
shl eax, 2
cmp eax, ecx
jge 0x1006d829
mov eax, esi
shl eax, 4
sub eax, esi
add eax, eax
cmp eax, ecx
jge 0x1006d829
cmp dword [ebp - 0x20], 0x7e
jl 0x1006d850
mov ebx, dword [ebp - 0x14]
push edi
push ebx
push dword [ebp + 8]
or byte [ebx + 8], 4
call sym.tesseract41.dll_void___cdecl_cutline_struct_EDGEPT___struct_EDGEPT___int_
mov ecx, dword [ebp + 0xc]
mov esi, ebx
add esp, 0xc
mov dword [ebp + 8], esi
mov ebx, dword [esi + 0xc]
cmp ebx, ecx
jne 0x1006d635
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret