Function at 0x1001ed20
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_SetLastError]
xor esi, esi
push esi
call edi
mov ebx, dword [ebp + 8]
push ebx
call fcn.10018b20
test eax, eax
je 0x1001ed53
push 0xa0
call edi
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push 0x37e4
call fcn.1001b910
mov esi, dword [ebp + 0xc]
cmp eax, 1
jne 0x1001f40f
test esi, 0x800
jne 0x1001f40f
mov ecx, 0x100a2780
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1001ed80
sub ecx, edx
sar ecx, 1
push ecx
push 0x100a2780
push ebx
call fcn.1007b09b
add esp, 0xc
test eax, eax
jne 0x1001f40f
mov esi, dword [sym.imp.KERNEL32.dll_SetLastError]
xor edi, edi
push edi
call esi
test ebx, ebx
je 0x1001f3ea
push ebx
call fcn.10018b20
test eax, eax
jne 0x1001f3ea
push ebx
call fcn.1001cb30
mov ebx, eax
mov dword [ebp - 4], ebx
test ebx, ebx
je 0x1001f0f5
call fcn.1001e1d0
mov esi, eax
mov dword [ebp - 8], esi
test esi, esi
je 0x1001f0e1
push ebx
call fcn.10018b20
test eax, eax
je 0x1001efc8
mov dword [ebp - 0x14], 0x100a2e30
lea ebx, [ebp - 0x14]
mov dword [ebp - 0x10], 0x100a2dc0
nop dword [eax + eax]
mov ecx, dword [ebx]
mov esi, ecx
lea edx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x1001ee17
sub esi, edx
sar esi, 1
push esi
push ecx
push dword [ebp - 4]
call fcn.1007b09b
add esp, 0xc
test eax, eax
je 0x1001eea7
add ebx, 4
lea eax, [ebp - 0xc]
cmp ebx, eax
jb 0x1001ee10
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
lea eax, [ebp - 0xc]
cmp ebx, eax
mov ebx, dword [ebp - 4]
jne 0x1001f0ce
movzx eax, word [ebx]
cmp eax, 0x5c
je 0x1001ee90
cmp eax, 0x2f
je 0x1001ee90
push eax
call fcn.1007a780
add esp, 4
test eax, eax
je 0x1001f0ce
cmp word [ebx + 2], 0x3a
jne 0x1001f0ce
movzx eax, word [ebx + 4]
cmp eax, 0x5c
je 0x1001ee90
cmp eax, 0x2f
jne 0x1001f0ce
push dword [ebp - 8]
mov edi, ebx
xor ebx, ebx
call esi
push ebx
call esi
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1001f3d9
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 8]
lea esi, [eax + esi*2]
mov dword [ebp - 0x10], esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1001eeb6
sub ecx, edx
sar ecx, 1
test esi, esi
jne 0x1001ef04
lea esi, [ecx + 1]
lea eax, [esi + esi]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
test edi, edi
je 0x1001ee41
push dword [ebp - 8]
push esi
push edi
call fcn.1001c240
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
test eax, eax
jns 0x1001ee47
push edi
call esi
xor edi, edi
jmp 0x1001ee47
mov edx, esi
lea edi, [edx + 2]
nop dword [eax]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x1001ef10
sub edx, edi
sar edx, 1
test ecx, ecx
je 0x1001ef3f
mov eax, dword [ebp - 8]
cmp word [eax + ecx*2 - 2], 0x5c
je 0x1001ef3f
test edx, edx
je 0x1001ef3f
cmp word [esi], 0x5c
je 0x1001ef3f
mov eax, 1
jmp 0x1001ef41
xor eax, eax
mov dword [ebp - 0xc], eax
add eax, ecx
add eax, edx
lea esi, [eax*2 + 2]
push esi
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
test edi, edi
je 0x1001ee41
push dword [ebp - 8]
push esi
push edi
call fcn.1001c0d0
test eax, eax
jns 0x1001ef80
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
push edi
call esi
xor edi, edi
jmp 0x1001ee47
cmp dword [ebp - 0xc], 0
je 0x1001efa6
push 0x100a2890
push esi
push edi
call fcn.1001c020
test eax, eax
jns 0x1001efa6
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
push edi
call esi
xor edi, edi
jmp 0x1001ee47
push dword [ebp - 0x10]
push esi
push edi
call fcn.1001c020
test eax, eax
jns 0x1001ee41
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
push edi
call esi
xor edi, edi
jmp 0x1001ee47
mov ecx, esi
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1001efd0
sub ecx, edx
mov edx, ebx
sar ecx, 1
lea esi, [edx + 2]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x1001efe4
sub edx, esi
sar edx, 1
test ecx, ecx
je 0x1001f013
mov eax, dword [ebp - 8]
cmp word [eax + ecx*2 - 2], 0x5c
je 0x1001f013
test edx, edx
je 0x1001f013
cmp word [ebx], 0x5c
je 0x1001f013
mov ebx, 1
jmp 0x1001f015
xor ebx, ebx
lea eax, [ebx + edx]
add eax, ecx
lea esi, [eax*2 + 2]
push esi
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
test edi, edi
je 0x1001f0c5
push dword [ebp - 8]
push esi
push edi
call fcn.1001c0d0
test eax, eax
jns 0x1001f063
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
push edi
call esi
push dword [ebp - 8]
mov ebx, dword [ebp - 4]
xor edi, edi
call esi
push ebx
call esi
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1001f3d9
test ebx, ebx
je 0x1001f098
push 0x100a2890
push esi
push edi
call fcn.1001c020
test eax, eax
jns 0x1001f098
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
push edi
call esi
push dword [ebp - 8]
mov ebx, dword [ebp - 4]
xor edi, edi
call esi
push ebx
call esi
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1001f3d9
mov ebx, dword [ebp - 4]
push ebx
push esi
push edi
call fcn.1001c020
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
test eax, eax
jns 0x1001f0ce
push edi
call esi
push dword [ebp - 8]
xor edi, edi
call esi
push ebx
call esi
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1001f3d9
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
mov ebx, dword [ebp - 4]
push dword [ebp - 8]
call esi
push ebx
call esi
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1001f3d9
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
push ebx
call esi
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1001f3d9
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7e
jne 0x1001f292
mov esi, 0x100a2b10
lea ecx, [esi + 2]
nop dword [eax]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x1001f110
mov edx, dword [ebp + 8]
sub esi, ecx
mov ebx, edx
sar esi, 1
lea ecx, [ebx + 2]
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x1001f127
sub ebx, ecx
push edx
sar ebx, 1
call fcn.10019840
mov ecx, eax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1001f141
sub ecx, edx
sar ecx, 1
sub ecx, edi
je 0x1001f248
sub ecx, 1
je 0x1001f1d0
mov ecx, dword [ebp + 8]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1001f163
sub ecx, edx
sar ecx, 1
lea ebx, [ecx + 1]
lea eax, [ebx + ebx]
push eax
mov eax, dword [sym.imp.KERNEL32.dll_LocalAlloc]
push 0x40
call eax
mov esi, eax
test esi, esi
je 0x1001f28c
push dword [ebp + 8]
push ebx
push esi
call fcn.1001c240
test eax, eax
jns 0x1001f1a5
push esi
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
call esi
xor esi, esi
test esi, esi
je 0x1001f28c
push 0x37e4
call fcn.1001b910
test eax, eax
je 0x1001f2cb
push 0
call fcn.1001d420
mov ebx, eax
mov dword [ebp - 8], ebx
jmp 0x1001f2d5
lea ecx, [ebx - 1]
mov dword [ebp - 0x10], ecx
test ecx, ecx
js 0x1001f1a3
mov ebx, dword [ebp + 8]
lea edx, [ebx + 2]
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x1001f1e0
sub ebx, edx
sar ebx, 1
cmp ecx, ebx
cmovb ebx, ecx
inc ebx
lea eax, [ebx + ebx]
push eax
mov eax, dword [sym.imp.KERNEL32.dll_LocalAlloc]
push 0x40
call eax
mov esi, eax
test esi, esi
je 0x1001f28c
test ebx, ebx
je 0x1001f19a
cmp ebx, 0x7fffffff
jbe 0x1001f222
xor eax, eax
mov word [esi], ax
jmp 0x1001f19a
mov eax, dword [ebp - 0x10]
cmp eax, 0x7ffffffe
jbe 0x1001f236
xor eax, eax
mov word [esi], ax
jmp 0x1001f19a
push eax
push dword [ebp + 8]
push 0
push ebx
push esi
call fcn.1001c2b0
jmp 0x1001f196
lea eax, [ebx + esi]
lea ebx, [eax*2 + 2]
push ebx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov esi, eax
test esi, esi
je 0x1001f28c
push dword [ebp + 8]
push ebx
push esi
call fcn.1001c0d0
test eax, eax
js 0x1001f283
push 0x100a2b10
push ebx
push esi
call fcn.1001c020
test eax, eax
jns 0x1001f1ad
push esi
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
call esi
mov esi, dword [sym.imp.KERNEL32.dll_SetLastError]
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x1001f2a0
push 0x7e
call esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
test edi, edi
je 0x1001f3f9
push dword [ebp + 0xc]
push edi
call fcn.1001e9e0
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
call fcn.1001e1d0
mov ebx, eax
mov dword [ebp - 8], eax
test ebx, ebx
je 0x1001f3cc
mov ecx, ebx
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1001f2e2
sub ecx, edx
mov edx, esi
sar ecx, 1
lea edi, [edx + 2]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x1001f2f6
sub edx, edi
sar edx, 1
test ecx, ecx
je 0x1001f322
cmp word [ebx + ecx*2 - 2], 0x5c
je 0x1001f322
test edx, edx
je 0x1001f322
cmp word [esi], 0x5c
je 0x1001f322
mov eax, 1
jmp 0x1001f324
xor eax, eax
mov dword [ebp - 0xc], eax
add eax, edx
add eax, ecx
lea ebx, [eax*2 + 2]
push ebx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
test edi, edi
je 0x1001f3bb
push dword [ebp - 8]
push ebx
push edi
call fcn.1001c0d0
test eax, eax
js 0x1001f3b2
cmp dword [ebp - 0xc], 0
je 0x1001f369
push 0x100a2890
push ebx
push edi
call fcn.1001c020
test eax, eax
js 0x1001f3b2
push esi
push ebx
push edi
call fcn.1001c020
test eax, eax
js 0x1001f3b2
test edi, edi
je 0x1001f3bb
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x1001f389
test al, 0x50
je 0x1001f3bb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
cmp eax, 2
jne 0x1001f39e
push 0
call ebx
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
push dword [ebp - 8]
xor edi, edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x1001f3d2
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
xor edi, edi
push dword [ebp - 8]
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x1001f3d2
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
push esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
test edi, edi
je 0x1001f28c
push 0
call ebx
jmp 0x1001f2a0
push 0xa0
call esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x1001f3fc
mov ebx, dword [ebp + 8]
cmp eax, 0x7e
je 0x1001f40c
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 8
mov esi, dword [ebp + 0xc]
push esi
push ebx
call fcn.1001bb00
pop edi
mov esi, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8