Function at 0x512532
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x150
mov eax, dword [0x5f2e68]
xor eax, ebp
mov dword [ebp - 8], eax
push ebx
xor eax, eax
push esi
push edi
xor ebx, ebx
mov word [ebp - 0x13c], bx
lea edi, [ebp - 0x13a]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
xor eax, eax
mov word [ebp - 0x14c], bx
lea edi, [ebp - 0x14a]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
push 0x103
stosw word es:[edi], ax
lea eax, [ebp - 0x113]
push ebx
push eax
mov dword [ebp - 0x128], ebx
mov byte [ebp - 0x114], bl
call fcn.005306b0
mov esi, dword [ebp + 8]
add esp, 0xc
neg esi
sbb esi, esi
push 0x1ec7
and esi, 0xffffffe0
add esi, 0x20
push str..UpdatePAULA.c
push esi
mov dword [ebp - 0x11c], ebx
mov dword [ebp - 0x12c], ebx
mov dword [ebp - 0x124], ebx
call fcn.00474c00
add esp, 0xc
push str.UULF.lts
lea edi, [ebp - 0x114]
call fcn.00470e3d
pop ecx
push ebx
push 0x61a8
push 3
push 7
mov eax, edi
push 3
push eax
mov eax, SQLGetDiagRec
call fcn.0042eb42
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
add esp, 0x18
mov dword [ebp - 0x118], eax
call edi
cmp dword [ebp - 0x118], 0xffffffff
jne 0x512645
cmp eax, 2
je 0x512637
cmp eax, 3
je 0x512637
cmp eax, 0xf
je 0x512637
cmp eax, 0x35
je 0x512637
push eax
push str._GetLastError_
lea eax, [ebp - 0x114]
push eax
push str.:7:IsUploadPackageUpdatesAllowed___FAILED:_CreateFile__s__FAILED:__s_ld
call fcn.0042b70b
add esp, 0x10
push esi
call fcn.00475a9e
xor eax, eax
inc eax
jmp 0x512953
push ebx
lea eax, [ebp - 0x11c]
push eax
push 4
lea eax, [ebp - 0x128]
push eax
push dword [ebp - 0x118]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x5128e8
cmp dword [ebp - 0x11c], 4
jb 0x5128e8
push ebx
lea eax, [ebp - 0x11c]
push eax
push 4
lea eax, [ebp - 0x12c]
push eax
push dword [ebp - 0x118]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x5128b4
cmp dword [ebp - 0x11c], 4
jb 0x5128b4
push ebx
lea eax, [ebp - 0x11c]
push eax
push 4
lea eax, [ebp - 0x124]
push eax
push dword [ebp - 0x118]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x51287c
cmp dword [ebp - 0x11c], 4
jb 0x51287c
push ebx
lea eax, [ebp - 0x11c]
push eax
push 0x10
lea eax, [ebp - 0x13c]
push eax
push dword [ebp - 0x118]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x512831
cmp dword [ebp - 0x11c], 0x10
jb 0x512831
mov edi, dword [ebp - 0x118]
call fcn.00435716
push esi
call fcn.00475a9e
pop ecx
xor eax, eax
xor ecx, ecx
movzx edx, byte [ebp + ecx - 0x13c]
add eax, edx
inc ecx
cmp ecx, 0x10
jb 0x512723
add eax, dword [ebp - 0x12c]
cmp eax, dword [ebp - 0x128]
je 0x512798
cmp dword [0x7101e4], ebx
je 0x51293d
push eax
push dword [ebp - 0x128]
lea eax, [ebp - 0x114]
push eax
push str.:6:IsUploadPackageUpdatesAllowed___FAILED:_The_file_flags_CheckSum_has_failed:_The_flag_file___s__is_invalid.__It_should_be__ld_but_was_found_to_be__ld.
call fcn.0042b70b
add esp, 0x10
lea eax, [ebp - 0x114]
call fcn.004314ff
test eax, eax
jne 0x512790
push str._GetLastError_
lea eax, [ebp - 0x114]
push eax
push str.:7:IsUploadPackageUpdatesAllowed___FAILED:_DeleteFile___s___FAILED:_Could_not_delete_the_invalid_file_lock_flag:__s
call fcn.0042b70b
add esp, 0xc
xor eax, eax
inc eax
jmp 0x512954
mov esi, 0x6ddd00
cmp dword [ebp - 0x124], esi
jbe 0x5127bd
push dword [ebp - 0x124]
push str.:9:IsUploadPackageUpdatesAllowed___encountered_a_SERIOUS_EXCEPTION:_The_time_out_cannot_be_greater_than_TWO_HOURS_but_was_found_to_be__ld
call fcn.0042b70b
pop ecx
pop ecx
mov dword [ebp - 0x124], esi
push 0x1f31
lea eax, [ebp - 0x14c]
push str..UpdatePAULA.c
push eax
call fcn.004fb92f
push ecx
mov edi, esp
lea esi, [ebp - 0x13c]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
sub esp, 0x10
lea esi, [ebp - 0x14c]
mov edi, esp
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
call fcn.004f9ee0
push eax
call fcn.0053146e
add esp, 0x24
cmp eax, dword [ebp - 0x124]
jl 0x51282a
lea eax, [ebp - 0x114]
call fcn.004314ff
test eax, eax
jne 0x51282a
push str._GetLastError_
lea eax, [ebp - 0x114]
push eax
push str.:7:IsUploadPackageUpdatesAllowed___FAILED:_DeleteFile___s___FAILED:_Could_not_delete_the_expired_lock_flag:__s
jmp 0x512788
xor eax, eax
jmp 0x512954
call edi
mov edi, dword [ebp - 0x118]
mov dword [ebp - 0x120], eax
call fcn.00435716
cmp dword [0x7101e4], ebx
je 0x512922
push dword [ebp - 0x120]
lea eax, [ebp - 0x114]
push str._GetLastError_
push 0x10
push dword [ebp - 0x11c]
push eax
push str.:7:IsUploadPackageUpdatesAllowed___FAILED:_ReadFile___FAILED_to_read_the_SYSTEMTIME_from___s_.__Read__ld_bytes_of__ld:__s_ld
call fcn.0042b70b
add esp, 0x18
jmp 0x512922
call edi
mov edi, dword [ebp - 0x118]
mov dword [ebp - 0x120], eax
call fcn.00435716
cmp dword [0x7101e4], ebx
je 0x512922
push dword [ebp - 0x120]
lea eax, [ebp - 0x114]
push str._GetLastError_
push eax
push str.:7:IsUploadPackageUpdatesAllowed___FAILED:_ReadFile___FAILED_to_read_the_Time_Out_DWORD_from___s_:__s_ld
jmp 0x51291a
call edi
mov edi, dword [ebp - 0x118]
mov dword [ebp - 0x120], eax
call fcn.00435716
cmp dword [0x7101e4], ebx
je 0x512922
push dword [ebp - 0x120]
lea eax, [ebp - 0x114]
push str._GetLastError_
push eax
push str.:7:IsUploadPackageUpdatesAllowed___FAILED:_ReadFile___FAILED_to_read_the_Process_Identifier_from___s_:__s_ld
jmp 0x51291a
call edi
mov edi, dword [ebp - 0x118]
mov dword [ebp - 0x120], eax
call fcn.00435716
cmp dword [0x7101e4], ebx
je 0x512922
push dword [ebp - 0x120]
lea eax, [ebp - 0x114]
push str._GetLastError_
push eax
push str.:7:IsUploadPackageUpdatesAllowed___FAILED:_ReadFile___FAILED_to_read_the_checksum_from___s_:__s_ld
call fcn.0042b70b
add esp, 0x10
push esi
call fcn.00475a9e
cmp dword [0x7101e4], ebx
pop ecx
jne 0x512790
push 0x37
call dword [sym.imp.KERNEL32.dll_Sleep]
push esi
mov dword [0x7101e4], 1
call fcn.00512532
mov dword [0x7101e4], ebx
pop ecx
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.005317e7
leave
ret