Function at 0x50bf80
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x608713
mov eax, dword fs:[0]
push eax
sub esp, 0x208
mov eax, dword [0x6b000c]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x200], ecx
mov eax, dword [ebp + 8]
mov ecx, str.NTFS_RAW
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x1d0], eax
mov eax, dword [eax + 8]
mov edi, dword [esi + 0x18]
mov ebx, dword [esi + 0x1c]
nop
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x50bff6
test dx, dx
je 0x50bff2
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x50bff6
add eax, 4
add ecx, 4
test dx, dx
jne 0x50bfd0
xor eax, eax
jmp 0x50bffb
sbb eax, eax
or eax, 1
test eax, eax
jne 0x50c043
push 0x80
call fcn.00560437
mov ecx, eax
add esp, 4
mov dword [ebp - 0x1e0], ecx
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0x1d0]
mov eax, dword [edx]
cmp dword [eax - 0xc], 0
jl 0x50c6ec
movzx eax, word [eax]
push eax
call fcn.004a8700
mov ecx, eax
mov dword [ebp - 0x1e4], ecx
jmp 0x50c10b
cmp dword [esi + 0x40], 0xffffffff
je 0x50c0dd
call fcn.0040bf10
mov ecx, eax
test ecx, ecx
je 0x50c6f6
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x1d0], eax
mov dword [ebp - 4], 2
lea eax, [ebp - 0x1d0]
push dword [esi + 0x40]
push 0x65d140
push eax
call fcn.0040d300
add esp, 0xc
push 0x78
call fcn.00560437
add esp, 4
mov dword [ebp - 0x1e0], eax
mov byte [ebp - 4], 3
mov ecx, eax
mov esi, dword [ebp - 0x1d0]
push esi
call fcn.0047b130
mov ecx, eax
mov dword [ebp - 0x1e4], ecx
mov byte [ebp - 4], 2
mov dword [ebp - 4], 0xffffffff
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x50c112
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0x1e4]
jmp 0x50c112
push 0x78
call fcn.00560437
add esp, 4
mov dword [ebp - 0x1e0], eax
mov dword [ebp - 4], 5
mov ecx, eax
mov edx, dword [ebp - 0x1d0]
push dword [edx]
call fcn.0047b130
mov ecx, eax
mov dword [ebp - 0x1e4], eax
mov dword [ebp - 4], 0xffffffff
test ecx, ecx
jne 0x50c11d
xor eax, eax
jmp 0x50c66b
mov dword [ebp - 0x214], ecx
mov dword [ebp - 4], 6
push ecx
lea ecx, [ebp - 0x1cc]
call fcn.00479b60
mov byte [ebp - 4], 7
push ebx
push edi
push str._Preview__start_ref_d._n
call fcn.004131f0
add esp, 0xc
cmp dword [ebp + 0x18], 0
push ebx
push edi
jne 0x50c172
lea ecx, [ebp - 0x1cc]
call fcn.0047a760
test eax, eax
jne 0x50c1c6
push str._Preview__ParseFileRecord_fail._n
call fcn.004131f0
add esp, 4
jmp 0x50c643
push dword [ebp - 0x1e4]
call fcn.0050bef0
mov esi, eax
test esi, esi
je 0x50c643
mov dword [ebp - 0x1e0], esi
mov byte [ebp - 4], 8
lea ecx, [ebp - 0x1cc]
push esi
push ebx
push edi
call fcn.0047a930
test eax, eax
jne 0x50c1b7
mov byte [ebp - 4], 7
push 0x30
push esi
call fcn.005603ff
add esp, 8
jmp 0x50c643
mov byte [ebp - 4], 7
push 0x30
push esi
call fcn.005603ff
add esp, 8
lea ecx, [ebp - 0x1cc]
mov dword [ebp - 0x174], 0x883
call fcn.0047abe0
test eax, eax
jne 0x50c1f1
push str._Preview__ParseAttrs_fail._n
call fcn.004131f0
add esp, 4
jmp 0x50c643
mov eax, dword [ebp - 0x168]
mov dword [ebp - 0x160], eax
test eax, eax
je 0x50c293
mov eax, dword [eax + 4]
test eax, eax
je 0x50c293
mov eax, dword [eax + 0x40]
test dword [eax + 0x20], 0x400
je 0x50c293
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x1cc]
call fcn.0047ae00
mov byte [ebp - 4], 9
cmp dword [ebp - 0x1c], 0
je 0x50c287
cmp dword [ebp - 0x18], 8
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x50c287
push dword [ebp + 0x10]
cmp dword [ebp - 0x18], 8
lea ecx, [ebp - 0x1d0]
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x1d0], 0
cmovae eax, dword [ebp - 0x2c]
push ecx
push eax
call fcn.0050ab30
mov esi, dword [ebp - 0x1d0]
mov byte [ebp - 4], 7
lea ecx, [ebp - 0x2c]
call fcn.00476270
jmp 0x50c645
mov byte [ebp - 4], 7
lea ecx, [ebp - 0x2c]
call fcn.00476270
push ecx
lea ecx, [ebp - 0x1cc]
mov dword [ebp - 0x1f8], 0x10000
call fcn.0047b040
mov ebx, eax
mov eax, dword [ebp - 0x168]
mov dword [ebp - 0x208], ebx
mov dword [ebp - 0x160], eax
test eax, eax
je 0x50c2dc
mov eax, dword [eax + 4]
test eax, eax
je 0x50c2dc
mov eax, dword [eax + 0x40]
mov esi, dword [eax + 0x20]
and esi, 0x800
mov dword [ebp - 0x204], esi
jmp 0x50c2e6
mov dword [ebp - 0x204], 0
push ebx
push str._Preview__CAttrBase_x._n
call fcn.004131f0
add esp, 8
test ebx, ebx
je 0x50c643
mov eax, dword [ebx]
mov ecx, ebx
push 0
mov eax, dword [eax + 8]
call eax
mov esi, eax
mov dword [ebp - 0x1fc], edx
lea eax, [ebp - 0x1dc]
mov dword [ebp - 0x20c], esi
push eax
push 1
push 0
mov dword [ebp - 0x1dc], 0
call dword [sym.imp.ole32.dll_CreateStreamOnHGlobal]
test eax, eax
js 0x50c643
mov edi, dword [ebp + 0x10]
mov eax, edi
or eax, dword [ebp + 0x14]
mov dword [ebp - 0x1e0], 1
jne 0x50c689
mov ebx, dword [ebp - 0x1fc]
mov edi, esi
push 0x10000
mov dword [ebp - 0x1d8], ebx
call fcn.00560596
add esp, 4
xorps xmm0, xmm0
movlpd qword [ebp - 0x1f4], xmm0
mov esi, eax
test ebx, ebx
jb 0x50c621
ja 0x50c390
test edi, edi
jbe 0x50c621
nop word [eax + eax]
push 0x10000
push 0
push esi
call fcn.00588800
mov ecx, dword [ebp - 0x208]
lea edx, [ebp - 0x1d4]
add esp, 0xc
mov eax, dword [ecx]
push edx
push 0x10000
push esi
lea edx, [ebp - 0x1f4]
push edx
call dword [eax + 0xc]
test eax, eax
je 0x50c617
mov edx, dword [ebp - 0x1d4]
cmp edx, 0x10000
je 0x50c3e7
xor eax, eax
cmp edx, edi
jne 0x50c617
cmp eax, ebx
jne 0x50c617
mov eax, dword [ebp - 0x200]
cmp dword [eax + 4], 0
jne 0x50c617
cmp dword [ebp - 0x204], 0
je 0x50c5b1
mov ecx, dword [ebp - 0x208]
lea edx, [ebp - 0x1d4]
push edx
push 0x10000
push esi
mov eax, dword [ecx]
lea edx, [ebp - 0x1f4]
push edx
call dword [eax + 0x10]
push 0x10000
call fcn.00560596
mov edx, dword [ebp - 0x1d4]
add esp, 4
mov ebx, eax
test edx, edx
jne 0x50c45a
push ebx
mov dword [ebp - 0x1f8], 0x10000
call fcn.00560591
mov ebx, dword [ebp - 0x1d8]
add esp, 4
jmp 0x50c5db
movzx ecx, byte [esi + 1]
movzx eax, byte [esi]
shl ecx, 8
mov dword [ebp - 0x1f8], edx
mov dword [ebp - 0x1d0], 0
mov dword [ebp - 0x1e8], 0
add ecx, eax
je 0x50c578
lea eax, [ebp - 0x1e8]
mov ecx, ebx
push eax
lea eax, [ebp - 0x1d0]
push eax
push edx
push esi
call fcn.0047e1e0
add esp, 0x10
test eax, eax
jne 0x50c578
mov ecx, dword [ebp - 0x1dc]
lea eax, [ebp - 0x1ec]
push eax
mov eax, 0x10000
sub eax, dword [ebp - 0x1e8]
mov edx, dword [ecx]
push eax
push ebx
push ecx
call dword [edx + 0x10]
sub edi, dword [ebp - 0x1ec]
mov ecx, dword [ebp - 0x1d4]
sbb dword [ebp - 0x1d8], 0
cmp ecx, 0x10000
je 0x50c5a0
mov eax, dword [ebp - 0x1d0]
test eax, eax
je 0x50c5a0
mov edx, ecx
sub edx, eax
dec edx
or edx, 0xfff
inc edx
movzx ecx, byte [edx + esi + 1]
lea eax, [edx + esi]
movzx eax, byte [eax]
shl ecx, 8
add ecx, eax
je 0x50c56a
lea eax, [ebp - 0x1e8]
mov ecx, ebx
push eax
lea eax, [ebp - 0x1d0]
push eax
mov eax, dword [ebp - 0x1d4]
sub eax, edx
push eax
lea eax, [edx + esi]
push eax
call fcn.0047e1e0
mov edx, 0x10000
xor eax, eax
sub edx, dword [ebp - 0x1e8]
add esp, 0x10
cmp eax, dword [ebp - 0x1d8]
ja 0x50c553
jb 0x50c555
cmp edx, edi
jb 0x50c555
mov edx, edi
mov eax, dword [ebp - 0x1dc]
lea edi, [ebp - 0x1ec]
push edi
push edx
push ebx
mov ecx, dword [eax]
push eax
call dword [ecx + 0x10]
push ebx
call fcn.00560591
add esp, 4
jmp 0x50c621
mov eax, dword [ebp - 0x1dc]
lea edx, [ebp - 0x1ec]
push edx
mov edx, dword [ebp - 0x1d4]
push edx
mov ecx, dword [eax]
push esi
push eax
call dword [ecx + 0x10]
sub edi, dword [ebp - 0x1ec]
sbb dword [ebp - 0x1d8], 0
push ebx
call fcn.00560591
mov ebx, dword [ebp - 0x1d8]
add esp, 4
jmp 0x50c5db
mov eax, dword [ebp - 0x1dc]
lea ebx, [ebp - 0x210]
push ebx
push edx
push esi
mov ecx, dword [eax]
push eax
call dword [ecx + 0x10]
sub edi, dword [ebp - 0x1d4]
mov ebx, dword [ebp - 0x1d8]
sbb ebx, 0
mov dword [ebp - 0x1d8], ebx
mov ecx, dword [ebp - 0x1f4]
add ecx, dword [ebp - 0x1f8]
mov eax, dword [ebp - 0x1f0]
adc eax, 0
mov dword [ebp - 0x1f4], ecx
mov dword [ebp - 0x1f0], eax
cmp eax, dword [ebp - 0x1fc]
ja 0x50c621
jb 0x50c390
cmp ecx, dword [ebp - 0x20c]
jae 0x50c621
jmp 0x50c390
mov dword [ebp - 0x1e0], 0
push esi
call fcn.00560591
add esp, 4
cmp dword [ebp - 0x1e0], 0
jne 0x50c6e1
mov eax, dword [ebp - 0x1dc]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
xor esi, esi
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x1cc]
call fcn.00479c30
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x1e4]
mov ecx, eax
push 1
mov edx, dword [eax]
call dword [edx]
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0055f9be
mov esp, ebp
pop ebp
ret 0x14
push edi
call fcn.00560596
mov esi, eax
add esp, 4
test esi, esi
je 0x50c637
mov edx, dword [ebx]
lea eax, [ebp - 0x200]
push eax
push edi
push esi
lea eax, [ebp - 0x1f4]
xorps xmm0, xmm0
push eax
mov ecx, ebx
movlpd qword [ebp - 0x1f4], xmm0
call dword [edx + 0xc]
test eax, eax
je 0x50c6d8
mov eax, dword [ebp - 0x1dc]
lea edx, [ebp - 0x210]
push edx
push dword [ebp - 0x200]
mov ecx, dword [eax]
push esi
push eax
call dword [ecx + 0x10]
push esi
call fcn.00560591
add esp, 4
mov esi, dword [ebp - 0x1dc]
jmp 0x50c645
push 0x80070057
call fcn.0040b250
push 0x80004005
call fcn.0040b250
int3