Function at 0x4b9600
Capabilities:
Allocate thread local storage
Check os version
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x160
mov eax, dword [0x5ac004]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
push 0x118
mov dword [0x5b1d78], eax
lea eax, [ebp - 0x128]
push 0
push eax
mov dword [0x5b1d7c], 0x56fb6c
call fcn.0051fd40
add esp, 0xc
mov dword [ebp - 0x12c], 0x11c
lea eax, [ebp - 0x12c]
push eax
call dword [sym.imp.ntdll.dll_RtlGetVersion]
test eax, eax
js 0x4b97b7
mov eax, dword [ebp - 0x128]
lea esi, [ebp - 0x12c]
mov ecx, 0x47
mov edi, sym.ProcessHacker.exe_PhOsVersion
rep movsd dword es:[edi], dword [esi]
cmp eax, 6
jne 0x4b96c5
mov eax, dword [ebp - 0x124]
cmp eax, 1
jne 0x4b9694
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x3d
jmp 0x4b97c1
cmp eax, 2
jne 0x4b96a8
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x3e
jmp 0x4b97c1
cmp eax, 3
jne 0x4b97b7
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x3f
jmp 0x4b96c0
jmp 0x4b97c1
cmp eax, 0xa
jne 0x4b97b7
cmp dword [ebp - 0x124], 0
jne 0x4b97b7
mov eax, dword [ebp - 0x120]
cmp eax, 0x4a62
jb 0x4b96f7
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x6e
jmp 0x4b97c1
cmp eax, 0x4a61
jb 0x4b970d
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x6d
jmp 0x4b97c1
cmp eax, 0x47bb
jb 0x4b9725
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x6c
mov edi, edi
jmp 0x4b97c1
cmp eax, 0x47ba
jb 0x4b973b
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x6b
jmp 0x4b97c1
jmp 0x4b9740
cmp eax, 0x4563
jb 0x4b9753
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x6a
jmp 0x4b97c1
cmp eax, 0x42ee
jb 0x4b9766
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x69
jmp 0x4b97c1
cmp eax, 0x3fab
jb 0x4b9779
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x68
jmp 0x4b97c1
lea esp, [esp]
cmp eax, 0x3ad7
jb 0x4b9793
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x67
jmp 0x4b97c1
cmp eax, 0x3839
jb 0x4b97a6
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0x66
jmp 0x4b97c1
cmp eax, 0x295a
sbb eax, eax
add eax, 0x65
mov dword [sym.ProcessHacker.exe_WindowsVersion], eax
jmp 0x4b97c1
mov dword [sym.ProcessHacker.exe_WindowsVersion], 0xffffffff
push 0
push 0x2c
push sym.ProcessHacker.exe_PhSystemBasicInformation
push 0
call dword [sym.imp.ntdll.dll_NtQuerySystemInformation]
cmp dword [sym.ProcessHacker.exe_WindowsVersion], 0x3e
jb 0x4b97f7
push 0
push 0
push 0
push 0
push 0
push 0x1102
call dword [sym.imp.ntdll.dll_RtlCreateHeap]
mov dword [0x5b1dac], eax
jmp 0x4b97fc
mov eax, dword [0x5b1dac]
lea esp, [esp]
test eax, eax
jne 0x4b984e
push eax
push eax
push 0x100000
push 0x200000
push eax
push 0x1002
call dword [sym.imp.ntdll.dll_RtlCreateHeap]
mov dword [0x5b1dac], eax
test eax, eax
je 0x4b99db
cmp dword [sym.ProcessHacker.exe_WindowsVersion], 0x3c
jb 0x4b984e
push 4
lea ecx, [ebp - 0x130]
mov dword [ebp - 0x130], 2
push ecx
push 0
push eax
call dword [sym.imp.ntdll.dll_RtlSetHeapInformation]
push 0
push 0
push 0xf0003
push 0x5b38f8
call dword [sym.imp.ntdll.dll_NtCreateKeyedEvent]
test eax, eax
js 0x4b99db
mov al, 1
cmp al, byte [0x5b1da8]
push 0x5b4458
sbb eax, eax
and eax, 0xfa0
mov dword [0x5aff84], eax
call dword [sym.imp.ntdll.dll_RtlInitializeSListHead]
push 0x5b4440
call dword [sym.imp.ntdll.dll_RtlInitializeSListHead]
xor eax, eax
mov dword [0x5b4448], 0
mov dword [ebp - 0x15c], eax
mov dword [ebp - 0x158], eax
mov dword [ebp - 0x154], eax
mov dword [ebp - 0x150], eax
mov dword [ebp - 0x14c], eax
mov dword [ebp - 0x148], eax
mov dword [ebp - 0x144], eax
mov dword [ebp - 0x140], eax
mov dword [ebp - 0x13c], eax
mov dword [ebp - 0x138], eax
lea eax, [ebp - 0x15c]
push eax
push 0x28
mov dword [0x5b444c], 0x200
mov dword [0x5b4450], 0x38
mov dword [0x5b1d58], eax
mov dword [0x5b4040], eax
call sym.ProcessHacker.exe_PhCreateObject
mov ecx, eax
mov ebx, 1
xor eax, eax
mov word [ecx], ax
mov eax, ebx
lock xadd dword [0x5b1d60], eax
inc eax
dec al
mov dword [ecx + 4], 0
movzx edx, al
mov byte [ecx + 2], al
mov dword [ecx + 8], 0
mov dword [ecx + 0xc], str.Type
cmp edx, 0x100
jae 0x4b99d0
push ecx
movzx eax, al
push 0x28
mov dword [edx*4 + 0x5b4040], ecx
mov dword [0x5b1d58], ecx
mov word [ecx - 8], ax
mov dword [ecx + 4], ebx
call sym.ProcessHacker.exe_PhCreateObject
xor ecx, ecx
mov word [eax], cx
lock xadd dword [0x5b1d60], ebx
inc ebx
dec bl
mov dword [eax + 4], ecx
mov dword [eax + 8], ecx
movzx ecx, bl
mov byte [eax + 2], bl
mov dword [eax + 0xc], 0x57e8fc
cmp ecx, 0x100
jae 0x4b99d0
mov dword [ecx*4 + 0x5b4040], eax
mov dword [0x5b1d5c], eax
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x5b3864], eax
cmp eax, 0xffffffff
je 0x4b99db
call fcn.004b3da0
test al, al
je 0x4b99db
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0051e068
mov esp, ebp
pop ebp
ret 0xc
push 0xc0000001
call dword [sym.imp.ntdll.dll_RtlRaiseStatus]
mov ecx, dword [ebp - 8]
mov eax, 0xc0000001
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0051e068
mov esp, ebp
pop ebp
ret 0xc