Function at 0x412180
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x34
mov eax, dword [0x62d040]
xor eax, esp
mov dword [esp + 0x30], eax
movzx eax, word [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0x10]
mov dword [esp + 0x18], edi
sub eax, 9
je 0x412603
sub eax, 1
je 0x41244b
jmp 0x4121c0
sub eax, 1
jne 0x412718
mov dword [esp + 0xc], eax
lea eax, [esp + 0xc]
push eax
push esi
call sym.SystemInformer.exe_PhParseCommandLinePart
jmp 0x4121e0
test eax, eax
je 0x412718
lea ecx, [eax - 8]
or eax, 0xffffffff
lock xadd dword [ecx + 4], eax
dec eax
jne 0x4121fb
call fcn.004fbd80
mov edx, dword [esi]
mov ecx, dword [esp + 0xc]
shr edx, 1
cmp ecx, edx
jae 0x412222
mov eax, dword [esi + 4]
lea eax, [eax + ecx*2]
lea ecx, [ecx]
cmp word [eax], 0x20
jne 0x41221e
inc ecx
add eax, 2
cmp ecx, edx
jb 0x412210
mov dword [esp + 0xc], ecx
lea eax, [esp + 0xc]
push eax
push esi
call sym.SystemInformer.exe_PhParseCommandLinePart
mov ebx, eax
mov dword [esp + 0x10], ebx
test ebx, ebx
je 0x412718
push ebx
call sym.SystemInformer.exe_PhAutoDereferenceObject
mov eax, dword [ebx]
lea ebx, [ebx + 4]
shr eax, 1
mov esi, 0
mov dword [esp + 0xc], eax
je 0x41227f
mov edi, eax
lea esp, [esp]
mov eax, dword [ebx]
movzx eax, word [eax + esi*2]
push eax
call dword [sym.imp.ntdll.dll_RtlUpcaseUnicodeChar]
movzx ecx, ax
mov eax, dword [ebx]
mov word [eax + esi*2], cx
inc esi
cmp esi, edi
jb 0x412260
mov edi, dword [esp + 0x18]
mov esi, dword ds:[esp + 0x10]
lea eax, [esp + 0x18]
push 0
push eax
push esi
mov dword [esp + 0x24], 0x16
mov dword [esp + 0x28], str._PROCESSID:
call sym.SystemInformer.exe_PhFindStringInStringRef
mov edx, eax
cmp edx, 0xffffffff
je 0x412718
mov eax, dword [esi]
mov ecx, dword [ebx]
shr eax, 1
sub eax, edx
push 0
lea ecx, [ecx + edx*2]
push 0
lea eax, [eax*2 - 0x16]
add ecx, 0x16
mov dword [esp + 0x18], eax
lea eax, [esp + 0x18]
push eax
mov dword [esp + 0x20], ecx
call sym.SystemInformer.exe_PhCreateString3
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
mov esi, eax
lea eax, [esp + 0x2c]
push eax
push esi
call sym.SystemInformer.exe_PhStringToGuid
test eax, eax
js 0x412718
lfence
mov ecx, dword [esp + 0x2c]
mov eax, dword [esp + 0x30]
mov dword [edi], ecx
mov dword [edi + 4], eax
mov eax, dword [esp + 0x34]
mov dword [edi + 8], eax
mov eax, dword [esp + 0x38]
mov dword [edi + 0xc], eax
mov dword [edi + 0x10], 0
mov dword [edi + 0x14], 0
push dword [esi + 4]
push str.CLSID_
call sym.SystemInformer.exe_PhConcatStrings2
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
push 0
push eax
push 0xfffffffffffffff9
push 0x20019
lea eax, [esp + 0x30]
push eax
call sym.SystemInformer.exe_PhOpenKey
test eax, eax
js 0x4123dd
push 0
push dword [esp + 0x24]
call sym.SystemInformer.exe_PhQueryRegistryString
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
push 0
push 0x62de50
push dword [esp + 0x28]
mov dword [edi + 0x10], eax
lea eax, [esp + 0x30]
push 0x20019
push eax
call sym.SystemInformer.exe_PhOpenKey
test eax, eax
js 0x4123bd
push 0
push dword [esp + 0x28]
call sym.SystemInformer.exe_PhQueryRegistryString
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
push eax
mov dword [edi + 0x14], eax
call sym.SystemInformer.exe_PhExpandEnvironmentStrings
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
test eax, eax
je 0x4123b3
mov dword [edi + 0x14], eax
push dword [esp + 0x24]
call dword [sym.imp.ntdll.dll_NtClose]
push dword [esp + 0x20]
call dword [sym.imp.ntdll.dll_NtClose]
mov al, 1
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.0057e94f
mov esp, ebp
pop ebp
ret 0xc
lfence
push dword [esi + 4]
push str.AppID_
call sym.SystemInformer.exe_PhConcatStrings2
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
push 0
push eax
push 0xfffffffffffffff9
push 0x20019
lea eax, [esp + 0x30]
push eax
call sym.SystemInformer.exe_PhOpenKey
test eax, eax
js 0x4125eb
push 0
push dword [esp + 0x24]
call sym.SystemInformer.exe_PhQueryRegistryString
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
push dword [esp + 0x20]
mov dword [edi + 0x10], eax
call dword [sym.imp.ntdll.dll_NtClose]
mov al, 1
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.0057e94f
mov esp, ebp
pop ebp
ret 0xc
lea eax, [esp + 0xc]
mov dword [esp + 0xc], 0
push eax
push esi
call sym.SystemInformer.exe_PhParseCommandLinePart
mov edi, edi
test eax, eax
je 0x412718
lea ecx, [eax - 8]
or eax, 0xffffffff
lock xadd dword [ecx + 4], eax
dec eax
jne 0x41247b
call fcn.004fbd80
mov edx, dword [esi]
mov ecx, dword [esp + 0xc]
shr edx, 1
cmp ecx, edx
jae 0x4124a2
mov eax, dword [esi + 4]
lea eax, [eax + ecx*2]
lea ecx, [ecx]
cmp word [eax], 0x20
jne 0x41249e
inc ecx
add eax, 2
cmp ecx, edx
jb 0x412490
mov dword [esp + 0xc], ecx
lea eax, [esp + 0xc]
push eax
push esi
call sym.SystemInformer.exe_PhParseCommandLinePart
mov esi, eax
test esi, esi
je 0x412718
push esi
call sym.SystemInformer.exe_PhAutoDereferenceObject
lea eax, [esp + 0x18]
push eax
lea eax, [esp + 0x14]
push eax
push 0x2c
push esi
call sym.SystemInformer.exe_PhSplitStringRefAtLastChar
test al, al
je 0x412718
mov ecx, dword [esp + 0x10]
test ecx, ecx
jne 0x4124e7
nop
call sym.SystemInformer.exe_PhReferenceEmptyString
jmp 0x412505
mov eax, dword ds:[esp + 0x14]
push 0
mov dword [esp + 0x18], eax
lea eax, [esp + 0x14]
push 0
push eax
mov dword [esp + 0x1c], ecx
call sym.SystemInformer.exe_PhCreateString3
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
mov ecx, dword [esp + 0x18]
mov ebx, eax
test ecx, ecx
jne 0x41251c
call sym.SystemInformer.exe_PhReferenceEmptyString
jmp 0x412536
mov eax, dword [esp + 0x1c]
push 0
mov dword [esp + 0x18], eax
lea eax, [esp + 0x14]
push 0
push eax
mov dword [esp + 0x1c], ecx
call sym.SystemInformer.exe_PhCreateString3
push eax
call sym.SystemInformer.exe_PhAutoDereferenceObject
mov esi, eax
push ebx
mov dword [esp + 0x14], esi
call sym.SystemInformer.exe_PhDetermineDosPathNameType
cmp eax, 5
jne 0x4125e6
lea eax, [esp + 0x18]
push eax
call sym.SystemInformer.exe_PhGetSystemRoot
test ebx, ebx
je 0x41258c
push ebx
push 0x630c00
lea eax, [esp + 0x20]
push eax
call sym.SystemInformer.exe_PhConcatStringRef3
mov ebx, eax
mov dword [edi + 4], esi
mov dword [edi], ebx
mov al, 1
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.0057e94f
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [0x630c00]
mov esi, dword [esp + 0x18]
add eax, esi
push 0
mov dword [esp + 0x28], eax
lea eax, [esp + 0x28]
push 0
push eax
mov dword [esp + 0x34], 0
call sym.SystemInformer.exe_PhCreateString3
mov ebx, eax
push esi
push dword [esp + 0x20]
push dword [ebx + 4]
call fcn.00580c90
mov eax, dword [ebx + 4]
add esp, 0xc
add eax, esi
push dword [0x630c00]
push dword [0x630c04]
push eax
call fcn.00580c90
mov esi, dword [esp + 0x1c]
add esp, 0xc
mov dword [edi], ebx
mov dword [edi + 4], esi
mov al, 1
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.0057e94f
mov esp, ebp
pop ebp
ret 0xc
push edi
push 0x412120
push 1
push 1
push 0x62de60
push esi
mov dword [edi], 0
call sym.SystemInformer.exe_PhParseCommandLine
mov edi, dword [edi]
test edi, edi
je 0x412718
cmp dword [0x62dbb0], 0xffffffff
mov ecx, dword [0x635c08]
jae 0x41264e
cmp ecx, 0x40
jae 0x41264e
lfence
mov eax, dword fs:[0x18]
mov esi, dword [eax + ecx*4 + 0xe10]
jmp 0x412657
push ecx
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
mov eax, dword [esi]
cmp eax, 0x40
jae 0x41267a
mov dword [esi + eax*4 + 4], edi
mov al, 1
inc dword [esi]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.0057e94f
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [esi + 0x10c]
test ecx, ecx
jne 0x4126ae
push 0x100
push 4
push dword [0x633f94]
mov dword [esi + 0x108], 0x40
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov ecx, eax
mov dword [esi + 0x10c], ecx
mov eax, dword [esi + 0x108]
cmp dword [esi + 0x104], eax
jne 0x4126f3
add eax, eax
mov dword [esi + 0x108], eax
shl eax, 2
push eax
test ecx, ecx
jne 0x4126dc
push 4
push dword [0x633f94]
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
jmp 0x4126eb
push ecx
push 4
push dword [0x633f94]
call dword [sym.imp.ntdll.dll_RtlReAllocateHeap]
mov ecx, eax
mov dword [esi + 0x10c], ecx
mov eax, dword [esi + 0x104]
mov dword [ecx + eax*4], edi
mov al, 1
inc dword [esi + 0x104]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.0057e94f
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [esp + 0x3c]
xor al, al
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0057e94f
mov esp, ebp
pop ebp
ret 0xc