Function at 0x100204f0
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xa5c
mov eax, dword [0x100a20a4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push 0x104
lea eax, [ebp - 0x348]
mov ebx, ecx
push eax
push 0xffffffffffffffff
xor esi, esi
push ebx
push esi
push esi
mov dword [ebp - 0x9b8], esi
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
lea eax, [ebp - 0x348]
push 0x5c
push eax
call dword [sym.imp.msvcrt.dll_wcsrchr]
mov edi, eax
add esp, 8
test edi, edi
jne 0x10020549
lea edi, [ebp - 0x348]
jmp 0x1002054c
add edi, 2
push edi
mov dword [ebp - 0x9b0], edi
call dword [sym.imp.msvcrt.dll__wcslwr]
add esp, 4
lea ecx, [ebp - 0x9fc]
call fcn.1001fb50
test eax, eax
je 0x10020a6c
push 0
push 0x80
push 3
push 0
push 3
push 0x80000000
push ebx
mov dword [ebp - 0x9ac], esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x9bc], eax
cmp eax, 0xffffffff
jne 0x100206b3
test ebx, ebx
je 0x10020a6c
mov esi, 0x104
mov eax, ebx
lea esp, [esp]
cmp byte [eax], 0
je 0x100205bb
inc eax
sub esi, 1
jne 0x100205b0
test esi, esi
je 0x10020a6a
push 0x104
lea eax, [ebp - 0x140]
push 0
push eax
call sub.msvcrt.dll_memset
lea eax, [esi - 0x104]
add esp, 0xc
neg esi
sbb esi, esi
and esi, eax
lea eax, [ebp - 0x140]
add esi, 0x102
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x10020a6a
mov ecx, 0x104
lea eax, [ebp - 0x140]
lea esp, [esp]
cmp byte [eax], 0
je 0x1002061b
inc eax
sub ecx, 1
jne 0x10020610
mov edi, 0x104
mov esi, ecx
mov eax, edi
sub eax, ecx
neg esi
sbb esi, esi
and esi, eax
test ecx, ecx
je 0x10020648
push ecx
push 0x1000510c
push ecx
mov edx, edi
lea ecx, [ebp - 0x140]
sub edx, esi
add ecx, esi
call fcn.1001fb00
mov ecx, edi
lea eax, [ebp - 0x140]
cmp byte [eax], 0
je 0x1002065b
inc eax
sub ecx, 1
jne 0x10020650
mov eax, edi
mov esi, ecx
sub eax, ecx
neg esi
sbb esi, esi
and esi, eax
test ecx, ecx
je 0x1002067f
push ecx
push ebx
push ecx
sub edi, esi
lea ecx, [ebp - 0x140]
add ecx, esi
mov edx, edi
call fcn.1001fb00
push 0
push 0x80
push 3
push 0
push 3
push 0x80000000
lea eax, [ebp - 0x140]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x9bc], eax
cmp eax, 0xffffffff
je 0x10020a6a
mov edi, dword [ebp - 0x9b0]
mov esi, dword [ebp - 0x9dc]
lea ecx, [ebp - 0x9ac]
push 0
push 0
push ecx
push eax
mov ecx, esi
call dword [0x100a8504]
call esi
test eax, eax
je 0x10020a56
push dword [ebp - 0x9ac]
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x9b4], eax
test eax, eax
je 0x10020a56
mov esi, dword [ebp - 0x9dc]
xor ebx, ebx
push ebx
push eax
lea eax, [ebp - 0x9ac]
mov dword [ebp - 0x9b0], 0
push eax
push dword [ebp - 0x9bc]
mov ecx, esi
mov dword [ebp - 0x358], 0xf750e6c3
mov dword [ebp - 0x354], 0x11d138ee
mov dword [ebp - 0x350], 0xc000e585
mov dword [ebp - 0x34c], 0xee95c24f
call dword [0x100a8504]
call esi
test eax, eax
je 0x10020776
mov esi, dword [ebp - 0x9e0]
lea eax, [ebp - 0x9b0]
push eax
push ebx
push dword [ebp - 0x9ac]
mov ecx, esi
push dword [ebp - 0x9b4]
push dword [ebp - 0x9f0]
call dword [0x100a8504]
call esi
mov ebx, eax
lea eax, [ebp - 0x9a8]
mov dword [ebp - 0xa50], 0
push 0x43c
mov dword [ebp - 0xa54], eax
lea eax, [ebp - 0x9a4]
push 0
push eax
mov dword [ebp - 0xa38], 0
mov dword [ebp - 0xa34], 0
mov dword [ebp - 0xa30], 0
mov dword [ebp - 0xa2c], 0
mov dword [ebp - 0xa28], 0
mov dword [ebp - 0xa58], 0x34
mov dword [ebp - 0xa4c], 2
mov dword [ebp - 0xa48], 0
mov dword [ebp - 0xa44], 2
mov dword [ebp - 0xa3c], 3
call sub.msvcrt.dll_memset
lea eax, [ebp - 0xa24]
mov dword [ebp - 0x9a8], 0x440
mov dword [ebp - 0xa40], eax
add esp, 0xc
mov eax, dword [ebp - 0x9b4]
mov dword [ebp - 0xa0c], eax
mov eax, dword [ebp - 0x9ac]
mov dword [ebp - 0xa20], 0
mov dword [ebp - 0xa1c], 0
mov dword [ebp - 0xa14], 0
mov dword [ebp - 0xa10], 0
mov dword [ebp - 0xa04], 0
mov dword [ebp - 0xa00], 0
mov dword [ebp - 0xa24], 0x28
mov dword [ebp - 0xa08], eax
mov dword [ebp - 0xa18], edi
test ebx, ebx
je 0x10020a4a
jmp 0x10020890
push 0x208
lea eax, [ebp - 0x564]
push 0
push eax
call sub.msvcrt.dll_memset
mov esi, dword [ebp - 0x9cc]
lea eax, [ebp - 0x568]
add esp, 0xc
mov dword [ebp - 0x568], 0x20c
mov ecx, esi
push 0
push eax
push ebx
call dword [0x100a8504]
call esi
test eax, eax
je 0x100208fe
mov esi, dword [ebp - 0x9c4]
lea eax, [ebp - 0x564]
mov dword [ebp - 0xa1c], eax
mov ecx, esi
lea eax, [ebp - 0xa58]
push eax
lea eax, [ebp - 0x358]
push eax
push 0
call dword [0x100a8504]
call esi
test eax, eax
je 0x1002093e
mov esi, dword [ebp - 0x9e0]
lea eax, [ebp - 0x9b0]
push eax
push 0
push dword [ebp - 0x9ac]
mov ecx, esi
mov dword [ebp - 0x9b0], ebx
push dword [ebp - 0x9b4]
push dword [ebp - 0x9f0]
call dword [0x100a8504]
call esi
mov ebx, eax
test ebx, ebx
jne 0x10020890
jmp 0x10020a4a
mov esi, dword [ebp - 0x9e4]
lea eax, [ebp - 0x564]
push 0
push 0
push 0
push 4
push eax
mov ecx, esi
mov dword [ebp - 0x9b8], 1
call dword [0x100a8504]
call esi
mov esi, dword [ebp - 0x9e8]
mov ecx, esi
push 0x10005130
push eax
mov dword [ebp - 0x9c0], eax
call dword [0x100a8504]
call esi
test eax, eax
je 0x10020a17
push 0
push 0
push 0x32
lea ecx, [ebp - 0x38]
push ecx
push 0xffffffffffffffff
push dword [eax + 0x10]
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
cmp byte [ebp - 0x38], 0
lea edi, [ebp - 0x38]
je 0x100209dc
mov esi, 0x10005148
mov eax, edi
sub esi, eax
mov eax, edi
mov cl, 0x3a
lea ebx, [ebx]
mov edx, eax
cmp byte [eax], cl
jne 0x100209d1
mov cl, byte [edx + esi + 1]
inc eax
test cl, cl
jne 0x100209c0
jmp 0x100209de
test cl, cl
je 0x100209de
inc edi
dec esi
cmp byte [edi], 0
jne 0x100209b6
xor edi, edi
inc edi
push edi
mov byte [edi + 4], 0
call dword [sym.imp.msvcrt.dll_atoi]
mov esi, eax
mov byte [edi + 7], 0
lea eax, [edi + 5]
shl esi, 0x10
push eax
call dword [sym.imp.msvcrt.dll_atoi]
shl eax, 8
or esi, eax
lea eax, [edi + 8]
push eax
call dword [sym.imp.msvcrt.dll_atoi]
add esp, 0xc
or esi, eax
mov dword [ebp - 0x9b8], esi
push dword [ebp - 0x9c0]
mov esi, dword [ebp - 0x9ec]
mov ecx, esi
call dword [0x100a8504]
call esi
test ebx, ebx
je 0x10020a4a
mov esi, dword [ebp - 0x9d0]
mov ecx, esi
push 0
push ebx
push dword [ebp - 0x9f0]
call dword [0x100a8504]
call esi
push dword [ebp - 0x9b4]
call dword [sym.imp.KERNEL32.dll_LocalFree]
push dword [ebp - 0x9bc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [ebp - 0x9b8]
jmp 0x10020a6c
xor esi, esi
cmp dword [ebp - 0x9fc], 0
je 0x10020abc
mov esi, dword [ebp - 0x9d4]
mov ecx, esi
push 0
push dword [ebp - 0x9f0]
call dword [0x100a8504]
call esi
push dword [ebp - 0x9f8]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
push dword [ebp - 0x9f4]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp - 0x9b8]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1009b610
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1009b610
mov esp, ebp
pop ebp
ret