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

Disassembly:
push ebp
lea ebp, [esp - 0x1d54]
mov eax, 0x1d54
call fcn.00409e10
push 0xffffffffffffffff
push 0x40b36c
mov eax, dword fs:[0]
push eax
push ecx
push ecx
mov eax, dword [0x411100]
xor eax, ebp
mov dword [ebp + 0x1d50], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x10], edi
xor ebx, ebx
push 0xfff
lea eax, [ebp + 0x941]
push ebx
push eax
mov dword [ebp - 4], ebx
mov byte [ebp + 0x940], bl
call sub.MSVCR100.dll_memset
push 0x7ff
lea eax, [ebp + 0x141]
push ebx
push eax
mov byte [ebp + 0x140], bl
call sub.MSVCR100.dll_memset
add esp, 0x18
mov esi, 0x800
push esi
lea eax, [ebp + 0x140]
push eax
push 0x40cd18
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
cmp eax, ebx
je 0x40662a
cmp eax, esi
jae 0x40662a
lea eax, [ebp + 0x140]
push eax
lea eax, [ebp + 0x940]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
jmp 0x40663f
push 0x1000
lea eax, [ebp + 0x940]
push eax
push edi
call fcn.00405d76
add esp, 0xc
lea eax, [ebp + 0x940]
push str._Djava.ext.dirs
push eax
call dword [sym.imp.MSVCR100.dll__mbsstr]
pop ecx
pop ecx
test eax, eax
jne 0x40678c
mov esi, 0x103
push esi
lea eax, [ebp + 0x1941]
push ebx
push eax
mov byte [ebp + 0x1940], bl
call sub.MSVCR100.dll_memset
push esi
lea eax, [ebp + 0x1b49]
push ebx
push eax
mov byte [ebp + 0x1b48], bl
call sub.MSVCR100.dll_memset
add esp, 0x18
lea edi, [esi + 1]
push edi
lea eax, [ebp + 0x1940]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea eax, [ebp + 0x1940]
push eax
push str._sSunJavaDeploymentLibTrusted
lea eax, [ebp + 0x1b48]
push edi
push eax
call fcn.00404e61
add esp, 0x10
lea eax, [ebp]
push eax
lea eax, [ebp + 0x1b48]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
push esi
mov dword [ebp - 0x14], eax
lea eax, [ebp + 0x1a45]
push ebx
push eax
mov byte [ebp + 0x1a44], bl
call sub.MSVCR100.dll_memset
push esi
lea eax, [ebp + 0x1c4d]
push ebx
push eax
mov byte [ebp + 0x1c4c], bl
call sub.MSVCR100.dll_memset
add esp, 0x18
push edi
lea eax, [ebp + 0x1a44]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp + 0x1a44]
push 0x5c
push eax
call dword [sym.imp.MSVCR100.dll_strrchr]
pop ecx
pop ecx
cmp eax, ebx
je 0x40671d
mov byte [eax], bl
lea eax, [ebp + 0x1a44]
push eax
push str._sjss
lea eax, [ebp + 0x1c4c]
push edi
push eax
call fcn.00404e61
add esp, 0x10
lea eax, [ebp]
push eax
lea eax, [ebp + 0x1c4c]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp dword [ebp - 0x14], 0xffffffff
mov ebx, eax
jne 0x4067ba
cmp ebx, 0xffffffff
je 0x40678c
lea eax, [ebp + 0x1c4c]
push eax
push dword [ebp - 0x10]
mov esi, 0x411d08
push str._Djava.ext.dirs__slibext__s_
push 0x30c
push esi
call fcn.00404e61
add esp, 0x14
push ebx
call dword [sym.imp.KERNEL32.dll_FindClose]
push esi
lea ecx, [ebp + 0x1d5c]
call fcn.00406bca
lea ecx, [ebp + 0x1d5c]
call fcn.00403ed6
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x1d50]
xor ecx, ebp
call fcn.00409df2
add ebp, 0x1d54
leave
ret
mov esi, 0x411d08
cmp ebx, 0xffffffff
je 0x4067f8
lea eax, [ebp + 0x1c4c]
push eax
lea eax, [ebp + 0x1b48]
push eax
push dword [ebp - 0x10]
push str._Djava.ext.dirs__slibext__s__s_
push 0x30c
push esi
call fcn.00404e61
mov edi, dword [sym.imp.KERNEL32.dll_FindClose]
add esp, 0x18
push dword [ebp - 0x14]
call edi
push ebx
call edi
jmp 0x406780
lea eax, [ebp + 0x1b48]
push eax
push dword [ebp - 0x10]
push 0x40cd8c
push 0x30c
push esi
call fcn.00404e61
add esp, 0x14
push dword [ebp - 0x14]
jmp 0x40677a