Function at 0x53d040
Capabilities:
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x674540
push 0x5dfbd0
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
push ebx
push esi
push edi
mov eax, dword [0x6aae14]
xor dword [ebp - 8], eax
xor eax, ebp
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
xor ebx, ebx
mov dword [ebp - 4], ebx
str word [ebp - 0x1c]
mov dword [ebp - 0x20], ebx
cmp dword [0x697e34], ebx
je 0x53d1ed
mov dword [0x697e34], ebx
push str.DevicePhysicalMemory
lea eax, [ebp - 0x44]
push eax
call dword [0x75d3cc]
mov dword [ebp - 0x5c], 0x18
mov dword [ebp - 0x58], ebx
mov dword [ebp - 0x50], 0x40
lea ecx, [ebp - 0x44]
mov dword [ebp - 0x54], ecx
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 0x48], ebx
lea edx, [ebp - 0x5c]
push edx
push 4
push 0x75d048
call dword [0x75d3d0]
lea eax, [ebp - 0x3c]
push eax
movzx ecx, word [ebp - 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call dword [sym.imp.KERNEL32.dll_GetThreadSelectorEntry]
mov ecx, dword [ebp - 0x38]
movzx eax, cl
shl eax, 0x10
and ecx, 0xff000000
add eax, ecx
movzx edx, word [ebp - 0x3a]
add eax, edx
and eax, 0x7fffffff
add eax, 0x1c
mov dword [ebp - 0x28], eax
mov esi, eax
mov dword [ebp - 0x24], esi
mov ecx, 4
add ecx, eax
mov edi, dword [sym.imp.KERNEL32.dll_MapViewOfFile]
cmp esi, ecx
jae 0x53d183
push 0x1000
mov eax, esi
and eax, 0xfffff000
push eax
push ebx
push 4
mov ecx, dword [0x75d048]
push ecx
call edi
mov ebx, eax
test ebx, ebx
je 0x53d181
mov eax, esi
and eax, 0xfff
mov ecx, 0x1000
sub ecx, eax
mov edx, 4
sub edx, dword [ebp - 0x20]
cmp edx, ecx
mov edi, edx
jb 0x53d159
mov edi, ecx
push edi
add eax, ebx
push eax
lea eax, [ebp - 0x2c]
mov edx, dword [ebp - 0x20]
add eax, edx
push eax
call fcn.005e13c0
add esp, 0xc
push ebx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
add dword [ebp - 0x20], edi
add esi, edi
mov eax, dword [ebp - 0x28]
xor ebx, ebx
jmp 0x53d108
xor ebx, ebx
mov ecx, dword [ebp - 0x2c]
mov eax, ecx
and eax, 0xfff
neg eax
sbb eax, eax
not eax
and eax, ecx
jne 0x53d1d5
push 0xa0000
push ebx
push ebx
push 4
mov eax, dword [0x75d048]
push eax
call edi
xor esi, esi
mov dword [ebp - 0x30], esi
cmp esi, 0xa0
jae 0x53d1c9
mov ecx, esi
shl ecx, 0xc
lea edx, [ecx + 0x67]
cmp dword [ecx + eax + 0xc00], edx
je 0x53d1c9
inc esi
jmp 0x53d1aa
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
shl esi, 0xc
mov eax, esi
push 0x1000
push eax
push ebx
push 4
mov eax, dword [0x75d048]
push eax
call edi
mov dword [0x75d04c], eax
jmp 0x53d1f3
mov edi, dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x20], ebx
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x34], esi
mov eax, 0x70
mov ecx, dword [ebp + 0xc]
add eax, ecx
cmp esi, eax
jae 0x53d2ec
mov edx, esi
shr edx, 0x16
mov eax, dword [0x75d04c]
mov eax, dword [eax + edx*4]
test al, 1
je 0x53d284
test al, al
js 0x53d261
push 0x1000
and eax, 0xfffff000
push eax
push 0
push 4
mov ecx, dword [0x75d048]
push ecx
call edi
mov edx, esi
shr edx, 0xc
and edx, 0x3ff
mov ebx, dword [eax + edx*4]
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
test bl, 1
je 0x53d2ec
and ebx, 0xfffff000
jmp 0x53d270
mov ebx, esi
and ebx, 0x3ff000
and eax, 0xfffff000
add ebx, eax
push 0x1000
push ebx
push 0
push 4
mov eax, dword [0x75d048]
push eax
call edi
mov ebx, eax
test ebx, ebx
je 0x53d2ec
mov eax, esi
and eax, 0xfff
mov ecx, 0x1000
sub ecx, eax
mov edx, 0x70
sub edx, dword [ebp - 0x20]
cmp edx, ecx
mov edi, edx
jb 0x53d2a6
mov edi, ecx
push edi
add eax, ebx
push eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0x20]
add eax, ecx
push eax
call fcn.005e13c0
add esp, 0xc
push ebx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
add dword [ebp - 0x20], edi
add esi, edi
mov edi, dword [sym.imp.KERNEL32.dll_MapViewOfFile]
xor ebx, ebx
jmp 0x53d1f9
mov dword [ebp - 4], 0xfffffffe
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret