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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xb20
mov eax, dword [0x4424f4]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0xc]
push ebx
push esi
push edi
xor esi, esi
mov dword [ebp - 0xae4], ecx
mov ecx, dword [ebp + 0x10]
xor edi, edi
inc esi
mov dword [ebp - 0xab8], eax
mov dword [ebp - 0xad8], ecx
mov ebx, edi
mov dword [ebp - 0xac0], ebx
cmp eax, 0xffffffff
je 0x438851
test edx, edx
jne 0x4381ab
mov edx, 0x40aae0
push 1
push 0x40ab1c
push edx
lea eax, [ebp - 0xb1c]
xor ecx, ecx
push eax
lea edx, [ebp - 0xab8]
call fcn.0043645b
test eax, eax
je 0x438851
mov eax, dword [0x443f94]
test eax, eax
je 0x43821d
push eax
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x43821d
push 0x100
lea eax, [ebp - 0xaac]
push eax
push 0x26d6
push dword [0x442af0]
call dword [sym.imp.USER32.dll_LoadStringW]
test eax, eax
je 0x43821d
lea eax, [ebp - 0xaac]
push eax
push edi
push 0x5c5
push dword [0x443f94]
call dword [sym.imp.USER32.dll_SendMessageW]
lea ecx, [ebp - 0xb1c]
call fcn.00436308
mov edi, eax
mov dword [ebp - 0xaec], edi
test edi, edi
je 0x438851
xor eax, eax
push 0x208
push eax
lea eax, [ebp - 0x294]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
push 0x4059f8
push edi
call dword [sym.imp.msvcrt.dll_wcstok]
mov edi, eax
mov dword [ebp - 0xacc], edi
pop ecx
pop ecx
test edi, edi
je 0x43883d
mov eax, dword [ebp - 0xab8]
mov dword [ebp - 0xabc], eax
push edi
push 0x40a198
push 4
call fcn.0041e83a
mov ecx, dword [ebp - 0xabc]
lea eax, [ebp - 0xafc]
add esp, 0xc
mov edx, edi
push eax
xor eax, eax
push eax
call fcn.00422caa
test eax, eax
je 0x43881d
mov ecx, dword [ebp - 0xabc]
mov edx, edi
mov dword [ebp - 0xac8], 1
call fcn.00422ba2
mov edi, eax
mov ecx, edi
mov dword [ebp - 0xae8], edi
call fcn.0041dc25
cmp edi, 1
jb 0x43881d
mov edi, dword [ebp - 0xac8]
mov ecx, edi
call fcn.0041dd92
inc edi
lea ecx, [ebp - 0xafc]
mov dword [ebp - 0xac8], edi
call fcn.00436308
mov dword [ebp - 0xac4], eax
test eax, eax
je 0x438811
push 0x409c5c
push eax
mov dword [ebp - 0xad4], eax
call dword [sym.imp.msvcrt.dll_wcsstr]
mov edi, eax
xor eax, eax
mov dword [ebp - 0xad0], edi
mov ebx, eax
mov dword [ebp - 0xab0], eax
mov dword [ebp - 0xab4], ebx
pop ecx
pop ecx
test edi, edi
je 0x4384e1
mov ecx, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
ret
jne 0x43833d
sub ecx, edx
sar ecx, 1
push 2
pop edx
lea eax, [ecx + 5]
xor ecx, ecx
mov dword [ebp - 0xae0], eax
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00440dea
mov ebx, eax
mov dword [ebp - 0xadc], ebx
pop ecx
test ebx, ebx
je 0x4384d4
add edi, 2
movzx eax, word [edi]
push eax
call dword [sym.imp.msvcrt.dll_iswalnum]
pop ecx
test eax, eax
jne 0x4383ad
push 2
pop ebx
xor eax, eax
cmp ax, word [edi]
je 0x4383a7
add edi, ebx
movzx eax, word [edi]
push eax
call dword [sym.imp.msvcrt.dll_iswalnum]
pop ecx
test eax, eax
je 0x43838f
mov ebx, dword [ebp - 0xadc]
mov edx, dword [ebp - 0xae0]
mov ecx, ebx
push edi
call fcn.0040c040
push 0x2c
push ebx
call dword [sym.imp.msvcrt.dll_wcschr]
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x4383e7
lea ecx, [edi + 2]
test ecx, ecx
je 0x4383da
call fcn.0041f003
jmp 0x4383dc
xor eax, eax
mov dword [ebp - 0xab4], eax
xor eax, eax
mov word [edi], ax
push 0x40a1c8
push ebx
call dword [sym.imp.msvcrt.dll__wcsicmp]
pop ecx
pop ecx
test eax, eax
jne 0x43843a
mov ecx, dword [ebp - 0xae4]
lea edx, [ebp - 0x294]
push 0x103
call fcn.0041e9d5
push dword [ebp - 0xacc]
lea eax, [ebp - 0x294]
mov dword [ebp - 0xab0], 1
push eax
push 0x40a1dc
push 4
call fcn.0041e83a
add esp, 0x10
jmp 0x4384c7
xor eax, eax
lea edx, [ebp - 0xab8]
push eax
push eax
push ebx
lea eax, [ebp - 0xb0c]
xor ecx, ecx
push eax
call fcn.0043645b
test eax, eax
je 0x4384bb
lea ecx, [ebp - 0xb0c]
call fcn.00436308
mov edi, eax
test edi, edi
je 0x4384bb
push ecx
push ecx
lea eax, [ebp - 0x294]
push eax
lea ecx, [ebp - 0xb0c]
call fcn.00436d06
test eax, eax
je 0x4384a6
push dword [ebp - 0xacc]
lea eax, [ebp - 0x294]
mov dword [ebp - 0xab0], 1
push eax
push 0x40a1dc
push 4
call fcn.0041e83a
add esp, 0x10
push edi
call fcn.00440db7
mov edi, dword [ebp - 0xab8]
pop ecx
mov dword [ebp - 0xabc], edi
jmp 0x4384c7
mov eax, dword [ebp - 0xab8]
mov dword [ebp - 0xabc], eax
push ebx
call fcn.00440db7
mov edi, dword [ebp - 0xad0]
pop ecx
mov ebx, dword [ebp - 0xab4]
xor eax, eax
mov word [edi], ax
jmp 0x4384f8
push dword [ebp - 0xac4]
push 0x40a210
push 2
pop eax
push eax
call fcn.0041e83a
add esp, 0xc
cmp dword [ebp - 0xab0], 0
je 0x43894f
xor eax, eax
lea ecx, [ebp - 0x49c]
mov ebx, eax
mov edx, 0x103
push 0x4015d0
mov dword [ebp - 0xab4], ebx
call fcn.0040c040
test edi, edi
je 0x4387e7
push dword [ebp - 0xad4]
lea ecx, [ebp - 0x8c]
push 0x3f
pop edx
call fcn.0040c040
lea eax, [ebp - 0x8c]
push 0x4059f8
push eax
call dword [sym.imp.msvcrt.dll_wcsstr]
mov dword [ebp - 0xad0], eax
pop ecx
pop ecx
test eax, eax
je 0x43856c
lea ecx, [eax + 2]
mov dword [ebp - 0xad4], ecx
xor ecx, ecx
mov word [eax], cx
lea eax, [ebp - 0x8c]
push eax
call dword [sym.imp.msvcrt.dll__wtol]
mov dword [ebp - 0xab0], eax
xor edi, edi
mov eax, ebx
pop ecx
sub eax, edi
je 0x43863a
sub eax, 1
je 0x4385a3
sub eax, 1
je 0x43863a
sub eax, 1
jne 0x4386df
lea eax, [ebp - 0x294]
mov edx, 0x104
push eax
lea ecx, [ebp - 0x6a4]
call fcn.0040c040
test eax, eax
js 0x4386c8
push 2
pop esi
push 0x5c
pop ebx
lea ecx, [ebp - 0x6a4]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, esi
cmp ax, di
jne 0x4385d1
sub ecx, edx
sar ecx, 1
je 0x4385f7
cmp word [ebp + ecx*2 - 0x6a6], bx
jne 0x4385f7
xor eax, eax
mov word [ebp + ecx*2 - 0x6a6], ax
jmp 0x4385c8
lea eax, [ebp - 0x6a4]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ebx, dword [ebp - 0xab4]
cmp eax, 0xffffffff
je 0x4386c8
test al, 0x10
je 0x4386c8
mov esi, 0x104
lea eax, [ebp - 0x49c]
push esi
push eax
lea eax, [ebp - 0x294]
push eax
call dword [sym.imp.KERNEL32.dll_GetLongPathNameW]
jmp 0x4386c0
lea eax, [ebp - 0x294]
mov edx, 0x104
push eax
lea ecx, [ebp - 0x8ac]
call fcn.0040c040
test eax, eax
js 0x4386c8
push 2
pop esi
push 0x5c
pop ebx
lea ecx, [ebp - 0x8ac]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, esi
cmp ax, di
jne 0x438664
sub ecx, edx
sar ecx, 1
je 0x43868a
cmp word [ebp + ecx*2 - 0x8ae], bx
jne 0x43868a
xor eax, eax
mov word [ebp + ecx*2 - 0x8ae], ax
jmp 0x43865b
lea eax, [ebp - 0x8ac]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ebx, dword [ebp - 0xab4]
cmp eax, 0xffffffff
je 0x4386c8
test al, 0x10
je 0x4386c8
mov esi, 0x104
lea eax, [ebp - 0x49c]
push esi
push eax
lea eax, [ebp - 0x294]
push eax
call dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
test eax, eax
je 0x4386c8
cmp eax, esi
jbe 0x4386df
lea eax, [ebp - 0x294]
mov edx, 0x103
push eax
lea ecx, [ebp - 0x49c]
call fcn.0040c040
inc ebx
mov dword [ebp - 0xab4], ebx
mov ebx, edi
push 0x4057a0
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov esi, eax
test esi, esi
je 0x43873b
push 0x4057d0
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edi, eax
test edi, edi
je 0x43872a
lea eax, [ebp - 0x49c]
mov ecx, edi
push eax
push dword [ebp - 0xab0]
push dword [ebp - 0xabc]
call dword [0x445628]
call edi
mov ebx, eax
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
xor edi, edi
test ebx, ebx
je 0x43873b
mov esi, edi
jmp 0x43875f
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jne 0x43874c
push 0x57
pop esi
test esi, esi
jle 0x438757
movzx esi, si
or esi, 0x80070000
test esi, esi
jne 0x438929
cmp dword [ebp - 0xad8], 0
je 0x438937
mov ebx, dword [ebp - 0xab0]
cmp ebx, 0x8000
jb 0x4388ff
push 0xc
call fcn.00440dbc
mov esi, eax
pop ecx
test esi, esi
jne 0x438866
cmp dword [0x442534], 0xffffffff
jne 0x4387a4
push ecx
push 2
pop eax
mov edx, eax
call fcn.0041e30f
push 2
pop eax
mov edx, 0x405988
mov ecx, eax
call fcn.0041e767
mov esi, 0x8007000e
mov dword [ebp - 0xac0], esi
mov ecx, 0x40a2a8
push 2
mov edx, esi
pop eax
push edx
push ebx
push ecx
push eax
call fcn.0041e83a
mov ebx, dword [ebp - 0xab4]
add esp, 0x10
cmp dword [ebp - 0xad0], 0
jne 0x43852c
mov ebx, dword [ebp - 0xac0]
push dword [ebp - 0xac4]
call fcn.00440db7
pop ecx
lea eax, [ebp - 0xafc]
push eax
push eax
call dword [sym.imp.SETUPAPI.dll_SetupFindNextLine]
test eax, eax
je 0x43881d
mov edi, dword [ebp - 0xac8]
cmp edi, dword [ebp - 0xae8]
jbe 0x4382dd
xor eax, eax
push 0x4059f8
push eax
call dword [sym.imp.msvcrt.dll_wcstok]
mov edi, eax
mov dword [ebp - 0xacc], eax
pop ecx
pop ecx
test edi, edi
jne 0x438279
push dword [ebp - 0xaec]
call fcn.00440db7
pop ecx
test esi, esi
js 0x438851
test ebx, ebx
jne 0x438853
mov ebx, esi
mov ecx, dword [ebp - 8]
mov eax, ebx
ret
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00441130
leave
ret 0xc
lea ecx, [ebp - 0x49c]
mov dword [esi], edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, di
jne 0x438871
sub ecx, edx
sar ecx, 1
push 2
pop edx
lea edi, [ecx + 1]
xor ecx, ecx
mov eax, edi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00440dea
mov dword [esi + 4], eax
pop ecx
test eax, eax
jne 0x4388d0
cmp dword [0x442534], 0xffffffff
jne 0x4388b5
push ecx
push 2
pop eax
mov edx, eax
call fcn.0041e30f
push 2
pop eax
mov edx, 0x405988
mov ecx, eax
call fcn.0041e767
push esi
call fcn.00440de5
pop ecx
jmp 0x4387b3
lea ecx, [ebp - 0x49c]
mov edx, edi
push ecx
mov ecx, eax
call fcn.0040c040
mov ecx, dword [ebp - 0xad8]
mov dword [esi + 8], ebx
mov eax, dword [ecx + 4]
test eax, eax
jne 0x4388f4
mov dword [ecx], esi
jmp 0x4388f6
mov dword [eax], esi
xor eax, eax
mov dword [ecx + 4], esi
mov esi, eax
jmp 0x438937
cmp dword [0x442534], 0xffffffff
jne 0x438913
push ecx
push 2
pop eax
mov edx, eax
call fcn.0041e30f
push 2
pop eax
mov edx, 0x4099b0
mov ecx, eax
call fcn.0041e767
mov esi, 0x80004003
jmp 0x43892f
mov ebx, dword [ebp - 0xab0]
test esi, esi
js 0x4387b8
mov ebx, dword [ebp - 0xab0]
lea edx, [ebp - 0x49c]
push 4
mov ecx, 0x40a27c
jmp 0x4387c7
test bl, 2
je 0x438965
mov eax, 0x80070003
mov ebx, eax
mov esi, eax
mov dword [ebp - 0xac0], ebx
jmp 0x43896b
mov ebx, dword [ebp - 0xac0]
push ebx
push dword [ebp - 0xac4]
push 0x40a2e8
push 2
pop eax
push eax
call fcn.0041e83a
add esp, 0x10
jmp 0x4387ed