Function at 0x485960
Capabilities:
Query environment variable

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x430
mov esi, ecx
lea ecx, [esp + 0x30]
push dword [esp + 0x444]
call fcn.00485be0
add esp, 4
mov ecx, dword [esp + 0x30]
mov eax, ecx
neg eax
jno 0x4859e1
cmp byte [esp + 0x34], 3
jne 0x4859d6
mov ebp, esi
mov esi, dword [esp + 0x38]
mov ebx, dword [esi + 4]
mov edi, dword [esi]
mov eax, dword [ebx]
test eax, eax
je 0x4859a7
push edi
call eax
add esp, 4
cmp dword [ebx + 4], 0
je 0x4859c5
cmp dword [ebx + 8], 9
jb 0x4859b6
mov edi, dword [edi - 4]
push edi
push 0
push dword [0xfd5200]
call dword [sym.imp.KERNEL32.dll_HeapFree]
push esi
push 0
push dword [0xfd5200]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov esi, ebp
mov dword [esi], 0x80000000
jmp 0x485bb1
mov eax, dword [esp + 0x34]
mov dword [esp], esi
mov ebx, 0x200
xor esi, esi
mov dword [esp + 8], 0
mov dword [esp + 0xc], 2
mov dword [esp + 4], ecx
mov dword [esp + 0x10], 0
mov dword [esp + 0x14], 2
mov dword [esp + 0x1c], eax
cmp ebx, 0x201
jae 0x485a50
jmp 0x485a3e
jbe 0x485ad9
cmp ebx, 0x201
jae 0x485a50
mov dword [esp + 0x18], 0x200
lea edi, [esp + 0x30]
mov ebp, ebx
jmp 0x485a62
sub ebx, esi
jne 0x485ab5
mov edi, dword [esp + 0x14]
mov ebp, esi
mov dword [esp + 0x10], esi
mov dword [esp + 0x18], esi
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebp
push edi
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov ebx, eax
test eax, eax
jne 0x485a8a
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x485b6f
cmp ebx, ebp
jne 0x485a30
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x485bda
lea ebx, [ebp + ebp]
test ebp, ebp
mov eax, 0xffffffff
cmovs ebx, eax
cmp ebx, 0x201
jb 0x485a3e
jmp 0x485a50
lea ecx, [esp + 8]
mov edx, esi
push 2
push 2
push ebx
call fcn.004ea1e0
add esp, 0xc
mov eax, dword [esp + 0xc]
mov esi, dword [esp + 8]
mov dword [esp + 0x14], eax
jmp 0x485a54
cmp ebx, dword [esp + 0x18]
ja 0x485bda
lea ecx, [esp + 0x20]
mov edx, edi
push ebx
call fcn.00484c00
add esp, 4
cmp dword [esp + 8], 0
je 0x485b0b
push dword [esp + 0xc]
push 0
push dword [0xfd5200]
call dword [sym.imp.KERNEL32.dll_HeapFree]
xor eax, eax
mov ecx, dword [esp + 4]
cmp eax, dword [esp + 0x20]
jno 0x485bbc
mov eax, dword [esp]
mov esi, dword [esp + 0x28]
cmp byte [esp + 0x24], 3
mov dword [eax], 0x80000000
jne 0x485b9b
mov ebx, dword [esi + 4]
mov edi, dword [esi]
mov eax, dword [ebx]
test eax, eax
je 0x485b40
push edi
call eax
add esp, 4
cmp dword [ebx + 4], 0
je 0x485b5e
cmp dword [ebx + 8], 9
jb 0x485b4f
mov edi, dword [edi - 4]
push edi
push 0
push dword [0xfd5200]
call dword [sym.imp.KERNEL32.dll_HeapFree]
push esi
push 0
push dword [0xfd5200]
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x485b97
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp dword [esp + 8], 0
je 0x485b8e
push dword [esp + 0xc]
push 0
push dword [0xfd5200]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [esp]
mov dword [eax], 0x80000000
mov ecx, dword [esp + 4]
test ecx, ecx
je 0x485bb1
push dword [esp + 0x1c]
push 0
push dword [0xfd5200]
call dword [sym.imp.KERNEL32.dll_HeapFree]
add esp, 0x430
pop esi
pop edi
pop ebx
pop ebp
ret
movsd xmm0, qword [esp + 0x20]
mov eax, dword [esp]
movsd xmm1, qword [esp + 0x28]
movsd qword [eax + 8], xmm1
movsd qword [eax], xmm0
test ecx, ecx
jne 0x485b9f
jmp 0x485bb1
ud2