Function at 0x1011d18
Capabilities:
Query environment variable

Disassembly:
push 0x14
mov eax, 0x1025de6
call fcn.0100a184
mov edx, dword [ebp + 8]
xor ebx, ebx
cmp edx, ebx
jne 0x1011d4c
push ebx
push 0x54f
push 0x1004520
push 0x667
push 0x1004190
call fcn.0100a8b1
jmp 0x1011fdb
mov eax, edx
lea esi, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
cmp cx, bx
jne 0x1011d51
sub eax, esi
sar eax, 1
je 0x1011fd0
movzx eax, word [edx]
cmp ax, 0x20
je 0x1011fd0
cmp ax, 9
je 0x1011fd0
mov edi, dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
push ebx
push ebx
push edx
call edi
mov esi, eax
cmp esi, ebx
je 0x1011fdb
push 2
pop edx
xor ecx, ecx
mul edx
seto cl
push ebx
neg ecx
or eax, ecx
lea ecx, [ebp - 0xd]
push ecx
push eax
call sub.WsmSvc.DLL_public:_static_void____stdcall_WSManMemory::Alloc_unsigned_int__class_TestSystem::CallSite_const___enum_TestSystem::Mode_
push eax
lea ecx, [ebp - 0x14]
call fcn.0100c474
mov dword [ebp - 4], ebx
cmp dword [ebp - 0x14], ebx
jne 0x1011dd4
push 0xe
call dword [sym.imp.KERNEL32.dll_SetLastError]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.0100c61b
jmp 0x1011fdb
push esi
push dword [ebp - 0x14]
push dword [ebp + 8]
call edi
cmp eax, ebx
je 0x1011dc3
push 2
pop edx
xor ecx, ecx
mov eax, esi
mul edx
seto cl
push ebx
neg ecx
or eax, ecx
lea ecx, [ebp + 0xb]
push ecx
push eax
call sub.WsmSvc.DLL_public:_static_void____stdcall_WSManMemory::Alloc_unsigned_int__class_TestSystem::CallSite_const___enum_TestSystem::Mode_
push eax
lea ecx, [ebp - 0x18]
call fcn.0100c474
mov byte [ebp - 4], 1
cmp dword [ebp - 0x18], ebx
jne 0x1011e23
push 0xe
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov byte [ebp - 4], bl
lea ecx, [ebp - 0x18]
call fcn.0100c61b
jmp 0x1011dc3
lea eax, [ebp - 0x20]
push eax
push dword [ebp - 0x18]
mov dword [ebp - 0x20], ebx
push esi
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
cmp eax, ebx
jne 0x1011e4c
mov ecx, dword [ebp + 0xc]
cmp ecx, ebx
je 0x1011e16
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x14], ebx
mov dword [ecx], eax
jmp 0x1011e16
dec esi
cmp eax, esi
jne 0x1011fc0
push dword [ebp - 0x18]
push dword [ebp - 0x14]
call fcn.0100ad10
test eax, eax
je 0x1011fc0
cmp dword [ebp + 0x14], ebx
je 0x1011eb4
push 0x25
push dword [ebp - 0x18]
call fcn.010111c5
test eax, eax
jne 0x1011eb4
push 0x26
push dword [ebp - 0x18]
call fcn.010111c5
test eax, eax
jne 0x1011eb4
push 0x80338191
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor esi, esi
mov byte [ebp - 4], bl
lea ecx, [ebp - 0x18]
call fcn.0100c61b
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.0100c61b
mov eax, esi
jmp 0x1011fdd
mov esi, dword [ebp - 0x18]
cmp dword [ebp + 0x10], ebx
je 0x1011ed6
push ebx
push 0x54f
push 0x1004514
push 0x6e6
push 0x1004190
call fcn.0100a8b1
mov dword [ebp - 0x1c], ebx
mov byte [ebp - 4], 3
push ebx
push 0x80
push 3
push ebx
push 7
mov edi, 0x80000000
push edi
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CreateFileW]
call esi
push eax
lea ecx, [ebp - 0x1c]
call fcn.0101153a
cmp dword [ebp - 0x1c], 0xffffffff
jne 0x1011f98
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x20
jne 0x1011f29
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x1c]
call fcn.0100b9f6
xor esi, esi
inc esi
jmp 0x1011e96
cmp eax, 2
je 0x1011f6d
cmp eax, 3
je 0x1011f6d
cmp eax, 0x7b
jne 0x1011f3f
push 0x80338191
jmp 0x1011f72
cmp eax, 5
jne 0x1011f66
push ebx
push 0x2000000
push 3
push ebx
push 7
push edi
push dword [ebp - 0x18]
call esi
push eax
lea ecx, [ebp - 0x1c]
call fcn.0101153a
cmp dword [ebp - 0x1c], 0xffffffff
je 0x1011f78
jmp 0x1011f38
push 0x54f
jmp 0x1011f72
push 0x80338192
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov ecx, dword [ebp + 0xc]
cmp ecx, ebx
je 0x1011f87
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x14], ebx
mov dword [ecx], eax
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x1c]
call fcn.0100b9f6
jmp 0x1011e94
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x1c]
call fcn.0100b9f6
mov byte [ebp - 4], bl
lea ecx, [ebp - 0x18]
call fcn.0100c61b
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.0100c61b
xor eax, eax
inc eax
jmp 0x1011fdd
push 0x80338191
call dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1011e3b
push 0x80338191
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
call fcn.0100a270
ret 0x10