Function at 0x46a5c0
Capabilities:
Query environment variable

Disassembly:
push ebp
lea ebp, [esp - 0x3028]
mov eax, 0x3028
call fcn.004ebbf0
push 0xffffffffffffffff
push 0x5073f0
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
mov eax, dword [0x528af4]
xor eax, ebp
mov dword [ebp + 0x3024], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ecx, dword [ebp + 0x3034]
mov eax, dword [ebp + 0x3030]
mov dword [ebp - 0x24], ecx
xor ecx, ecx
mov word [ebp + 0x2024], cx
test eax, eax
je 0x46a64a
cmp byte [ebp + 0x3038], cl
je 0x46a638
push ecx
push 1
push 0x800
lea ecx, [ebp + 0x2024]
push ecx
push eax
call fcn.004781a0
jmp 0x46a64a
push 0x800
push eax
lea eax, [ebp + 0x2024]
push eax
call fcn.0048e710
lea ecx, [ebp]
call fcn.00467980
mov dword [ebp - 4], 0
cmp word [ebp + 0x2024], 0
je 0x46a6b0
mov bl, byte [ebp + 0x303c]
lea eax, [ebp + 0x2024]
lea ecx, [ebp]
test bl, bl
je 0x46a67e
push eax
call fcn.00468630
jmp 0x46a686
push 0
push eax
call fcn.00468010
test al, al
jne 0x46a6b7
test bl, bl
je 0x46a69a
push 6
mov ecx, 0x56df60
call fcn.00462d10
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp]
call fcn.004679c0
xor al, al
jmp 0x46abc0
mov dword [ebp + 0xc], 1
xor ebx, ebx
lea ecx, [ebp - 0x34]
push 0x1005
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x28], ebx
call fcn.00404010
mov byte [ebp - 4], 1
lea ecx, [ebp]
mov esi, dword [ebp - 0x34]
push 0x1000
push esi
mov dword [ebp - 0x18], esi
call fcn.00468270
mov edi, dword [ebp - 0x30]
test eax, eax
je 0x46a793
mov ebx, dword [ebp - 0x28]
mov esi, dword [ebp - 0x2c]
mov edi, edi
mov ecx, dword [ebp - 0x10]
add edi, eax
add ecx, eax
mov dword [ebp - 0x30], edi
mov dword [ebp - 0x10], ecx
cmp edi, esi
jbe 0x46a772
test ebx, ebx
je 0x46a736
cmp edi, ebx
jbe 0x46a736
push ebx
push str.Maximum_allowed_array_size___u__is_exceeded
push 0x56df60
call fcn.00462d50
add esp, 0xc
mov ecx, 0x56df60
call fcn.00462de0
mov eax, esi
add esi, 0x20
shr eax, 2
add esi, eax
cmp edi, esi
jbe 0x46a746
mov esi, edi
mov ecx, dword [ebp - 0x18]
push esi
push ecx
call fcn.004f2533
add esp, 8
mov dword [ebp - 0x18], eax
test eax, eax
jne 0x46a767
mov ecx, 0x56df60
call fcn.00462de0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x2c], esi
mov ecx, dword [ebp - 0x10]
jmp 0x46a775
mov eax, dword [ebp - 0x18]
add eax, ecx
lea ecx, [ebp]
push 0x1000
push eax
call fcn.00468270
test eax, eax
jne 0x46a700
mov ebx, dword [ebp - 0x10]
mov esi, dword [ebp - 0x18]
xor eax, eax
mov dword [esi + ebx], 0
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x40], eax
mov byte [esi + ebx + 4], 0
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x3c], eax
mov byte [ebp - 4], 2
mov ch, byte [esi]
cmp ch, 0xff
jne 0x46a7cb
cmp byte [esi + 1], 0xfe
jne 0x46a7cb
mov eax, 1
jmp 0x46a7cd
xor eax, eax
mov dword [ebp - 0x20], eax
cmp ch, 0xfe
jne 0x46a7e2
cmp byte [esi + 1], 0xff
jne 0x46a7e2
mov edx, 1
jmp 0x46a7e4
xor edx, edx
xor cl, cl
mov dword [ebp - 0x38], edx
mov byte [ebp - 0x11], cl
test eax, eax
jne 0x46a7f4
test edx, edx
je 0x46a81e
mov eax, 2
cmp ebx, eax
jbe 0x46a81e
lea ecx, [ecx]
mov cl, byte [esi + eax]
cmp cl, 0x20
jae 0x46a816
cmp cl, 0xd
je 0x46a816
cmp cl, 0xa
jne 0x46a944
inc eax
cmp eax, ebx
jb 0x46a800
mov cl, byte [ebp - 0x11]
mov ebx, dword [ebp + 0x3040]
cmp ebx, 3
je 0x46a9bd
test ebx, ebx
jne 0x46a839
test cl, cl
jne 0x46a9bd
test ch, ch
je 0x46ab8c
xor ecx, ecx
mov edi, esi
cmp byte [esi], 0xd
je 0x46a872
mov dl, byte [ebp + 0x3048]
mov al, byte [edi]
cmp al, 0xa
je 0x46a872
test al, al
je 0x46a872
test dl, dl
je 0x46a86c
cmp al, 0x2f
jne 0x46a86c
cmp byte [edi + 1], al
jne 0x46a86c
mov byte [edi], 0
mov ecx, edi
inc edi
cmp byte [edi], 0xd
jne 0x46a850
mov byte [edi], 0
test ecx, ecx
jne 0x46a87b
mov ecx, edi
lea eax, [ecx - 1]
cmp eax, esi
jb 0x46a896
mov cl, byte [eax]
cmp cl, 0x20
je 0x46a88e
cmp cl, 9
jne 0x46a896
mov byte [eax], 0
dec eax
cmp eax, esi
jae 0x46a882
mov al, byte [esi]
test al, al
je 0x46a99f
cmp byte [ebp + 0x3044], 0
je 0x46a8c7
cmp al, 0x22
jne 0x46a8c7
mov ecx, esi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x46a8b2
sub ecx, edx
cmp byte [ecx + esi - 1], 0x22
jne 0x46a8c7
mov byte [ecx + esi - 1], al
inc esi
cmp ebx, 2
jne 0x46a8d4
push esi
push esi
call dword [sym.imp.USER32.dll_OemToCharA]
mov ecx, esi
lea edx, [ecx + 1]
lea esp, [esp]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x46a8e0
sub ecx, edx
mov edx, dword [ebp - 0x1c]
inc ecx
cmp ecx, edx
jbe 0x46a94b
mov ebx, dword [ebp - 0x44]
sub ecx, ebx
add ebx, ecx
mov dword [ebp - 0x44], ebx
cmp ebx, edx
jbe 0x46a950
mov eax, edx
add edx, 0x20
shr eax, 2
add edx, eax
mov dword [ebp - 0x1c], edx
cmp ebx, edx
jbe 0x46a915
mov edx, ebx
mov dword [ebp - 0x1c], edx
lea eax, [edx + edx]
push eax
mov eax, dword [ebp - 0x10]
push eax
call fcn.004f2533
add esp, 8
mov dword [ebp - 0x10], eax
test eax, eax
jne 0x46a939
mov ecx, 0x56df60
call fcn.00462de0
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x48], eax
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x40], eax
jmp 0x46a950
mov cl, 1
jmp 0x46a81e
mov ebx, ecx
mov dword [ebp - 0x44], ebx
push ebx
mov ebx, dword [ebp - 0x10]
push ebx
push esi
call fcn.004914f0
cmp byte [ebp + 0x304c], 0
je 0x46a990
cmp byte [esi], 0x25
jne 0x46a990
push 0x800
lea eax, [ebp + 0x1024]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x46a990
cmp eax, 0x800
jae 0x46a990
lea eax, [ebp + 0x1024]
push eax
jmp 0x46a991
push ebx
mov ecx, dword [ebp - 0x24]
call fcn.0048e7f0
mov ebx, dword [ebp + 0x3040]
lea esi, [edi + 1]
mov al, byte [esi]
cmp al, 0xd
je 0x46a9ac
cmp al, 0xa
jne 0x46a9af
inc esi
jmp 0x46a9a2
cmp byte [esi], 0
jne 0x46a841
jmp 0x46ab8c
mov ebx, dword [ebp - 0x20]
mov dword [ebp - 0x1c], 2
test ebx, ebx
jne 0x46a9d7
test edx, edx
jne 0x46a9d7
xor eax, eax
lea ebx, [edx + 1]
mov dword [ebp - 0x1c], eax
mov eax, edi
mov dword [ebp - 0x58], 0
shr eax, 1
lea ecx, [ebp - 0x58]
inc eax
mov dword [ebp - 0x54], 0
push eax
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x4c], 0
call fcn.0040d720
mov byte [ebp - 4], 3
dec edi
mov eax, dword [ebp - 0x1c]
cmp eax, edi
jae 0x46aa5e
mov edx, dword [ebp - 0x18]
sub edi, eax
sub ebx, dword [ebp - 0x38]
add edx, eax
add edx, dword [ebp - 0x38]
dec edi
shr edi, 1
xor esi, esi
mov dword [ebp - 0x20], ebx
inc edi
mov eax, 0x100
jmp 0x46aa30
movzx ecx, byte [ebx + edx]
mov ebx, dword [ebp - 0x58]
movzx eax, ax
imul ecx, eax
movzx eax, byte [edx]
add edx, 2
add cx, ax
mov eax, esi
shr eax, 1
add esi, 2
mov word [ebx + eax*2], cx
mov eax, 0x100
mov ebx, dword [ebp - 0x20]
sub edi, 1
jne 0x46aa30
mov eax, dword [ebp - 0x58]
mov edi, eax
cmp word [eax], 0
je 0x46ab7f
lea ecx, [ecx]
xor ecx, ecx
mov esi, edi
cmp word [edi], 0xd
je 0x46aaac
mov dl, byte [ebp + 0x3048]
movzx eax, word [esi]
cmp eax, 0xa
je 0x46aaac
test ax, ax
je 0x46aaac
test dl, dl
je 0x46aaa3
cmp eax, 0x2f
jne 0x46aaa3
cmp word [esi + 2], ax
jne 0x46aaa3
xor eax, eax
mov ecx, esi
mov word [esi], ax
add esi, 2
cmp word [esi], 0xd
jne 0x46aa80
xor eax, eax
mov word [esi], ax
test ecx, ecx
jne 0x46aab7
mov ecx, esi
lea eax, [ecx - 2]
cmp eax, edi
jb 0x46aad9
mov edi, edi
movzx ecx, word [eax]
cmp ecx, 0x20
je 0x46aacd
cmp ecx, 9
jne 0x46aad9
xor ecx, ecx
mov word [eax], cx
sub eax, 2
cmp eax, edi
jae 0x46aac0
movzx edx, word [edi]
test dx, dx
je 0x46ab5b
mov ecx, edi
lea ebx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x46aae6
sub ecx, ebx
sar ecx, 1
cmp byte [ebp + 0x3044], al
je 0x46ab13
cmp edx, 0x22
jne 0x46ab13
cmp word [edi + ecx*2 - 2], dx
jne 0x46ab13
xor eax, eax
mov word [edi + ecx*2 - 2], ax
add edi, 2
cmp byte [ebp + 0x304c], 0
je 0x46ab52
cmp word [edi], 0x25
jne 0x46ab52
xor eax, eax
mov word [ebp + 0x1024], ax
lea eax, [ebp + 0x1024]
push 0x800
push eax
push edi
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x46ab52
cmp eax, 0x800
jae 0x46ab52
lea eax, [ebp + 0x1024]
push eax
jmp 0x46ab53
push edi
mov ecx, dword [ebp - 0x24]
call fcn.0048e7f0
lea edi, [esi + 2]
mov edi, edi
movzx eax, word [edi]
cmp eax, 0xd
je 0x46ab6d
cmp eax, 0xa
jne 0x46ab72
add edi, 2
jmp 0x46ab60
cmp word [edi], 0
jne 0x46aa70
mov eax, dword [ebp - 0x58]
mov byte [ebp - 4], 2
push eax
call fcn.004f252e
add esp, 4
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x46aba0
push eax
call fcn.004f252e
add esp, 4
mov byte [ebp - 4], 0
push dword [ebp - 0x18]
call fcn.004f252e
add esp, 4
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp]
call fcn.004679c0
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x3024]
xor ecx, ebp
call fcn.004ebbd8
lea esp, [ebp + 0x3028]
pop ebp
ret 0x20