Function at 0x100e2750
Capabilities:
Get thread local storage value
Query environment variable
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x10124c28
mov eax, dword fs:[0]
push eax
sub esp, 0x58
push ebx
push esi
push edi
mov eax, dword [0x1016e750]
xor eax, esp
push eax
lea eax, [esp + 0x68]
mov dword fs:[0], eax
cmp dword [0x10175108], 1
jne 0x100e27f6
push dword [ebp + 0x14]
lea eax, [esp + 0x28]
push dword [ebp + 0xc]
push str._denying_access_to__s:0x_x__SCM_SUPPORT_DENY_CHANGE_
push eax
call fcn.10044f30
add esp, 0x10
mov dword [esp + 0x70], 0
mov ecx, 0x101530d4
mov edx, dword [eax]
call fcn.10043b30
mov dword [esp + 0x70], 0xffffffff
or ecx, 0xffffffff
mov edx, dword [esp + 0x24]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x100e27d7
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push 5
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
mov ecx, dword [esp + 0x68]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x34
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [0x1016f5d0]
mov ebx, eax
mov dword [esp + 0x28], ebx
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
cmp byte [0x1017045d], 0
mov dword [esp + 0x2c], eax
je 0x100e2826
test al, 1
je 0x100e2868
push ebx
call dword [sym.imp.KERNEL32.dll_SetLastError]
push dword [ebp + 0x38]
push dword [ebp + 0x34]
push dword [ebp + 0x30]
push dword [ebp + 0x2c]
push dword [ebp + 0x28]
push dword [ebp + 0x24]
push dword [ebp + 0x20]
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [0x101728f8]
mov ecx, dword [esp + 0x68]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x34
or eax, 1
push eax
push dword [0x1016f5d0]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov ebx, dword [ebp + 0x24]
lea ecx, [esp + 0x10]
test ebx, ebx
mov eax, 0x1012ec60
cmovne eax, ebx
push eax
call fcn.10023fc0
mov dword [esp + 0x70], 1
test ebx, ebx
je 0x100e28dd
mov eax, dword [esp + 0x10]
mov edx, 1
mov ecx, dword [eax - 8]
sub edx, dword [eax - 4]
sub ecx, 0x104
or ecx, edx
jge 0x100e28c6
push 0x104
lea ecx, [esp + 0x14]
call fcn.100249c0
mov eax, dword [esp + 0x10]
push 0x104
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
push ecx
lea ecx, [esp + 0x14]
call fcn.10024210
push dword [ebp + 0x14]
mov edx, dword [ebp + 0x34]
mov ecx, str.NULL
mov esi, dword [ebp + 0xc]
test edx, edx
mov eax, ecx
cmovne eax, edx
mov edx, dword [ebp + 0x10]
push eax
push dword [esp + 0x18]
test ebx, ebx
mov eax, ecx
cmovne eax, ebx
test edx, edx
push eax
mov eax, ecx
cmovne eax, edx
test esi, esi
push eax
push dword [ebp + 0x1c]
cmovne ecx, esi
lea eax, [esp + 0x38]
push dword [ebp + 0x18]
push ecx
push dword [ebp + 8]
push str.CreateServiceW_0x_x__ServiceName_ws__dwServiceType_d__dwStartType_d__DisplayName_ws__BinaryPathName_ws_expanded_ws___ServiceStartName_ws__0x_x_
push eax
call fcn.10044f30
add esp, 0x2c
mov byte [esp + 0x70], 2
mov ecx, 0x10153164
mov edx, dword [eax]
call fcn.10043b30
mov byte [esp + 0x70], 1
or edi, 0xffffffff
mov edx, dword [esp + 0x20]
mov eax, edi
add edx, 0xfffffff0
lea ecx, [edx + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x100e2961
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
test byte [0x10175108], 2
je 0x100e2b5f
push ecx
mov ecx, dword [0x1017507c]
mov esi, esp
add ecx, 0xfffffff0
mov dword [esp + 0x2c], esp
call fcn.10024750
add eax, 0x10
mov dword [esi], eax
mov esi, dword [ebp + 0xc]
push ecx
mov ecx, esp
mov byte [esp + 0x78], 3
push esi
call fcn.10023fc0
mov byte [esp + 0x78], 1
call fcn.1003e6a0
add esp, 8
test eax, eax
jne 0x100e2b5f
lea ecx, [esp + 0x1c]
call fcn.10023f70
lea ecx, [esp + 0x18]
call fcn.10023f70
lea ecx, [esp + 0x14]
call fcn.10023f70
mov ebx, dword [ebp + 0x20]
mov eax, dword [ebp + 0x1c]
mov edi, dword [ebp + 0x28]
push ebx
push eax
push dword [ebp + 0x18]
mov byte [esp + 0x7c], 6
push ecx
mov ecx, esp
mov dword [esp + 0x38], esp
push edi
mov dword [esp + 0x34], 0
call fcn.10023fc0
push ecx
mov byte [esp + 0x84], 7
mov ecx, esp
mov dword [esp + 0x44], esp
push dword [ebp + 0x24]
call fcn.10023fc0
mov eax, dword [ebp + 0x10]
push ecx
mov byte [esp + 0x88], 8
mov ecx, esp
mov dword [esp + 0x4c], esp
push eax
call fcn.10023fc0
push ecx
mov ecx, esp
mov byte [esp + 0x8c], 9
push esi
call fcn.10023fc0
lea ecx, [esp + 0x58]
mov byte [esp + 0x8c], 6
call fcn.100e0ed0
lea eax, [esp + 0x20]
mov byte [esp + 0x70], 0xa
push eax
lea eax, [esp + 0x18]
mov ecx, 0x10175070
push eax
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x28]
push eax
lea edx, [esp + 0x4c]
call fcn.1003f200
mov esi, dword [esp + 0x28]
lea eax, [esp + 0x38]
push esi
push dword [ebp + 0xc]
push str._Virtualizing_CreateServiceW:__s_____s
push eax
call fcn.10044f30
add esp, 0x20
mov byte [esp + 0x70], 0xb
mov ecx, 0x10153164
mov edx, dword [eax]
call fcn.10043b30
lea ecx, [esp + 0x28]
mov byte [esp + 0x70], 0xa
call fcn.10024080
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.dll_SetLastError]
push dword [ebp + 0x38]
mov eax, dword [ebp + 0x34]
push eax
push dword [ebp + 0x30]
push dword [ebp + 0x2c]
mov eax, dword [ebp + 0x14]
push edi
push dword [esp + 0x30]
push ebx
push dword [esp + 0x3c]
push dword [ebp + 0x18]
push eax
push dword [esp + 0x3c]
mov eax, dword [ebp + 8]
push esi
push eax
call dword [0x101728f8]
mov ebx, eax
test ebx, ebx
je 0x100e2b31
lea eax, [esp + 0x28]
push str.CreateServiceW_succeeded._Flagging_service_as_integrated.
push eax
call fcn.10044f30
add esp, 8
mov byte [esp + 0x70], 0xc
mov ecx, 0x10153164
mov edx, dword [eax]
call fcn.10043b30
lea ecx, [esp + 0x28]
mov byte [esp + 0x70], 0xa
call fcn.10024080
push ecx
lea ecx, [esi - 0x10]
mov edi, esp
call fcn.10024750
add eax, 0x10
lea edx, [esp + 0x40]
mov ecx, 0x10175070
mov dword [edi], eax
call fcn.1003f6f0
add esp, 4
lea ecx, [esp + 0x3c]
call fcn.1003e7d0
lea ecx, [esp + 0x14]
call fcn.10024080
lea ecx, [esp + 0x18]
call fcn.10024080
lea ecx, [esp + 0x1c]
mov byte [esp + 0x70], 1
call fcn.10024080
or edi, 0xffffffff
jmp 0x100e2bd5
push esi
lea eax, [esp + 0x2c]
push str._No_need_to_virtualize_CreateServiceW__s_
push eax
call fcn.10044f30
add esp, 0xc
mov byte [esp + 0x70], 0xd
mov ecx, 0x10153164
mov edx, dword [eax]
call fcn.10043b30
mov byte [esp + 0x70], 1
mov ecx, edi
mov edx, dword [esp + 0x28]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x100e2ba5
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [ebp + 0x38]
mov eax, dword [ebp + 0x34]
push eax
push dword [ebp + 0x30]
mov eax, dword [ebp + 0x1c]
push dword [ebp + 0x2c]
push dword [ebp + 0x28]
push ebx
push dword [ebp + 0x20]
push eax
push dword [ebp + 0x18]
mov eax, dword [ebp + 0x14]
push eax
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp + 8]
push esi
push eax
call dword [0x101728f8]
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
lea eax, [esp + 0x30]
push str.Result0x_x__LE_d_
push eax
call fcn.10044f30
add esp, 0x10
mov byte [esp + 0x70], 0xe
mov ecx, 0x10153164
mov edx, dword [eax]
call fcn.10043b30
mov byte [esp + 0x70], 1
mov ecx, edi
mov edx, dword [esp + 0x28]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x100e2c22
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [esp + 0x2c]
push dword [0x1016f5d0]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov dword [esp + 0x70], 0xffffffff
mov edx, dword [esp + 0x10]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x100e2c5f
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, ebx
mov ecx, dword [esp + 0x68]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x34