Function at 0x4591a0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5217c1
mov eax, dword fs:[0]
push eax
sub esp, 0x74
mov eax, dword [0x579630]
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 ebx, dword [ebp + 8]
xorps xmm0, xmm0
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x64], 0
mov dword [ebp - 0x80], ebx
movq qword [ebx], xmm0
mov dword [ebx + 8], 0
mov dword [ebx], 0
mov dword [ebx + 4], 0
mov dword [ebx + 8], 0
mov dword [ebp - 4], 0
mov dword [ebp - 0x64], 1
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov dword [ebp - 0x60], eax
test eax, eax
je 0x459408
mov esi, eax
lea eax, [ebp - 0x58]
push eax
call fcn.00459430
lea eax, [ebp - 0x40]
mov dword [ebp - 4], 1
push eax
call fcn.00459510
add esp, 8
cmp dword [edi + 0x10], 0
mov byte [ebp - 4], 2
mov dword [ebp - 0x5c], 0
je 0x45926b
push 0xffffffffffffffff
push 0
push edi
lea ecx, [ebp - 0x40]
call fcn.0040af40
lea eax, [ebp - 0x40]
push eax
call fcn.00458d00
mov edi, eax
add esp, 4
mov dword [ebp - 0x5c], edi
jmp 0x459270
xor edi, edi
lea ecx, [ecx]
cmp word [esi], 0
je 0x4593b7
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
cmp word [esi], ax
jne 0x459297
xor ecx, ecx
jmp 0x4592af
mov ecx, esi
lea edx, [ecx + 2]
lea esp, [esp]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4592a0
sub ecx, edx
sar ecx, 1
push ecx
push esi
lea ecx, [ebp - 0x28]
call fcn.00407750
cmp dword [ebp - 0x48], 0
mov byte [ebp - 4], 3
je 0x45937d
push 4
push 0
push 0x52da78
lea ecx, [ebp - 0x28]
call fcn.0040cdd0
test eax, eax
jne 0x4592eb
test edi, edi
je 0x4592eb
lea eax, [ebp - 0x40]
push eax
push 0x52da78
jmp 0x45932d
push 5
push 0
push 0x52da84
lea ecx, [ebp - 0x28]
call fcn.0040cdd0
test eax, eax
jne 0x45930f
test edi, edi
je 0x45930f
lea eax, [ebp - 0x40]
push eax
push 0x52da84
jmp 0x45932d
push 0xd
push 0
push str.LOCALAPPDATA
lea ecx, [ebp - 0x28]
call fcn.0040cdd0
test eax, eax
jne 0x45937d
lea eax, [ebp - 0x58]
push eax
push str.LOCALAPPDATA
lea eax, [ebp - 0x7c]
push eax
call fcn.0040ec80
mov edi, eax
add esp, 0xc
lea eax, [ebp - 0x28]
cmp eax, edi
je 0x45936c
cmp dword [ebp - 0x14], 8
jb 0x459353
push dword [ebp - 0x28]
call fcn.004085be
add esp, 4
xor eax, eax
mov dword [ebp - 0x14], 7
push edi
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x18], eax
mov word [ebp - 0x28], ax
call fcn.00407e60
cmp dword [ebp - 0x68], 8
jb 0x45937d
push dword [ebp - 0x7c]
call fcn.004085be
add esp, 4
lea eax, [ebp - 0x28]
push eax
push ebx
call fcn.00458980
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov byte [ebp - 4], 2
lea esi, [esi + eax*2]
add esi, 2
cmp dword [ebp - 0x14], 8
jb 0x4593ac
push dword [ebp - 0x28]
call fcn.004085be
add esp, 4
mov edi, dword [ebp - 0x5c]
test esi, esi
jne 0x459270
lea eax, [ebp - 0x5c]
mov dword [ebp - 0x5c], 0
push eax
mov ecx, ebx
call fcn.004596a0
push dword [ebp - 0x60]
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
cmp dword [ebp - 0x2c], 8
jb 0x4593e3
push dword [ebp - 0x40]
call fcn.004085be
add esp, 4
xor eax, eax
mov dword [ebp - 0x2c], 7
cmp dword [ebp - 0x44], 8
mov dword [ebp - 0x30], 0
mov word [ebp - 0x40], ax
jb 0x459408
push dword [ebp - 0x58]
call fcn.004085be
add esp, 4
mov eax, ebx
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.00401590
mov esp, ebp
pop ebp
ret