Function at 0x1007ad1
Capabilities:
Get common file path
Link many functions at runtime
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x10
and dword [ebp - 4], 0
push ebx
push esi
push edi
push 0x1016bc8
mov dword [0x1016bc8], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x1007b05
push 1
push 0x10013ac
jmp 0x1007d8c
mov esi, 0x104
push esi
mov edi, 0x10166ac
push edi
call fcn.0100c7a6
mov ebx, eax
test ebx, ebx
jne 0x1007b28
push 1
push 0x1001384
jmp 0x1007d8c
lea eax, [ebx + 0x10166ac]
push eax
push edi
call dword [sym.imp.USER32.dll_CharPrevA]
cmp byte [eax], 0x5c
je 0x1007b4a
mov byte [ebx + 0x10166ac], 0x5c
inc ebx
mov byte [ebx + 0x10166ac], 0
push esi
push edi
push 0x10169b8
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
mov eax, esi
sub eax, ebx
push eax
push 0x1005908
lea eax, [ebx + 0x10169b8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
push esi
mov ebx, 0x10168b4
push ebx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je 0x1007d85
push ebx
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecA]
test eax, eax
je 0x1007d85
push esi
mov ebx, 0x10165a8
push ebx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
mov dword [ebp - 8], eax
jne 0x1007bb4
push 1
push 0x100135c
jmp 0x1007d8c
lea eax, [eax + 0x10165a8]
push eax
push ebx
call dword [sym.imp.USER32.dll_CharPrevA]
cmp byte [eax], 0x5c
je 0x1007bdd
mov eax, dword [ebp - 8]
lea eax, [eax + 0x10165a8]
mov byte [eax], 0x5c
mov eax, dword [ebp - 8]
mov byte [eax + 0x10165a9], 0
push 0x1006b0c
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
test eax, eax
mov dword [0x1016c70], eax
jne 0x1007bfe
push eax
push 0x10
push 0x401
jmp 0x1007d9a
cmp dword [0x1016bd8], 1
jne 0x1007c21
push esi
push edi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
call edi
push esi
push ebx
push ebx
call edi
push esi
mov eax, 0x10169b8
push eax
push eax
call edi
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x100134c
push dword [0x1016c70]
call edi
push 0x1001338
push dword [0x1016c70]
mov dword [0x1016c74], eax
call edi
push 0x1001328
push dword [0x1016c70]
mov dword [0x1016c78], eax
call edi
xor ebx, ebx
cmp dword [0x1016c74], ebx
mov dword [0x1016c7c], eax
je 0x1007d69
cmp dword [0x1016c78], ebx
je 0x1007d69
cmp eax, ebx
je 0x1007d69
push 0x1001314
push dword [0x1016c70]
call edi
push 0x1001304
push dword [0x1016c70]
mov dword [0x1016c80], eax
call edi
push dword [ebp + 8]
mov dword [0x1016c84], eax
call fcn.010078e9
mov eax, dword [0x1016c6c]
dec eax
je 0x1007cd5
dec eax
jne 0x1007da8
mov dword [0x1016bc4], 0x1005710
mov eax, 0x403
mov dword [0x1016bc0], 0x1004fac
jmp 0x1007cee
mov dword [0x1016bc4], 0x1005704
mov eax, 0x3e8
mov dword [0x1016bc0], 0x1005240
push esi
push 0x10167b0
push eax
push dword [0x1016c8c]
call dword [sym.imp.USER32.dll_LoadStringA]
test eax, eax
jne 0x1007d0e
push 1
push 0x10012d8
jmp 0x1007d8c
cmp dword [0x1016c60], 1
jne 0x1007da8
lea eax, [ebp - 0xc]
push eax
push 1
push ebx
push dword [0x1016bc0]
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x1007da8
lea eax, [ebp - 0x10]
push eax
mov dword [ebp - 0x10], esi
mov esi, 0x1016c98
push esi
push ebx
push ebx
push 0x1005624
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x1007d5e
mov dword [0x1016bc4], esi
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x1007da8
push ebx
push 0x10
push 0x402
push ebx
call fcn.0100d141
push dword [0x1016c70]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x1007da1
push 1
push 0x10012b0
call fcn.0100d0a2
push 0
push 0x10
push 0x400
push 0
call fcn.0100d141
mov dword [ebp - 4], 0x80004005
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 4