Function at 0x4cf6b0
Capabilities:
Read file on windows
Terminate thread

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x4fb776
push eax
mov dword fs:[0], esp
sub esp, 0x94
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0xb4]
xor ebx, ebx
cmp edi, ebx
mov esi, ecx
jne 0x4cf6e6
or eax, 0xffffffff
jmp 0x4cfb6b
mov eax, dword [esi + 0x62788]
cmp eax, ebx
je 0x4cf74e
push 0x1388
push eax
mov dword [esi + 0x6278c], 1
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x4cf735
mov ecx, dword [esi + 0x62788]
lea eax, [esp + 0x10]
push eax
push ecx
mov dword [esp + 0x18], ebx
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
mov edx, dword [esp + 0x10]
mov eax, dword [esi + 0x62788]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov ecx, dword [esi + 0x62788]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 0x62788], ebx
mov dword [esi + 0x6278c], ebx
push 1
mov ecx, esi
call fcn.004d1b30
lea edx, [esi + 0x76]
push edi
push edx
mov dword [esi + 0x62790], 1
call dword [sym.imp.MSVCRT.dll_wcscpy]
push 0x51b1ec
push edi
call dword [sym.imp.MSVCRT.dll__wfopen]
mov ebp, eax
add esp, 0x10
cmp ebp, ebx
jne 0x4cf797
mov ecx, esi
call fcn.004d0400
mov ecx, esi
call fcn.004dea60
or eax, 0xffffffff
jmp 0x4cfb6b
lea ecx, [esp + 0x28]
call fcn.004f0f40
push str.BookMarkEvent
push 1
push ebx
push ebx
mov dword [esp + 0xbc], ebx
call dword [sym.imp.KERNEL32.dll_CreateEventW]
cmp eax, ebx
mov dword [esp + 0x10], eax
je 0x4cf7c7
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [esi + 0x6274c]
push eax
mov dword [esp + 0x1c], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [esp + 0x1c], 1
lea eax, [esp + 0x20]
mov byte [esp + 0xac], 1
push eax
mov dword [esp + 0x24], ebx
call fcn.004ce5e0
mov ebx, dword [sym.imp.MSVCRT.dll_fread]
push ebp
push 1
lea ecx, [esp + 0x30]
push 4
push ecx
call ebx
push ebp
push 1
lea edx, [esp + 0x30]
push 4
push edx
mov edi, eax
call ebx
add esp, 0x24
add edi, eax
je 0x4cf9fa
mov eax, dword [esp + 0x24]
cmp eax, 0x2711
jne 0x4cf84e
mov eax, dword [esp + 0x14]
push ebp
push eax
lea ecx, [esi + 0x1c]
push 1
push ecx
call ebx
mov ecx, dword [esp + 0x24]
add esp, 0x10
cmp ecx, eax
jne 0x4cfa07
jmp 0x4cf9cc
cmp eax, 0x2712
jne 0x4cf863
mov edx, dword [esp + 0x14]
push ebp
push edx
lea eax, [esi + 0x30]
push 1
push eax
jmp 0x4cf838
cmp eax, 0x2713
jne 0x4cf880
push ebp
mov ecx, esi
call fcn.004cf320
cmp eax, 0xffffffff
je 0x4cfa07
jmp 0x4cf9cc
cmp eax, 0x2714
jne 0x4cf89d
push ebp
push 1
lea ecx, [esi + 0x628]
push 4
push ecx
call ebx
add esp, 0x10
cmp eax, 1
jmp 0x4cf843
cmp eax, 0x2715
jne 0x4cf8ba
push ebp
push 1
lea edx, [esi + 0x62c]
push 4
push edx
call ebx
add esp, 0x10
cmp eax, 1
jmp 0x4cf843
cmp eax, 0x2716
jne 0x4cf8da
push ebp
push 0x14
lea eax, [esi + 0x388]
push 2
push eax
call ebx
add esp, 0x10
cmp eax, 0x14
jmp 0x4cf843
cmp eax, 0x2717
jne 0x4cf8fa
push ebp
push 1
lea ecx, [esi + 0x600]
push 1
push ecx
call ebx
add esp, 0x10
cmp eax, 1
jmp 0x4cf843
cmp eax, 0x271a
jne 0x4cf91a
push ebp
push 1
lea edx, [esi + 0x384]
push 1
push edx
call ebx
add esp, 0x10
cmp eax, 1
jmp 0x4cf843
cmp eax, 0x2719
jne 0x4cf93a
push ebp
push 1
lea eax, [esi + 0x3b0]
push 0x10
push eax
call ebx
add esp, 0x10
cmp eax, 1
jmp 0x4cf843
cmp eax, 0x2718
jne 0x4cf95a
push ebp
push 1
lea ecx, [esi + 0x3c0]
push 0x10
push ecx
call ebx
add esp, 0x10
cmp eax, 1
jmp 0x4cf843
cmp eax, 0x271b
jne 0x4cf97a
push ebp
push 1
lea edx, [esi + 0x5f8]
push 4
push edx
call ebx
add esp, 0x10
cmp eax, 1
jmp 0x4cf843
cmp eax, 0x271c
jne 0x4cf9f3
mov ecx, 0x18
xor eax, eax
lea edi, [esp + 0x42]
mov word [esp + 0x40], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push ebp
push 0x32
lea eax, [esp + 0x48]
push 2
push eax
call ebx
add esp, 0x10
cmp eax, 0x32
jne 0x4cfa07
cmp dword [esp + 0x20], 2
jne 0x4cf9cc
call fcn.004c6670
add eax, 0x8c
lea ecx, [esp + 0x40]
push eax
push ecx
call dword [sym.imp.SHLWAPI.dll_StrCmpW]
test eax, eax
jne 0x4cfa07
push ebp
push 1
lea edx, [esp + 0x2c]
push 4
push edx
call ebx
mov edi, eax
push ebp
push 1
lea eax, [esp + 0x2c]
push 4
push eax
call ebx
add esp, 0x20
add edi, eax
jne 0x4cf821
jmp 0x4cf9fa
cmp eax, 0x2af8
jne 0x4cfa07
push ebp
mov ecx, esi
call fcn.004cf4a0
cmp eax, 0xffffffff
jne 0x4cfa76
mov ecx, dword [esp + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push ebp
mov dword [esp + 0x20], 0
call dword [sym.imp.MSVCRT.dll_fclose]
mov edi, dword [esp + 0x14]
add esp, 4
test edi, edi
je 0x4cfa3a
push edi
call dword [sym.imp.KERNEL32.dll_SetEvent]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 1
mov ecx, esi
call fcn.004d1b30
mov ecx, esi
call fcn.004d0400
mov ecx, esi
mov dword [esi + 0x630], 1
call fcn.004dea60
lea ecx, [esp + 0x28]
mov dword [esp + 0xac], 0xffffffff
call fcn.004f0f80
xor eax, eax
jmp 0x4cfb6b
push ebp
call dword [sym.imp.MSVCRT.dll_fclose]
mov edi, dword [esp + 0x14]
add esp, 4
test edi, edi
je 0x4cfa96
push edi
call dword [sym.imp.KERNEL32.dll_SetEvent]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esi + 0x620]
mov ebx, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
test eax, eax
jne 0x4cfabe
mov edi, dword [esp + 0x18]
push edi
call ebx
mov ecx, esi
mov dword [esp + 0x1c], 0
call fcn.004d0400
jmp 0x4cfae4
mov edx, dword [esi + 0x608]
push 0x4ce9f0
push 0xc80
push eax
push edx
call dword [sym.imp.MSVCRT.dll_qsort]
add esp, 0x10
mov ecx, esi
call fcn.004d60c0
mov edi, dword [esp + 0x18]
lea eax, [esi + 0x1c]
mov ebp, 1
push eax
mov ecx, esi
mov dword [esi + 0x14], ebp
call fcn.004cfbb0
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x4cfb0a
push edi
call ebx
mov dword [esp + 0x1c], 0
mov ecx, esi
mov dword [esi + 0x630], ebp
call fcn.004dea60
mov ecx, esi
call fcn.004ded20
mov eax, dword [esi + 4]
cmp eax, 2
jne 0x4cfb2b
cmp dword [esi + 8], eax
je 0x4cfb33
push eax
mov ecx, esi
call fcn.004dea90
cmp dword [esp + 0x20], ebp
jne 0x4cfb4a
mov ecx, dword [esp + 0xb4]
push ecx
lea ecx, [esp + 0x2c]
call fcn.004f12e0
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x4cfb55
push edi
call ebx
lea ecx, [esp + 0x28]
mov dword [esp + 0xac], 0xffffffff
call fcn.004f0f80
mov eax, ebp
mov ecx, dword [esp + 0xa4]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0xa0
ret 4