Function at 0x528650
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x59c591
mov eax, dword fs:[0]
push eax
sub esp, 0xc8c
mov eax, dword [0x601018]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
xor ebx, ebx
mov dword [ebp - 0xc64], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0xc84], eax
mov dword [eax], ebx
mov dword [ebp - 0xc94], ebx
mov dword [ebp - 0xc80], ebx
mov dword [ebp - 0xc7c], ebx
mov dword [ebp - 0xc78], ebx
mov dword [ebp - 4], ebx
xor edi, edi
mov eax, 0x5bc564
lea esi, [ebp - 0x42c]
mov dword [ebp - 0x418], 0xf
mov dword [ebp - 0x41c], ebx
mov byte [ebp - 0x42c], bl
call fcn.00402fe0
mov byte [ebp - 0xc60], bl
mov byte [ebp - 0x848], bl
mov dword [ebp - 0x858], 1
mov dword [ebp - 0x860], ebx
mov dword [ebp - 0x85c], ebx
mov dword [ebp - 0x448], ebx
mov dword [ebp - 0x43c], ebx
push 0x10000
mov byte [ebp - 4], 2
call fcn.00596073
mov ecx, dword [ebp - 0xc64]
add esp, 4
push ebx
push ebx
push 3
push ebx
push ebx
mov esi, eax
push closesocket
push ecx
mov dword [ebp - 0x448], esi
mov dword [ebp - 0x444], esi
mov dword [ebp - 0x440], esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x860], eax
mov dword [ebp - 0x85c], ebx
cmp eax, 0xffffffff
je 0x5287ee
mov eax, dword [ebp - 0xc64]
lea edx, [ebp - 0xc60]
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
cmp cl, bl
jne 0x528765
mov edi, dword [ebp - 0x860]
mov dword [ebp - 0x858], ebx
cmp edi, 0xffffffff
jne 0x528830
mov edi, dword [ebp - 0x448]
mov esi, dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
cmp edi, ebx
je 0x5287a2
push edi
call esi
add esp, 4
xor edi, edi
mov dword [ebp - 0x448], edi
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0xc64]
push eax
push str.ERROR_:_failed_to_open_PDF_file____s___when_checking_UPDATE_status
mov ecx, 0x610240
mov dword [ebp - 0x860], ebx
call fcn.00504670
add esp, 8
cmp edi, ebx
je 0x5287d3
push edi
call esi
add esp, 4
cmp dword [ebp - 0x418], 0x10
jb 0x528e98
mov ecx, dword [ebp - 0x42c]
push ecx
call esi
jmp 0x528e95
mov dword [ebp - 0x858], 1
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor edi, edi
mov dword [ebp - 0x85c], eax
mov dword [ebp - 0x860], edi
cmp dword [0x61025c], ebx
je 0x528836
mov edx, dword [ebp - 0xc64]
push eax
push edx
push str.ERROR_15113:_unable_to_open_file___s___GetLastError__d_
mov ecx, 0x610240
call fcn.00504670
add esp, 0xc
jmp 0x528836
mov esi, dword [ebp - 0x448]
push 2
lea edx, [ebp - 0xc70]
push edx
or ecx, 0xffffffff
push ecx
mov eax, 0xfffffc00
push eax
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x5288ec
mov dword [ebp - 0x85c], ebx
cmp dword [ebp - 0xc6c], ebx
jg 0x5288fd
jl 0x528878
cmp dword [ebp - 0xc70], ebx
jae 0x5288fd
cmp esi, ebx
je 0x52888e
push esi
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
xor esi, esi
mov dword [ebp - 0x448], esi
cmp edi, ebx
je 0x5288a1
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor edi, edi
mov dword [ebp - 0x860], edi
mov eax, dword [ebp - 0xc64]
push eax
push str.ERROR_:_failed_to_call_Seek___in_file____s___when_checking_UPDATE_status
mov ecx, 0x610240
call fcn.00504670
add esp, 8
cmp esi, ebx
je 0x5288c8
push esi
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
cmp edi, ebx
je 0x5288d3
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x418], 0x10
jb 0x528e98
mov ecx, dword [ebp - 0x42c]
push ecx
jmp 0x528e8f
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x85c], eax
jmp 0x528878
push ebx
lea edx, [ebp - 0xc8c]
push edx
push 0x400
lea eax, [ebp - 0x410]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x52892c
mov dword [ebp - 0x85c], ebx
cmp dword [ebp - 0xc8c], ebx
jne 0x528942
jmp 0x528938
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x85c], eax
mov dword [ebp - 0x858], 1
mov dword [ebp - 0xc68], ebx
cmp dword [ebp - 0xc8c], ebx
jbe 0x5289c0
mov ecx, dword [ebp - 0xc68]
mov dl, byte [ebp + ecx - 0x410]
mov ecx, dword [ebp - 0x418]
mov byte [ebp - 0xc6c], dl
mov edx, dword [ebp - 0x42c]
mov eax, edx
cmp ecx, 0x10
jae 0x52897c
lea eax, [ebp - 0x42c]
add eax, dword [ebp - 0x41c]
cmp ecx, 0x10
mov ecx, edx
jae 0x52898f
lea ecx, [ebp - 0x42c]
cmp eax, ebx
jne 0x528997
xor eax, eax
jmp 0x528999
sub eax, ecx
mov ecx, dword [ebp - 0xc6c]
push ecx
lea edi, [ebp - 0x42c]
call fcn.00469ec0
mov eax, dword [ebp - 0xc68]
inc eax
mov dword [ebp - 0xc68], eax
cmp eax, dword [ebp - 0xc8c]
jb 0x528950
mov ecx, dword [ebp - 0xc8c]
push str.startxref
mov ebx, 9
lea edi, [ebp - 0x42c]
call fcn.0049d1d0
test eax, eax
jns 0x528a57
test esi, esi
je 0x5289f5
push esi
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
xor esi, esi
mov dword [ebp - 0x448], esi
mov edi, dword [ebp - 0x860]
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
test edi, edi
je 0x528a10
push edi
call ebx
xor edi, edi
mov dword [ebp - 0x860], edi
mov edx, dword [ebp - 0xc64]
push edx
push str.ERROR_:_failed_to_get_TRAILER_STARTXREF_from_file____s___when_checking_UPDATE_status
mov ecx, 0x610240
call fcn.00504670
add esp, 8
test esi, esi
je 0x528a37
push esi
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
test edi, edi
je 0x528a3e
push edi
call ebx
cmp dword [ebp - 0x418], 0x10
jb 0x528e98
mov eax, dword [ebp - 0x42c]
push eax
jmp 0x528e8f
cmp dword [ebp - 0x418], 0x10
mov ecx, dword [ebp - 0x42c]
jae 0x528a6c
lea ecx, [ebp - 0x42c]
mov edx, dword [ebp - 0x41c]
push 3
push 3
sub edx, eax
push 0x5e1ec8
push edx
add ecx, eax
lea edx, [ebp - 0xc80]
call fcn.0052c940
mov ecx, dword [ebp - 0xc7c]
mov ebx, dword [ebp - 0xc80]
sub ecx, ebx
mov eax, 0x92492493
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
add esp, 0x10
cmp eax, 3
je 0x528aee
mov edi, dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
test esi, esi
je 0x528ac4
push esi
call edi
add esp, 4
mov eax, dword [ebp - 0x860]
test eax, eax
je 0x528ad5
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x418], 0x10
jb 0x528e62
mov ecx, dword [ebp - 0x42c]
push ecx
jmp 0x528e5d
mov ecx, str.startxref
mov edi, ebx
call fcn.00494830
test al, al
je 0x528e2c
lea edi, [ebx + 0x38]
mov ecx, str.__EOF
call fcn.00494830
test al, al
je 0x528e2c
add ebx, 0x1c
cmp dword [ebx + 0x14], 0x10
jb 0x528b22
mov ebx, dword [ebx]
push ebx
call dword [sym.imp.MSVCR100.dll_atoi]
cdq
xor edi, edi
add esp, 4
cmp edx, edi
jg 0x528b41
jl 0x528db1
cmp eax, edi
jb 0x528db1
mov dword [ebp - 0xc70], eax
mov dword [ebp - 0xc6c], edx
lea ecx, [ecx]
push edi
lea ecx, [ebp - 0xc90]
push ecx
push edx
mov edx, dword [ebp - 0x860]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x528d7f
mov dword [ebp - 0x85c], edi
cmp dword [ebp - 0xc8c], edi
jl 0x528db1
jg 0x528b8f
cmp dword [ebp - 0xc90], edi
jb 0x528db1
cmp dword [ebp - 0x418], 0x10
mov eax, dword [ebp - 0x42c]
mov dword [ebp - 0x41c], edi
jae 0x528baa
lea eax, [ebp - 0x42c]
mov esi, dword [ebp - 0x858]
mov byte [eax], 0
cmp esi, edi
jne 0x528c4f
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
jmp 0x528bd0
mov edx, dword [ebp - 0x860]
push 0
lea eax, [ebp - 0xc68]
push eax
push 0x400
lea ecx, [ebp - 0x410]
push ecx
push edx
call edi
test eax, eax
je 0x528c07
cmp dword [ebp - 0xc68], 0
mov dword [ebp - 0x85c], 0
jne 0x528c1a
jmp 0x528c0f
call ebx
mov dword [ebp - 0x85c], eax
mov esi, 1
mov dword [ebp - 0x858], esi
mov eax, dword [ebp - 0xc68]
push eax
lea eax, [ebp - 0x410]
lea ecx, [ebp - 0x42c]
call fcn.00445440
push 5
push str.__EOF
lea ecx, [ebp - 0x42c]
push ecx
xor eax, eax
call fcn.00469c60
test eax, eax
jns 0x528c4f
test esi, esi
je 0x528bd0
mov esi, dword [ebp - 0x41c]
cmp esi, 0x11
jb 0x528db1
cmp dword [ebp - 0xc94], 1
jg 0x528dd7
push str._Prev
mov ebx, 5
mov ecx, esi
lea edi, [ebp - 0x42c]
call fcn.0049d1d0
test eax, eax
jg 0x528e10
push str.startxref
mov ebx, 9
mov ecx, esi
call fcn.0049d1d0
test eax, eax
js 0x528d8d
mov ecx, dword [ebp - 0x42c]
mov ebx, 0x10
cmp dword [ebp - 0x418], ebx
jae 0x528cb8
mov ecx, edi
push 3
push 3
sub esi, eax
push 0x5e1ec8
push esi
add ecx, eax
lea edx, [ebp - 0xc80]
call fcn.0052c940
mov ecx, dword [ebp - 0xc7c]
mov esi, dword [ebp - 0xc80]
sub ecx, esi
mov eax, 0x92492493
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
add esp, 0x10
cmp eax, 3
jne 0x528db1
mov ecx, str.startxref
mov edi, esi
call fcn.00494830
test al, al
je 0x528db1
lea edi, [esi + 0x38]
mov ecx, str.__EOF
call fcn.00494830
test al, al
je 0x528db1
cmp dword [esi + 0x30], ebx
lea eax, [esi + 0x1c]
jb 0x528d31
mov eax, dword [eax]
push eax
call dword [sym.imp.MSVCR100.dll_atoi]
cdq
add esp, 4
test edx, edx
jl 0x528db1
jg 0x528d46
test eax, eax
jb 0x528db1
cmp eax, dword [ebp - 0xc70]
jne 0x528d5a
cmp edx, dword [ebp - 0xc6c]
je 0x528e1e
mov ecx, dword [ebp - 0xc94]
inc ecx
mov dword [ebp - 0xc70], eax
mov dword [ebp - 0xc6c], edx
mov dword [ebp - 0xc94], ecx
cmp ecx, 0xa
jg 0x528d8d
xor edi, edi
jmp 0x528b50
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x85c], eax
jmp 0x528db1
lea esi, [ebp - 0xc60]
call fcn.00550f80
mov ecx, dword [ebp - 0xc64]
push ecx
push str.ERROR_:_failed_to_get_TRAILER_STARTXREF_from_file____s___when_checking_UPDATE_status
mov ecx, 0x610240
call fcn.00504670
add esp, 8
lea esi, [ebp - 0xc60]
call fcn.00550f80
lea esi, [ebp - 0x42c]
call fcn.004542a0
lea esi, [ebp - 0xc80]
call fcn.0044ad00
jmp 0x528e98
mov edx, dword [ebp - 0xc84]
mov dword [edx], 1
lea esi, [ebp - 0xc60]
call fcn.00550f80
lea esi, [ebp - 0x42c]
call fcn.004542a0
lea esi, [ebp - 0xc80]
call fcn.0044ad00
mov eax, 1
xor edx, edx
jmp 0x528e9d
mov eax, dword [ebp - 0xc84]
mov dword [eax], 1
jmp 0x528de3
mov edx, dword [ebp - 0xc84]
mov dword [edx], 0
jmp 0x528de3
mov edi, dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
test esi, esi
je 0x528e3c
push esi
call edi
add esp, 4
mov eax, dword [ebp - 0x860]
test eax, eax
je 0x528e4d
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x418], 0x10
jb 0x528e62
mov eax, dword [ebp - 0x42c]
push eax
call edi
add esp, 4
mov byte [ebp - 0x42c], 0
mov dword [ebp - 0x41c], 0
mov dword [ebp - 0x418], 0xf
test ebx, ebx
je 0x528e98
mov edi, dword [ebp - 0xc7c]
mov eax, ebx
call fcn.0044af60
push ebx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
or eax, 0xffffffff
or edx, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00596083
mov esp, ebp
pop ebp
ret