Function at 0x10066100
Capabilities:
Query environment variable

Disassembly:
push ebp
lea ebp, [esp - 0x254]
sub esp, 0x254
push 0xffffffffffffffff
push 0x10234c58
mov eax, dword fs:[0]
push eax
sub esp, 0x24
mov eax, dword [0x102c6474]
xor eax, ebp
mov dword [ebp + 0x250], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x28], edx
mov edi, ecx
mov eax, dword [ebp + 0x25c]
mov dword [ebp - 0x2c], eax
call fcn.10005e30
mov esi, eax
cmp dword [esi + 0x10], 0
jne 0x1006615b
xor al, al
jmp 0x1006697c
lea ecx, [ebp + 0x30]
call fcn.10007fd4
mov dword [ebp - 4], 0
mov eax, esi
mov edx, dword [esi + 0x14]
cmp edx, 8
jb 0x10066176
mov eax, dword [esi]
cmp word [eax], 0x40
jne 0x100661ac
mov eax, dword [esi + 0x10]
lea ecx, [ebp + 0x18]
dec eax
mov edx, edi
push eax
call fcn.10074a60
add esp, 4
mov byte [ebp - 4], 1
lea ecx, [ebp + 0x30]
push eax
call fcn.10007f9d
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x18]
call fcn.10005e05
jmp 0x1006634c
mov ecx, edi
call fcn.10005e30
lea ecx, [ebp + 0x30]
cmp ecx, eax
je 0x1006634c
mov dword [ebp - 0x14], esi
cmp edx, 8
jb 0x100661cb
mov eax, dword [esi]
mov dword [ebp - 0x14], eax
mov ebx, dword [esi + 0x10]
lea ecx, [ebp + 0x30]
call fcn.10005e30
mov edi, eax
mov eax, dword [edi + 0x14]
mov dword [ebp - 0x1c], eax
cmp ebx, eax
ja 0x10066214
mov esi, edi
cmp eax, 8
jb 0x100661eb
mov esi, dword [edi]
push ebx
push dword [ebp - 0x14]
mov dword [edi + 0x10], ebx
push esi
call fcn.10005f10
lea eax, [ebp - 0x10]
mov dword [ebp - 0x10], 0
push eax
lea eax, [esi + ebx*2]
push eax
call fcn.10005eff
add esp, 0x14
jmp 0x1006634c
lea ecx, [ebp + 0x30]
call fcn.1000608d
cmp ebx, eax
ja 0x1006699f
lea ecx, [ebp + 0x30]
call fcn.1000608d
lea ecx, [ebp + 0x30]
mov esi, eax
call fcn.10005e30
mov ecx, ebx
or ecx, 7
mov dword [ebp - 0x24], ecx
cmp ecx, esi
ja 0x10066269
mov edx, dword [eax + 0x14]
mov ecx, edx
shr ecx, 1
mov eax, esi
sub eax, ecx
cmp edx, eax
ja 0x10066269
lea eax, [ecx + edx]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x24]
push eax
call fcn.10005ed6
add esp, 8
mov esi, dword [eax]
lea eax, [esi + 1]
lea ecx, [eax + eax]
cmp eax, 0x7fffffff
jbe 0x1006627b
or ecx, 0xffffffff
jmp 0x10066283
cmp ecx, 0x1000
jb 0x100662ae
lea eax, [ecx + 0x23]
cmp eax, ecx
mov ecx, 0xffffffff
cmovbe eax, ecx
push eax
call fcn.101e4da1
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x100669a4
lea eax, [ecx + 0x23]
and eax, 0xffffffe0
mov dword [eax - 4], ecx
jmp 0x100662bf
test ecx, ecx
je 0x100662bd
push ecx
call fcn.101e4da1
add esp, 4
jmp 0x100662bf
xor eax, eax
mov dword [ebp - 0x10], eax
push ebx
push dword [ebp - 0x14]
mov dword [edi + 0x10], ebx
mov dword [edi + 0x14], esi
mov esi, dword [ebp - 0x10]
push esi
call fcn.10005f29
lea eax, [ebp - 0x14]
mov dword [ebp - 0x14], 0
push eax
lea eax, [esi + ebx*2]
push eax
call fcn.10005eff
mov ecx, dword [ebp - 0x1c]
add esp, 0x14
cmp ecx, 8
jb 0x1006632c
mov eax, dword [edi]
lea ecx, [ecx*2 + 2]
cmp ecx, 0x1000
jb 0x1006631b
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x100669a4
mov eax, edx
push ecx
push eax
call fcn.101e4d70
mov eax, dword [ebp - 0x10]
add esp, 8
mov dword [edi], eax
jmp 0x1006634c
push edi
call fcn.10005f6e
push eax
push 4
call fcn.10005b84
mov esi, eax
lea eax, [ebp - 0x10]
push eax
call fcn.10005f6e
add esp, 0x10
mov ecx, dword [eax]
mov dword [esi], ecx
push 0x208
lea eax, [ebp + 0x48]
push 0
push eax
call fcn.101fd690
add esp, 0xc
lea eax, [ebp + 0x48]
lea ecx, [ebp + 0x30]
push 0x104
push eax
call fcn.10007f54
mov edi, dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
push eax
call edi
mov esi, eax
cmp esi, 0x104
jb 0x10066564
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.101e4dd6
add esp, 4
lea ecx, [ebp + 0x30]
mov ebx, eax
mov dword [ebp - 0x14], ebx
push esi
push ebx
call fcn.10007f54
push eax
call edi
push ebx
call fcn.10005f42
add esp, 4
lea ecx, [ebp + 0x30]
mov ebx, eax
call fcn.10005e30
mov edi, eax
mov eax, dword [edi + 0x14]
mov dword [ebp - 0x18], eax
cmp ebx, eax
ja 0x1006640e
mov esi, edi
cmp eax, 8
jb 0x100663da
mov esi, dword [edi]
push ebx
push dword [ebp - 0x14]
mov dword [edi + 0x10], ebx
push esi
call fcn.10005f10
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x1c], 0
push eax
lea eax, [esi + ebx*2]
push eax
call fcn.10005eff
add esp, 0x14
push dword [ebp - 0x14]
call fcn.101e4dd1
add esp, 4
jmp 0x100666f2
lea ecx, [ebp + 0x30]
call fcn.1000608d
cmp ebx, eax
ja 0x100669a9
lea ecx, [ebp + 0x30]
call fcn.1000608d
lea ecx, [ebp + 0x30]
mov esi, eax
call fcn.10005e30
mov ecx, ebx
or ecx, 7
mov dword [ebp - 0x24], ecx
cmp ecx, esi
ja 0x10066463
mov edx, dword [eax + 0x14]
mov ecx, edx
shr ecx, 1
mov eax, esi
sub eax, ecx
cmp edx, eax
ja 0x10066463
lea eax, [ecx + edx]
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x24]
push eax
call fcn.10005ed6
add esp, 8
mov esi, dword [eax]
lea eax, [esi + 1]
lea ecx, [eax + eax]
cmp eax, 0x7fffffff
jbe 0x10066475
or ecx, 0xffffffff
jmp 0x1006647d
cmp ecx, 0x1000
jb 0x100664a8
lea eax, [ecx + 0x23]
cmp eax, ecx
mov ecx, 0xffffffff
cmovbe eax, ecx
push eax
call fcn.101e4da1
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x100669a4
lea eax, [ecx + 0x23]
and eax, 0xffffffe0
mov dword [eax - 4], ecx
jmp 0x100664b9
test ecx, ecx
je 0x100664b7
push ecx
call fcn.101e4da1
add esp, 4
jmp 0x100664b9
xor eax, eax
mov dword [ebp - 0x10], eax
push ebx
push dword [ebp - 0x14]
mov dword [edi + 0x10], ebx
mov dword [edi + 0x14], esi
mov esi, dword [ebp - 0x10]
push esi
call fcn.10005f29
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0
push eax
lea eax, [esi + ebx*2]
push eax
call fcn.10005eff
mov ecx, dword [ebp - 0x18]
add esp, 0x14
cmp ecx, 8
jb 0x10066534
mov eax, dword [edi]
lea ecx, [ecx*2 + 2]
cmp ecx, 0x1000
jb 0x10066515
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x100669a4
mov eax, edx
push ecx
push eax
call fcn.101e4d70
mov eax, dword [ebp - 0x10]
add esp, 8
mov dword [edi], eax
push dword [ebp - 0x14]
call fcn.101e4dd1
add esp, 4
jmp 0x100666f2
push edi
call fcn.10005f6e
push eax
push 4
call fcn.10005b84
mov esi, eax
lea eax, [ebp - 0x10]
push eax
call fcn.10005f6e
add esp, 0x10
mov ecx, dword [eax]
push dword [ebp - 0x14]
mov dword [esi], ecx
call fcn.101e4dd1
add esp, 4
jmp 0x100666f2
lea eax, [ebp + 0x48]
push eax
call fcn.10005f42
add esp, 4
lea ecx, [ebp + 0x30]
mov ebx, eax
call fcn.10005e30
mov edi, eax
mov eax, dword [edi + 0x14]
mov dword [ebp - 0x20], eax
cmp ebx, eax
ja 0x100665b9
mov esi, edi
cmp eax, 8
jb 0x1006658f
mov esi, dword [edi]
push ebx
lea eax, [ebp + 0x48]
mov dword [edi + 0x10], ebx
push eax
push esi
call fcn.10005f10
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push eax
lea eax, [esi + ebx*2]
push eax
call fcn.10005eff
add esp, 0x14
jmp 0x100666f2
lea ecx, [ebp + 0x30]
call fcn.1000608d
cmp ebx, eax
ja 0x100669ae
lea ecx, [ebp + 0x30]
call fcn.1000608d
lea ecx, [ebp + 0x30]
mov esi, eax
call fcn.10005e30
mov ecx, ebx
or ecx, 7
mov dword [ebp - 0x1c], ecx
cmp ecx, esi
ja 0x1006660e
mov edx, dword [eax + 0x14]
mov ecx, edx
shr ecx, 1
mov eax, esi
sub eax, ecx
cmp edx, eax
ja 0x1006660e
lea eax, [ecx + edx]
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.10005ed6
add esp, 8
mov esi, dword [eax]
lea eax, [esi + 1]
lea ecx, [eax + eax]
cmp eax, 0x7fffffff
jbe 0x10066620
or ecx, 0xffffffff
jmp 0x10066628
cmp ecx, 0x1000
jb 0x10066653
lea eax, [ecx + 0x23]
cmp eax, ecx
mov ecx, 0xffffffff
cmovbe eax, ecx
push eax
call fcn.101e4da1
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x100669a4
lea eax, [ecx + 0x23]
and eax, 0xffffffe0
mov dword [eax - 4], ecx
jmp 0x10066664
test ecx, ecx
je 0x10066662
push ecx
call fcn.101e4da1
add esp, 4
jmp 0x10066664
xor eax, eax
mov dword [ebp - 0x10], eax
lea eax, [ebp + 0x48]
push ebx
mov dword [edi + 0x10], ebx
mov dword [edi + 0x14], esi
mov esi, dword [ebp - 0x10]
push eax
push esi
call fcn.10005f29
lea eax, [ebp - 0x24]
mov dword [ebp - 0x24], 0
push eax
lea eax, [esi + ebx*2]
push eax
call fcn.10005eff
mov ecx, dword [ebp - 0x20]
add esp, 0x14
cmp ecx, 8
jb 0x100666d2
mov eax, dword [edi]
lea ecx, [ecx*2 + 2]
cmp ecx, 0x1000
jb 0x100666c1
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x100669a4
mov eax, edx
push ecx
push eax
call fcn.101e4d70
mov eax, dword [ebp - 0x10]
add esp, 8
mov dword [edi], eax
jmp 0x100666f2
push edi
call fcn.10005f6e
push eax
push 4
call fcn.10005b84
mov esi, eax
lea eax, [ebp - 0x10]
push eax
call fcn.10005f6e
add esp, 0x10
mov ecx, dword [eax]
mov dword [esi], ecx
push 0x10280f30
lea ecx, [ebp]
call fcn.10005e0a
mov byte [ebp - 4], 2
lea ecx, [ebp + 0x30]
call fcn.10005e30
lea ecx, [ebp]
mov dword [ebp - 0x14], eax
mov esi, eax
call fcn.10005e30
mov edi, eax
cmp dword [edi + 0x14], 8
jb 0x10066722
mov eax, dword [edi]
cmp dword [esi + 0x14], 8
mov ecx, esi
jb 0x1006672c
mov ecx, dword [esi]
push dword [edi + 0x10]
mov ebx, dword [esi + 0x10]
mov edx, ebx
push eax
push 0
call fcn.1003c5c0
add esp, 0xc
mov dword [ebp - 0x18], eax
cmp eax, 0xffffffff
je 0x100667b8
push eax
lea edx, [ebp + 0x30]
lea ecx, [ebp + 0x18]
call fcn.100749f0
add esp, 4
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x28]
push eax
call fcn.10007f9d
mov byte [ebp - 4], 2
lea ecx, [ebp + 0x18]
call fcn.10005e05
mov ebx, dword [ebp - 0x2c]
test ebx, ebx
je 0x100667b1
mov eax, dword [esi + 0x10]
lea edx, [ebp + 0x30]
sub eax, dword [edi + 0x10]
lea ecx, [ebp + 0x18]
sub eax, dword [ebp - 0x18]
push eax
call fcn.10074a60
add esp, 4
mov byte [ebp - 4], 4
lea ecx, [ebp + 0x18]
call fcn.10007f54
xor edx, edx
mov ecx, eax
call fcn.100743c0
mov dword [ebx], eax
mov byte [ebp - 4], 2
lea ecx, [ebp + 0x18]
call fcn.10005e05
mov bl, 1
jmp 0x1006695f
lea ecx, [ebp + 0x30]
call fcn.10005e30
mov ecx, dword [ebp - 0x28]
cmp ecx, eax
je 0x10066957
cmp dword [esi + 0x14], 8
jb 0x100667d6
mov esi, dword [esi]
mov dword [ebp - 0x14], esi
call fcn.10005e30
mov edi, eax
mov ecx, dword [edi + 0x14]
mov dword [ebp - 0x20], ecx
cmp ebx, ecx
ja 0x1006681e
mov dword [ebp - 0x10], edi
cmp ecx, 8
jb 0x100667f4
mov eax, dword [edi]
mov dword [ebp - 0x10], eax
push ebx
push esi
push eax
mov dword [edi + 0x10], ebx
call fcn.10005f10
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push eax
mov eax, dword [ebp - 0x10]
lea eax, [eax + ebx*2]
push eax
call fcn.10005eff
add esp, 0x14
jmp 0x10066957
mov esi, dword [ebp - 0x28]
mov ecx, esi
call fcn.1000608d
cmp ebx, eax
ja 0x100669b3
mov ecx, esi
call fcn.1000608d
mov ecx, dword [ebp - 0x28]
mov esi, eax
call fcn.10005e30
mov ecx, ebx
or ecx, 7
mov dword [ebp - 0x1c], ecx
cmp ecx, esi
ja 0x10066874
mov edx, dword [eax + 0x14]
mov ecx, edx
shr ecx, 1
mov eax, esi
sub eax, ecx
cmp edx, eax
ja 0x10066874
lea eax, [ecx + edx]
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.10005ed6
add esp, 8
mov esi, dword [eax]
lea eax, [esi + 1]
lea ecx, [eax + eax]
cmp eax, 0x7fffffff
jbe 0x10066886
or ecx, 0xffffffff
jmp 0x1006688e
cmp ecx, 0x1000
jb 0x100668b9
lea eax, [ecx + 0x23]
cmp eax, ecx
mov ecx, 0xffffffff
cmovbe eax, ecx
push eax
call fcn.101e4da1
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x100669a4
lea eax, [ecx + 0x23]
and eax, 0xffffffe0
mov dword [eax - 4], ecx
jmp 0x100668ca
test ecx, ecx
je 0x100668c8
push ecx
call fcn.101e4da1
add esp, 4
jmp 0x100668ca
xor eax, eax
mov dword [ebp - 0x10], eax
push ebx
push dword [ebp - 0x14]
mov dword [edi + 0x10], ebx
mov dword [edi + 0x14], esi
mov esi, dword [ebp - 0x10]
push esi
call fcn.10005f29
lea eax, [ebp - 0x24]
mov dword [ebp - 0x24], 0
push eax
lea eax, [esi + ebx*2]
push eax
call fcn.10005eff
mov ecx, dword [ebp - 0x20]
add esp, 0x14
cmp ecx, 8
jb 0x10066937
mov eax, dword [edi]
lea ecx, [ecx*2 + 2]
cmp ecx, 0x1000
jb 0x10066926
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x100669a4
mov eax, edx
push ecx
push eax
call fcn.101e4d70
mov eax, dword [ebp - 0x10]
add esp, 8
mov dword [edi], eax
jmp 0x10066957
push edi
call fcn.10005f6e
push eax
push 4
call fcn.10005b84
mov esi, eax
lea eax, [ebp - 0x10]
push eax
call fcn.10005f6e
add esp, 0x10
mov ecx, dword [eax]
mov dword [esi], ecx
mov ebx, dword [ebp - 0x2c]
test ebx, ebx
sete bl
mov byte [ebp - 4], 0
lea ecx, [ebp]
call fcn.10005e05
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x30]
call fcn.10005e05
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x250]
xor ecx, ebp
call fcn.101e48f0
lea esp, [ebp + 0x254]
pop ebp
ret
call fcn.1000604b
call fcn.10205f6e
call fcn.1000604b
call fcn.1000604b
call fcn.1000604b
int3