Function at 0x10024ba
Capabilities:
Query environment variable
Set environment variable

Disassembly:
push ebp
lea ebp, [esp - 0x198]
sub esp, 0x218
mov eax, dword [0x1005020]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenW]
push esi
push edi
push 0x1005048
mov dword [ebp + 0x194], eax
call ebx
push 0x1001310
mov esi, eax
mov edi, 0x104
push edi
lea eax, [ebp - 0x74]
push eax
call fcn.01001a40
test eax, eax
jl 0x1002505
lea eax, [ebp - 0x74]
push eax
call ebx
jmp 0x1002507
xor eax, eax
cmp esi, eax
mov ebx, dword [sym.imp.SHLWAPI.dll_StrCmpIW]
jl 0x10025ff
lea ecx, [ebp - 0x74]
push ecx
mov ecx, esi
sub ecx, eax
lea eax, [ecx*2 + 0x1005048]
push eax
call ebx
test eax, eax
jne 0x10025ff
mov esi, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
push eax
lea eax, [ebp - 0x74]
push eax
mov ebx, 0x1001304
push ebx
call esi
test eax, eax
je 0x10027c5
add eax, 0x105
mov dword [ebp - 0x7c], eax
add eax, eax
push eax
call sub.msvcrt.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
push dword [ebp - 0x7c]
mov dword [ebp - 0x78], eax
push eax
push ebx
call esi
test eax, eax
mov dword [ebp - 0x7c], eax
jbe 0x10027bc
mov ecx, dword [ebp - 0x78]
lea eax, [ecx + eax*2]
cmp word [eax - 2], 0x3b
je 0x1002594
push 0x1001300
push 0x105
push eax
call fcn.01001a40
test eax, eax
jl 0x1002594
inc dword [ebp - 0x7c]
and word [ebp - 0x74], 0
push edi
lea eax, [ebp - 0x74]
push eax
push 0x10012d8
call esi
test eax, eax
mov dword [ebp - 0x80], eax
je 0x10027bc
cmp word [ebp - 0x74], 0
je 0x10027bc
lea edx, [ebp + eax*2 - 0x74]
cmp word [edx - 2], 0x5c
mov esi, 0x7fffffff
je 0x10025e9
mov ecx, edi
sub ecx, eax
cmp ecx, esi
ja 0x10025e9
push 0x1001240
push ecx
push edx
call fcn.01001a40
test eax, eax
jl 0x10025e6
inc dword [ebp - 0x80]
mov eax, dword [ebp - 0x80]
mov ecx, edi
sub ecx, eax
cmp ecx, esi
ja 0x10027bc
push 0x10012c8
jmp 0x100277a
push 0x10012b4
push edi
lea eax, [ebp - 0x74]
push eax
call fcn.01001a40
test eax, eax
jl 0x100261e
lea eax, [ebp - 0x74]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
jmp 0x1002620
xor eax, eax
cmp esi, eax
jl 0x100263a
lea ecx, [ebp - 0x74]
push ecx
mov ecx, esi
sub ecx, eax
lea eax, [ecx*2 + 0x1005048]
push eax
call ebx
test eax, eax
je 0x10026b6
push 0x100129c
push edi
lea eax, [ebp - 0x74]
push eax
call fcn.01001a40
test eax, eax
jl 0x1002659
lea eax, [ebp - 0x74]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
jmp 0x100265b
xor eax, eax
cmp esi, eax
jl 0x1002675
lea ecx, [ebp - 0x74]
push ecx
mov ecx, esi
sub ecx, eax
lea eax, [ecx*2 + 0x1005048]
push eax
call ebx
test eax, eax
je 0x10026b6
push 0x1001288
push edi
lea eax, [ebp - 0x74]
push eax
call fcn.01001a40
test eax, eax
jl 0x1002694
lea eax, [ebp - 0x74]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
jmp 0x1002696
xor eax, eax
cmp esi, eax
jl 0x10027c5
lea ecx, [ebp - 0x74]
sub esi, eax
push ecx
lea eax, [esi*2 + 0x1005048]
push eax
call ebx
test eax, eax
jne 0x10027c5
mov esi, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
push 0
lea eax, [ebp - 0x74]
push eax
mov ebx, 0x1001304
push ebx
call esi
test eax, eax
je 0x10027c5
add eax, 0x105
mov dword [ebp - 0x7c], eax
add eax, eax
push eax
call sub.msvcrt.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
push dword [ebp - 0x7c]
mov dword [ebp - 0x78], eax
push eax
push ebx
call esi
test eax, eax
mov dword [ebp - 0x7c], eax
jbe 0x10027bc
mov ecx, dword [ebp - 0x78]
lea eax, [ecx + eax*2]
cmp word [eax - 2], 0x3b
je 0x100271c
push 0x1001300
push 0x105
push eax
call fcn.01001a40
test eax, eax
jl 0x100271c
inc dword [ebp - 0x7c]
and word [ebp - 0x74], 0
push edi
lea eax, [ebp - 0x74]
push eax
push 0x10012d8
call esi
test eax, eax
mov dword [ebp - 0x80], eax
je 0x10027bc
cmp word [ebp - 0x74], 0
je 0x10027bc
lea edx, [ebp + eax*2 - 0x74]
cmp word [edx - 2], 0x5c
mov esi, 0x7fffffff
je 0x100276d
mov ecx, edi
sub ecx, eax
cmp ecx, esi
ja 0x100276d
push 0x1001240
push ecx
push edx
call fcn.01001a40
test eax, eax
jl 0x100276a
inc dword [ebp - 0x80]
mov eax, dword [ebp - 0x80]
mov ecx, edi
sub ecx, eax
cmp ecx, esi
ja 0x10027bc
push 0x1001264
lea eax, [ebp + eax*2 - 0x74]
push ecx
push eax
call fcn.01001a40
test eax, eax
jl 0x10027bc
lea eax, [ebp - 0x74]
push eax
push dword [ebp - 0x78]
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
jne 0x10027bc
mov ecx, dword [ebp - 0x7c]
lea eax, [ebp - 0x74]
push eax
mov eax, dword [ebp - 0x78]
lea eax, [eax + ecx*2]
push edi
push eax
call fcn.01001a40
test eax, eax
jl 0x10027bc
push dword [ebp - 0x78]
push ebx
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push dword [ebp - 0x78]
call sub.msvcrt.dll_void___cdecl_operator_delete_void__
pop ecx
mov ecx, dword [ebp + 0x194]
pop edi
pop esi
pop ebx
call fcn.01004128
add ebp, 0x198
leave
ret