Function at 0x415080
Capabilities:
Get thread local storage value
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4a9904
mov eax, dword fs:[0]
push eax
sub esp, 0x488
mov eax, dword [0x4dc6e0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
cmp dword [ebp + 0x14], 0xffffffff
mov esi, 0x4af9b8
mov eax, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
mov edi, dword [ebp + 0x10]
mov dword [ebp - 0x468], eax
mov dword [ebp - 0x454], ebx
mov dword [ebp - 0x46c], edi
jne 0x415285
push esi
call fcn.0048faa4
mov dword [ebp - 0x430], eax
push esi
mov dword [ebp - 4], 0
call fcn.0048faa4
mov dword [ebp - 0x464], eax
push esi
call fcn.0048faa4
mov dword [ebp - 0x434], eax
push esi
call fcn.0048faa4
mov dword [ebp - 0x438], eax
push esi
call fcn.0048faa4
mov dword [ebp - 0x444], eax
push esi
call fcn.0048faa4
mov dword [ebp - 0x44c], eax
push esi
call fcn.0048faa4
mov dword [ebp - 0x450], eax
test edi, edi
mov eax, esi
cmovne eax, edi
push eax
call fcn.0048faa4
mov dword [ebp - 0x45c], eax
push esi
call fcn.0048faa4
mov dword [ebp - 0x458], eax
test edi, edi
mov eax, esi
cmovne eax, edi
push eax
call fcn.0048faa4
mov dword [ebp - 0x460], eax
lea eax, [ebp - 0x450]
mov byte [ebp - 4], 9
push eax
lea eax, [ebp - 0x45c]
push eax
lea eax, [ebp - 0x428]
push ebx
push eax
call fcn.00407620
mov esi, eax
lea eax, [ebp - 0x458]
mov byte [ebp - 4], 0xa
push eax
lea eax, [ebp - 0x460]
push eax
lea eax, [ebp - 0x42c]
push ebx
push eax
call fcn.00407620
add esp, 0x48
push 0xffffffffffffffff
push 0
push 0
lea ecx, [ebp - 0x430]
mov byte [ebp - 4], 0xb
push ecx
push 1
push 0
lea ecx, [ebp - 0x464]
push ecx
lea ecx, [ebp - 0x434]
push ecx
lea ecx, [ebp - 0x438]
push ecx
lea ecx, [ebp - 0x444]
push ecx
lea ecx, [ebp - 0x44c]
push ecx
push esi
push eax
push 0
push 0xffffffffffffffff
push 0
push dword [ebp - 0x468]
call fcn.00403eb0
push dword [ebp - 0x42c]
mov dword [ebp + 0x14], eax
call fcn.0048faf7
add esp, 0x48
push dword [ebp - 0x428]
call fcn.0048faf7
push dword [ebp - 0x460]
call fcn.0048faf7
push dword [ebp - 0x458]
call fcn.0048faf7
push dword [ebp - 0x45c]
call fcn.0048faf7
push dword [ebp - 0x450]
call fcn.0048faf7
push dword [ebp - 0x44c]
call fcn.0048faf7
push dword [ebp - 0x444]
call fcn.0048faf7
push dword [ebp - 0x438]
call fcn.0048faf7
push dword [ebp - 0x434]
call fcn.0048faf7
push dword [ebp - 0x464]
call fcn.0048faf7
push dword [ebp - 0x430]
call fcn.0048faf7
add esp, 0x2c
mov esi, 0x4af9b8
push 2
call fcn.0048fb2f
xor ecx, ecx
mov dword [ebp - 0x430], eax
mov word [eax], cx
push edi
mov dword [ebp - 4], 0xc
mov dword [ebp - 0x474], ecx
call fcn.0048faa4
push 0x5c
push eax
mov dword [ebp - 0x460], eax
call fcn.0049130d
mov ecx, eax
add esp, 0x10
xor eax, eax
mov word [ecx], ax
add ecx, 2
mov dword [ebp - 0x470], ecx
cmp byte [ebp + 0x18], al
je 0x4152f1
push edi
call fcn.0048faa4
push dword [ebp - 0x430]
mov ebx, eax
mov dword [ebp - 0x464], ebx
call fcn.0048faf7
add esp, 8
jmp 0x4153e7
test ecx, ecx
mov eax, esi
cmovne eax, ecx
push eax
call fcn.0048faa4
mov ebx, eax
push 0x4b4ae4
mov dword [ebp - 0x440], ebx
call fcn.0048faa4
mov ecx, dword [ebp - 0x460]
mov edi, eax
test ecx, ecx
mov dword [ebp - 0x428], edi
mov eax, esi
cmovne eax, ecx
push eax
call fcn.0048faa4
mov esi, eax
lea eax, [ebp - 0x42c]
push 0x4afa48
push eax
lea eax, [ebp - 0x438]
mov dword [ebp - 0x42c], esi
push eax
call fcn.00418660
lea ecx, [ebp - 0x428]
push ecx
push eax
lea eax, [ebp - 0x434]
push eax
call fcn.0041ca30
push 0x4afa48
push eax
lea eax, [ebp - 0x43c]
push eax
call fcn.00418660
lea ecx, [ebp - 0x440]
push ecx
push eax
lea eax, [ebp - 0x448]
push eax
call fcn.0041ca30
push dword [eax]
call fcn.0048faa4
add esp, 0x40
mov dword [ebp - 0x464], eax
push dword [ebp - 0x430]
call fcn.0048faf7
push dword [ebp - 0x448]
call fcn.0048faf7
push dword [ebp - 0x43c]
call fcn.0048faf7
push dword [ebp - 0x434]
call fcn.0048faf7
push dword [ebp - 0x438]
call fcn.0048faf7
push esi
call fcn.0048faf7
push edi
call fcn.0048faf7
push ebx
call fcn.0048faf7
mov ebx, dword [ebp - 0x464]
add esp, 0x20
lea eax, [ebp - 0x474]
push eax
push dword [0x4de020]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
or eax, 0x20019
push eax
push 0
push ebx
push dword [ebp - 0x454]
call fcn.00406320
add esp, 0x14
test eax, eax
jne 0x415a60
mov dword [ebp - 0x478], eax
lea eax, [ebp - 0x47c]
push eax
lea eax, [ebp - 0x420]
mov dword [ebp - 0x47c], 0x208
push eax
push 0
push 0
push 0
push dword [ebp - 0x474]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x415a54
lea eax, [ebp - 0x420]
push eax
call fcn.0048faa4
mov esi, eax
mov dword [ebp - 0x42c], esi
lea eax, [ebp - 0x42c]
push eax
lea eax, [ebp - 0x440]
push 0x4afb58
push eax
call fcn.00417070
push 0x4b4d48
push eax
lea eax, [ebp - 0x428]
push eax
call fcn.00418660
add esp, 0x1c
mov edi, dword [eax]
lea eax, [ebp - 0x478]
push eax
push dword [0x4de020]
mov byte [ebp - 4], 0xf
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
or eax, 0x20019
push eax
push 0
push edi
push dword [ebp - 0x454]
call fcn.00406320
push dword [ebp - 0x428]
test eax, eax
sete byte [ebp - 0x421]
call fcn.0048faf7
push dword [ebp - 0x440]
call fcn.0048faf7
push esi
mov byte [ebp - 4], 0xc
call fcn.0048faf7
add esp, 0x20
cmp byte [ebp - 0x421], 0
je 0x415a54
lea eax, [ebp - 0x47c]
mov dword [ebp - 0x47c], 0x208
push eax
lea eax, [ebp - 0x218]
push eax
push 0
push 0
push 0
push dword [ebp - 0x478]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x415a48
mov ecx, 0x4b4d70
lea eax, [ebp - 0x218]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x41555b
test dx, dx
je 0x415557
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x41555b
add eax, 4
add ecx, 4
test dx, dx
jne 0x415535
xor eax, eax
jmp 0x415560
sbb eax, eax
or eax, 1
test eax, eax
je 0x415a48
push 2
call fcn.0048fb2f
xor ecx, ecx
mov dword [ebp - 0x450], eax
mov word [eax], cx
push 2
call fcn.0048fb2f
xor ecx, ecx
mov dword [ebp - 0x458], eax
mov word [eax], cx
push 2
call fcn.0048fb2f
xor ecx, ecx
mov dword [ebp - 0x45c], eax
add esp, 0xc
mov word [eax], cx
lea ecx, [ebp - 0x494]
call fcn.004020f0
lea eax, [ebp - 0x494]
mov byte [ebp - 4], 0x13
push eax
lea eax, [ebp - 0x218]
push eax
call fcn.00406bd0
mov esi, dword [ebp - 0x468]
lea eax, [ebp - 0x494]
push 0
push eax
lea eax, [ebp - 0x44c]
push esi
push eax
call fcn.00404cf0
lea eax, [ebp - 0x458]
mov byte [ebp - 4], 0x14
push eax
lea eax, [ebp - 0x450]
push eax
push dword [ebp - 0x44c]
push esi
call fcn.00404ce0
push 0x4af9b8
mov dword [ebp - 0x480], eax
call fcn.0048faa4
mov dword [ebp - 0x43c], eax
mov edi, dword [ebp - 0x46c]
mov esi, 0x4af9b8
test edi, edi
mov ecx, esi
cmovne ecx, edi
push ecx
call fcn.0048faa4
mov dword [ebp - 0x444], eax
push esi
call fcn.0048faa4
mov dword [ebp - 0x438], eax
test edi, edi
mov eax, esi
cmovne eax, edi
push eax
call fcn.0048faa4
mov dword [ebp - 0x434], eax
test edi, edi
mov eax, esi
cmovne eax, edi
push eax
call fcn.0048faa4
mov dword [ebp - 0x430], eax
lea eax, [ebp - 0x43c]
mov byte [ebp - 4], 0x19
push eax
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0x454]
lea eax, [ebp - 0x428]
push eax
call fcn.00407620
add esp, 0x4c
mov esi, eax
lea eax, [ebp - 0x438]
mov byte [ebp - 4], 0x1a
push eax
lea eax, [ebp - 0x434]
push eax
push dword [ebp - 0x454]
lea eax, [ebp - 0x42c]
push eax
call fcn.00407620
lea ecx, [ebp - 0x484]
mov byte [ebp - 4], 0x1b
push ecx
lea ecx, [ebp - 0x45c]
push ecx
lea ecx, [ebp - 0x450]
push ecx
lea ecx, [ebp - 0x44c]
push ecx
push esi
push eax
lea eax, [ebp - 0x430]
push eax
push dword [ebp - 0x468]
call fcn.00403c00
push dword [ebp - 0x42c]
mov byte [ebp - 0x421], al
call fcn.0048faf7
push dword [ebp - 0x428]
call fcn.0048faf7
push dword [ebp - 0x430]
call fcn.0048faf7
push dword [ebp - 0x434]
call fcn.0048faf7
add esp, 0x40
push dword [ebp - 0x438]
call fcn.0048faf7
push dword [ebp - 0x444]
call fcn.0048faf7
push dword [ebp - 0x43c]
mov byte [ebp - 4], 0x14
call fcn.0048faf7
add esp, 0xc
cmp byte [ebp - 0x421], 0
je 0x415a0b
cmp dword [ebp + 0x14], 0xffffffff
jne 0x4158e7
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x42c], eax
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x428], eax
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x440], eax
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x448], eax
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x444], eax
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x438], eax
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x434], eax
mov esi, 0x4af9b8
test edi, edi
mov eax, esi
cmovne eax, edi
push eax
call fcn.0048faa4
mov dword [ebp - 0x430], eax
mov ecx, dword [ebp - 0x470]
mov eax, esi
test ecx, ecx
cmovne eax, ecx
push eax
call fcn.0048faa4
mov dword [ebp - 0x43c], eax
lea eax, [ebp - 0x434]
mov byte [ebp - 4], 0x24
push eax
lea eax, [ebp - 0x430]
push eax
push dword [ebp - 0x454]
lea eax, [ebp - 0x46c]
push eax
call fcn.00407620
push 0xffffffffffffffff
push 0
push 0
lea ecx, [ebp - 0x42c]
mov byte [ebp - 4], 0x25
push ecx
push 1
push 0
lea ecx, [ebp - 0x428]
push ecx
lea ecx, [ebp - 0x440]
push ecx
lea ecx, [ebp - 0x448]
push ecx
lea ecx, [ebp - 0x444]
push ecx
lea ecx, [ebp - 0x438]
push ecx
push eax
lea eax, [ebp - 0x43c]
push eax
push 0
push 0xffffffffffffffff
push 0
push dword [ebp - 0x468]
call fcn.00403eb0
add esp, 0x78
push dword [ebp - 0x46c]
mov dword [ebp + 0x14], eax
call fcn.0048faf7
push dword [ebp - 0x43c]
call fcn.0048faf7
push dword [ebp - 0x430]
call fcn.0048faf7
push dword [ebp - 0x434]
call fcn.0048faf7
push dword [ebp - 0x438]
call fcn.0048faf7
push dword [ebp - 0x444]
call fcn.0048faf7
push dword [ebp - 0x448]
call fcn.0048faf7
push dword [ebp - 0x440]
call fcn.0048faf7
push dword [ebp - 0x428]
call fcn.0048faf7
push dword [ebp - 0x42c]
call fcn.0048faf7
add esp, 0x28
jmp 0x4158ec
mov esi, 0x4af9b8
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x43c], eax
lea eax, [ebp - 0x218]
push eax
call fcn.0048faa4
mov dword [ebp - 0x448], eax
push 0x4af9b8
call fcn.0048faa4
mov dword [ebp - 0x440], eax
test edi, edi
mov eax, esi
cmovne eax, edi
push eax
call fcn.0048faa4
mov dword [ebp - 0x428], eax
test edi, edi
cmovne esi, edi
push esi
call fcn.0048faa4
mov dword [ebp - 0x42c], eax
lea eax, [ebp - 0x440]
mov byte [ebp - 4], 0x2a
push eax
lea eax, [ebp - 0x428]
push eax
push dword [ebp - 0x454]
lea eax, [ebp - 0x470]
push eax
call fcn.00407620
push 0xffffffffffffffff
push 0
push 0
lea ecx, [ebp - 0x43c]
mov byte [ebp - 4], 0x2b
push ecx
movzx ecx, byte [ebp + 0x18]
push ecx
push dword [ebp - 0x484]
lea ecx, [ebp - 0x448]
push ecx
lea ecx, [ebp - 0x45c]
push ecx
lea ecx, [ebp - 0x458]
push ecx
lea ecx, [ebp - 0x450]
push ecx
lea ecx, [ebp - 0x44c]
push ecx
push eax
lea eax, [ebp - 0x42c]
push eax
push 3
push dword [ebp + 0x14]
push dword [ebp - 0x480]
push dword [ebp - 0x468]
call fcn.00403eb0
add esp, 0x68
push dword [ebp - 0x470]
call fcn.0048faf7
push dword [ebp - 0x42c]
call fcn.0048faf7
push dword [ebp - 0x428]
call fcn.0048faf7
push dword [ebp - 0x440]
call fcn.0048faf7
push dword [ebp - 0x448]
call fcn.0048faf7
push dword [ebp - 0x43c]
call fcn.0048faf7
add esp, 0x18
push dword [ebp - 0x44c]
call fcn.0048faf7
add esp, 4
lea ecx, [ebp - 0x494]
call fcn.00402130
push dword [ebp - 0x45c]
call fcn.0048faf7
push dword [ebp - 0x458]
call fcn.0048faf7
push dword [ebp - 0x450]
call fcn.0048faf7
add esp, 0xc
push dword [ebp - 0x478]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push dword [ebp - 0x474]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push dword [ebp - 0x460]
call fcn.0048faf7
add esp, 4
push ebx
call fcn.0048faf7
mov eax, dword [ebp + 0x14]
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0048fc6c
mov esp, ebp
pop ebp
ret