Function at 0x10001753
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x9b4
mov eax, dword [0x10009de0]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
push 0x7f
mov dword [ebp - 0x9b0], eax
lea eax, [ebp - 0x83]
push ebx
push eax
mov byte [ebp - 0x9a5], bl
mov byte [ebp - 0x84], bl
call sub.msvcrt.dll_memset
add esp, 0xc
cmp esi, ebx
jne 0x1000179f
xor al, al
jmp 0x10001b16
cmp byte [esi], 0x2a
jne 0x10001798
push 0x7f
lea eax, [ebp - 0x84]
push esi
push eax
call dword [sym.imp.msvcrt.dll_strncpy]
mov esi, dword [sym.imp.msvcrt.dll_strchr]
lea eax, [ebp - 0x84]
push 0xd
push eax
call esi
add esp, 0x14
cmp eax, ebx
je 0x100017ce
mov byte [eax], bl
lea eax, [ebp - 0x84]
push 0xa
push eax
call esi
pop ecx
pop ecx
cmp eax, ebx
je 0x100017e1
mov byte [eax], bl
xor eax, eax
push 0xfe
mov word [ebp - 0x184], ax
lea eax, [ebp - 0x182]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
push 0x7f
lea eax, [ebp - 0x184]
push eax
push 0xffffffffffffffff
lea eax, [ebp - 0x84]
push eax
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
je 0x10001798
mov cx, word [0x1000904c]
mov edx, 0x1000904c
cmp cx, bx
jge 0x1000183f
mov eax, edx
neg word [eax]
add eax, 2
cmp word [eax], bx
jne 0x10001834
push edi
lea eax, [ebp - 0x9b4]
push eax
push ebx
push ebx
push ebx
push edx
lea eax, [ebp - 0x184]
push eax
call fcn.10007050
add esp, 0x18
test al, al
je 0x10001b01
push 1
mov byte [ebp - 0x9a5], 1
call fcn.1000154f
pop ecx
call fcn.1000173b
mov ax, word [0x1000905c]
mov edx, 0x1000905c
cmp ax, bx
jge 0x10001893
mov ecx, edx
neg word [ecx]
add ecx, 2
cmp word [ecx], bx
jne 0x10001888
mov cx, word [0x10009068]
mov edi, 0x10009068
cmp cx, bx
jge 0x100018b1
mov eax, edi
neg word [eax]
add eax, 2
cmp word [eax], bx
jne 0x100018a6
mov cx, word [0x10009070]
mov esi, 0x10009070
cmp cx, bx
jge 0x100018cf
mov eax, esi
neg word [eax]
add eax, 2
cmp word [eax], bx
jne 0x100018c4
mov cx, word [0x10009080]
cmp cx, bx
jge 0x100018eb
mov eax, 0x10009080
neg word [eax]
add eax, 2
cmp word [eax], bx
jne 0x100018e0
push ebx
push ebx
push ebx
push 0xffffffffffffffff
push edx
lea eax, [ebp - 0x184]
push eax
mov dword [ebp - 0x9ac], 1
call fcn.10007050
add esp, 0x18
test al, al
je 0x1000191a
mov dword [ebp - 0x9ac], 1
jmp 0x10001962
push ebx
push ebx
push ebx
push 0xffffffffffffffff
lea eax, [ebp - 0x184]
push edi
push eax
call fcn.10007050
add esp, 0x18
test al, al
je 0x1000193f
mov dword [ebp - 0x9ac], 2
jmp 0x10001962
push ebx
push ebx
push ebx
push 0xffffffffffffffff
lea eax, [ebp - 0x184]
push esi
push eax
call fcn.10007050
add esp, 0x18
test al, al
je 0x10001962
mov dword [ebp - 0x9ac], 3
xor eax, eax
mov esi, 0x206
push esi
mov word [ebp - 0x594], ax
lea eax, [ebp - 0x592]
push ebx
push eax
call sub.msvcrt.dll_memset
push ebx
mov edi, 0x103
push edi
lea eax, [ebp - 0x594]
push eax
push 0xffffffffffffffff
lea eax, [ebp - 0x184]
push 0x10009080
push eax
call fcn.10007050
xor eax, eax
push esi
mov word [ebp - 0x38c], ax
lea eax, [ebp - 0x38a]
push ebx
push eax
call sub.msvcrt.dll_memset
mov esi, dword [sym.imp.msvcrt.dll_wcsncpy]
add esp, 0x30
cmp dword [ebp - 0x9ac], 1
jne 0x100019f7
mov cx, word [section..data]
mov edx, section..data
cmp cx, bx
jge 0x100019e6
mov eax, edx
neg word [eax]
add eax, 2
cmp word [eax], bx
jne 0x100019db
push edi
lea eax, [ebp - 0x38c]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
jmp 0x10001a55
cmp dword [ebp - 0x9ac], 2
jne 0x10001a20
mov cx, word [0x10009014]
mov edx, 0x10009014
cmp cx, bx
jge 0x10001a47
mov eax, edx
neg word [eax]
add eax, 2
cmp word [eax], bx
jne 0x10001a13
jmp 0x10001a47
cmp dword [ebp - 0x9ac], 3
jne 0x10001a55
mov cx, word [0x10009034]
mov edx, 0x10009034
cmp cx, bx
jge 0x10001a47
mov eax, edx
neg word [eax]
add eax, 2
cmp word [eax], bx
jne 0x10001a3c
push edi
push edx
lea eax, [ebp - 0x38c]
push eax
call esi
add esp, 0xc
cmp word [ebp - 0x38c], bx
je 0x10001b01
xor eax, eax
push 0x40e
mov word [ebp - 0x9a4], ax
lea eax, [ebp - 0x9a2]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
mov edi, 0x207
cmp word [ebp - 0x594], bx
je 0x10001ab4
lea eax, [ebp - 0x594]
push eax
lea eax, [ebp - 0x38c]
push eax
push str._s__s
lea eax, [ebp - 0x9a4]
push edi
push eax
call dword [sym.imp.msvcrt.dll__snwprintf]
add esp, 0x14
jmp 0x10001ac8
push edi
lea eax, [ebp - 0x38c]
push eax
lea eax, [ebp - 0x9a4]
push eax
call esi
add esp, 0xc
lea eax, [ebp - 0x9a4]
push eax
call fcn.100015cd
pop ecx
test al, al
je 0x10001b01
mov eax, dword [ebp - 0x9ac]
mov dword [0x1000a100], eax
push edi
lea eax, [ebp - 0x9a4]
push eax
push 0x1000a104
call esi
add esp, 0xc
call fcn.10001338
test al, al
mov al, 1
jne 0x10001b03
mov al, bl
mov ecx, dword [ebp - 0x9b0]
pop edi
cmp ecx, ebx
je 0x10001b10
mov byte [ecx], al
mov al, byte [ebp - 0x9a5]
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.10007260
leave
ret