Function at 0x4016b0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x250
mov eax, dword [ebp + 8]
mov dword [ebp - 0x240], eax
mov dword [ebp - 0x23c], eax
lea ecx, [ebp - 1]
call fcn.004019d0
mov ecx, eax
call fcn.00401a80
mov dword [esp], eax
call fcn.00401450
lea ecx, [ebp - 2]
call fcn.00401aa0
mov ecx, eax
call fcn.00401b50
mov dword [esp], eax
call fcn.00401450
mov eax, dword [0x48f04c]
mov dword [ebp - 6], eax
lea ecx, [ebp - 7]
call fcn.00401b70
mov ecx, eax
call fcn.00401c20
mov dword [esp], eax
call sub.msvcrt.dll_getenv
cmp eax, 0
je 0x401762
lea eax, [ebp - 6]
mov dword [esp], eax
call fcn.00401c40
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x40175f
lea ecx, [ebp - 0xd]
call fcn.00401ca0
mov ecx, eax
call fcn.00401b50
mov dword [esp], eax
call fcn.00401c50
xor eax, eax
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_GlobalFlags]
sub esp, 4
call dword [ebp - 0xc]
lea ecx, [ebp - 0xe]
call fcn.00401d50
mov ecx, eax
call fcn.00401e00
mov dword [esp], eax
call fcn.00401450
cmp dword [0x4a1510], 0
jne 0x4017a6
lea ecx, [0x48f050]
lea eax, str.Cant_call_WinAPI_function.
mov dword [esp], ecx
mov dword [esp + 4], eax
mov dword [esp + 8], 0x10
call fcn.00401e20
lea ecx, [ebp - 0x217]
call fcn.00401e80
mov ecx, eax
call fcn.00401a80
mov dword [esp], eax
call fcn.00401450
lea ecx, [ebp - 0x218]
call fcn.00401f30
mov ecx, eax
call fcn.00401b50
mov dword [esp], eax
call fcn.00401450
mov eax, dword [0x48f072]
mov dword [ebp - 0x21c], eax
lea ecx, [ebp - 0x21d]
call fcn.00401fe0
mov ecx, eax
call fcn.00401c20
mov dword [esp], eax
call sub.msvcrt.dll_getenv
cmp eax, 0
je 0x40185b
lea eax, [ebp - 0x21c]
mov dword [esp], eax
call fcn.00401c40
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0
jne 0x401855
lea ecx, [ebp - 0x225]
call fcn.00402090
mov ecx, eax
call fcn.00401b50
mov dword [esp], eax
call fcn.00401c50
xor eax, eax
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_GlobalFlags]
sub esp, 4
call dword [ebp - 0x224]
lea ecx, [ebp - 0x226]
call fcn.00402140
mov ecx, eax
call fcn.00401e00
mov dword [esp], eax
call fcn.00401450
mov eax, dword [0x4a1510]
lea ecx, [ebp - 0x216]
mov dword [esp], ecx
mov dword [esp + 4], 0x104
call eax
sub esp, 8
mov dword [ebp - 0x244], eax
lea eax, [0x48f076]
mov dword [esp], eax
call sub.msvcrt.dll_atoi
mov ecx, eax
mov eax, dword [ebp - 0x244]
cmp eax, ecx
jbe 0x4018d0
mov ecx, dword [ebp - 0x240]
lea eax, [ebp - 0x216]
mov dword [esp], eax
call fcn.004021f0
sub esp, 4
jmp 0x4019b6
lea ecx, [ebp - 0x227]
call fcn.00402250
mov ecx, eax
call fcn.00401a80
mov dword [esp], eax
call fcn.00401450
lea ecx, [ebp - 0x228]
call fcn.00402300
mov ecx, eax
call fcn.00401b50
mov dword [esp], eax
call fcn.00401450
mov eax, dword [0x48f078]
mov dword [ebp - 0x22c], eax
lea ecx, [ebp - 0x22d]
call fcn.004023b0
mov ecx, eax
call fcn.00401c20
mov dword [esp], eax
call sub.msvcrt.dll_getenv
cmp eax, 0
je 0x401985
lea eax, [ebp - 0x22c]
mov dword [esp], eax
call fcn.00401c40
mov dword [ebp - 0x234], eax
cmp dword [ebp - 0x234], 0
jne 0x40197f
lea ecx, [ebp - 0x235]
call fcn.00402460
mov ecx, eax
call fcn.00401b50
mov dword [esp], eax
call fcn.00401c50
xor eax, eax
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_GlobalFlags]
sub esp, 4
call dword [ebp - 0x234]
lea ecx, [ebp - 0x236]
call fcn.00402510
mov ecx, eax
call fcn.00401e00
mov dword [esp], eax
call fcn.00401450
mov ecx, dword [ebp - 0x240]
lea eax, [0x48f07c]
mov dword [esp], eax
call fcn.004021f0
sub esp, 4
mov eax, dword [ebp - 0x23c]
add esp, 0x250
pop ebp
ret