Function at 0x406627
Capabilities:
Get common file path
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40dbdf
mov eax, dword fs:[0]
push eax
mov eax, 0x1d58
call fcn.0040bfc0
mov eax, dword [0x41a1d4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
xor ebx, ebx
lea eax, [ebp - 0x1c20]
push 0x1000
push ebx
push eax
mov dword [ebp - 4], ebx
call sub.VCRUNTIME140.dll_memset
mov edi, 0x800
lea eax, [ebp - 0xc20]
push edi
push ebx
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0x18
lea eax, [ebp - 0xc20]
push edi
push eax
push 0x40f418
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
test eax, eax
je 0x4066ba
cmp eax, edi
jae 0x4066ba
lea eax, [ebp - 0xc20]
push eax
lea eax, [ebp - 0x1c20]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
jmp 0x4066cf
push 0x1000
lea eax, [ebp - 0x1c20]
push eax
push esi
call fcn.004060f0
add esp, 0xc
lea eax, [ebp - 0x1c20]
push str._Djava.ext.dirs
push eax
call dword [sym.imp.api_ms_win_crt_multibyte_l1_1_0.dll__mbsstr]
pop ecx
pop ecx
test eax, eax
jne 0x40687c
mov edi, 0x104
lea eax, [ebp - 0x420]
push edi
push ebx
push eax
call sub.VCRUNTIME140.dll_memset
push edi
lea eax, [ebp - 0x218]
push ebx
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0x18
lea eax, [ebp - 0x420]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea eax, [ebp - 0x420]
push eax
push str._sSunJavaDeploymentLibTrusted
lea eax, [ebp - 0x218]
push edi
push eax
call fcn.0040651e
mov ebx, dword [sym.imp.KERNEL32.dll_FindFirstFileA]
lea eax, [ebp - 0x1d60]
add esp, 0x10
push eax
lea eax, [ebp - 0x218]
push eax
call ebx
mov edi, eax
lea eax, [ebp - 0x31c]
push 0x104
push 0
push eax
mov dword [ebp - 0x1d64], edi
call sub.VCRUNTIME140.dll_memset
push 0x104
lea eax, [ebp - 0x114]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0x18
lea eax, [ebp - 0x31c]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x31c]
push 0x5c
push eax
call sub.VCRUNTIME140.dll_strrchr
pop ecx
pop ecx
test eax, eax
je 0x4067ab
mov byte [eax], 0
lea eax, [ebp - 0x31c]
push eax
push str._sjss
lea eax, [ebp - 0x114]
push 0x104
push eax
call fcn.0040651e
add esp, 0x10
lea eax, [ebp - 0x1d60]
push eax
lea eax, [ebp - 0x114]
push eax
call ebx
mov ebx, eax
cmp edi, 0xffffffff
jne 0x40680d
cmp ebx, edi
je 0x40687c
lea eax, [ebp - 0x114]
mov edi, 0x41af28
push eax
push esi
push str._Djava.ext.dirs__slibext__s_
push 0x30c
push edi
call fcn.0040651e
add esp, 0x14
push ebx
jmp 0x40686d
mov edi, 0x41af28
cmp ebx, 0xffffffff
je 0x40684c
lea eax, [ebp - 0x114]
push eax
lea eax, [ebp - 0x218]
push eax
push esi
push str._Djava.ext.dirs__slibext__s__s_
push 0x30c
push edi
call fcn.0040651e
mov esi, dword [sym.imp.KERNEL32.dll_FindClose]
add esp, 0x18
push dword [ebp - 0x1d64]
call esi
push ebx
call esi
jmp 0x406873
lea eax, [ebp - 0x218]
push eax
push esi
push 0x40f48c
push 0x30c
push edi
call fcn.0040651e
add esp, 0x14
push dword [ebp - 0x1d64]
call dword [sym.imp.KERNEL32.dll_FindClose]
push edi
lea ecx, [ebp + 0xc]
call fcn.0040730c
lea ecx, [ebp + 0xc]
call fcn.00404136
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0040bfab
leave
ret