Function at 0x1013d830
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x1c
mov edi, dword [ebp + 0x14]
test edi, edi
je 0x1013d8ce
cmp dword [edi + 4], 0
je 0x1013d8ce
mov eax, dword [edi + 8]
test eax, eax
je 0x1013d8ce
cmp eax, 0x3fffffff
ja 0x1013d8ce
add eax, 2
mov ecx, 0xaaaaaaab
mul ecx
mov eax, edx
shr edx, 5
mov ecx, edx
shr eax, 1
lea esi, [edx + edx - 2]
shl ecx, 4
sub eax, ecx
lea ecx, [edx + edx]
test eax, eax
cmovne esi, ecx
shl edx, 6
lea ecx, [edx + eax*4]
add ecx, esi
je 0x1013d8ce
mov eax, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
test eax, eax
mov dword [ebp - 0x24], ebx
je 0x1013d908
push eax
mov dword [ebp - 0x14], ecx
call sym.nss3.dll_PORT_ArenaMark_Util
add esp, 4
mov esi, eax
mov eax, dword [ebp - 0x14]
or eax, 1
test ebx, ebx
jne 0x1013d913
push eax
push dword [ebp + 8]
call sym.nss3.dll_PORT_ArenaAlloc_Util
add esp, 8
test eax, eax
mov dword [ebp - 0x24], eax
je 0x1013da39
mov edx, dword [ebp - 0x14]
jmp 0x1013d95a
cmp dword [0x101d4d40], 0
je 0x1013dd27
push dword [0x101d4d30]
call dword [sym.imp.kernel32.dll_TlsGetValue]
test eax, eax
je 0x1013dcc3
mov dword [eax + 0x28], 0xffffe005
xor esi, esi
mov dword [eax + 0x2c], esi
mov dword [eax + 0x30], esi
mov eax, esi
add esp, 0x1c
pop esi
pop edi
pop ebx
pop ebp
ret
mov eax, ecx
xor esi, esi
or eax, 1
test ebx, ebx
je 0x1013d944
mov edx, dword [ebp + 0x10]
cmp eax, edx
jbe 0x1013d95a
cmp dword [0x101d4d40], 0
je 0x1013dd31
push dword [0x101d4d30]
call dword [sym.imp.kernel32.dll_TlsGetValue]
test eax, eax
je 0x1013dcd7
mov dword [eax + 0x28], 0xffffe003
jmp 0x1013d8f6
push eax
mov esi, ecx
call sym.nss3.dll_PORT_Alloc_Util
mov edx, esi
add esp, 4
xor esi, esi
test eax, eax
mov dword [ebp - 0x24], eax
je 0x1013d8fe
mov eax, dword [edi + 8]
test eax, eax
je 0x1013da2b
cmp eax, 0x3fffffff
mov dword [ebp - 0x10], eax
ja 0x1013d9d8
mov eax, dword [ebp - 0x10]
mov ecx, 0xaaaaaaab
mov dword [ebp - 0x14], edx
add eax, 2
mul ecx
mov eax, edx
shr edx, 5
mov ecx, edx
shr eax, 1
lea ebx, [edx + edx - 2]
shl ecx, 4
sub eax, ecx
lea ecx, [edx + edx]
test eax, eax
cmovne ebx, ecx
mov ecx, dword [ebp - 0x14]
shl edx, 6
lea eax, [edx + eax*4]
add eax, ebx
je 0x1013d9d8
cmp eax, ecx
jbe 0x1013da4f
cmp dword [0x101d4d40], 0
je 0x1013dd45
push dword [0x101d4d30]
call dword [sym.imp.kernel32.dll_TlsGetValue]
test eax, eax
je 0x1013dcff
mov dword [eax + 0x28], 0xffffe8b6
jmp 0x1013da00
cmp dword [0x101d4d40], 0
je 0x1013dd3b
push dword [0x101d4d30]
call dword [sym.imp.kernel32.dll_TlsGetValue]
test eax, eax
je 0x1013dceb
mov dword [eax + 0x28], 0xffffe005
xor ecx, ecx
mov dword [eax + 0x2c], ecx
mov dword [eax + 0x30], ecx
mov ecx, dword [ebp + 8]
test ecx, ecx
jne 0x1013da3c
mov eax, dword [ebp - 0x24]
xor esi, esi
test eax, eax
je 0x1013d8fe
push eax
call dword [sym.imp.mozglue.dll_free]
add esp, 4
jmp 0x1013d8fe
xor ebx, ebx
mov esi, dword [ebp - 0x24]
mov byte [esi + ebx], 0
jmp 0x1013d8fe
mov ecx, dword [ebp + 8]
mov edx, esi
push 0
call fcn.10146c70
add esp, 4
xor esi, esi
jmp 0x1013d8fe
mov edi, dword [edi + 4]
push 0x24
push 1
call dword [sym.imp.mozglue.dll_calloc]
add esp, 8
test eax, eax
je 0x1013da08
mov edx, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x14]
mov ebx, eax
mov dword [eax + 8], 0x40
mov dword [ebp - 0x18], ebx
mov dword [ebx + 0x18], edx
mov dword [ebx + 0x1c], ecx
mov ecx, dword [ebp - 0x10]
cmp ecx, 2
ja 0x1013da99
mov al, byte [edi]
cmp ecx, 2
mov byte [ebx], al
jne 0x1013dad9
mov al, byte [edi + 1]
mov byte [ebx + 1], al
mov eax, 2
jmp 0x1013dadc
lea eax, [edi + ecx]
mov edx, 0xaaaaaaab
mov dword [ebp - 0x1c], eax
mov eax, ecx
mul edx
shr edx, 1
lea eax, [edx + edx*2]
mov dword [ebp - 0x20], eax
mov eax, ecx
sub eax, dword [ebp - 0x20]
je 0x1013dae4
mov edx, ecx
sub edx, eax
cmp eax, 1
mov cl, byte [edi + edx]
mov byte [ebx], cl
je 0x1013dacc
mov cl, byte [edx + edi + 1]
mov byte [ebx + 1], cl
mov ecx, dword [ebp - 0x1c]
mov dword [ebx + 4], eax
sub ecx, eax
mov eax, dword [ebp - 0x14]
jmp 0x1013daea
xor eax, eax
inc eax
mov dword [ebx + 4], eax
jmp 0x1013dc40
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x1c]
cmp ecx, edi
jbe 0x1013dc40
mov edx, dword [ebp - 0x24]
add eax, 0xfffffffd
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], edx
xor eax, eax
mov ebx, 0xfffffffd
movzx ecx, byte [edi + ebx + 3]
mov edx, eax
shl eax, 8
or eax, ecx
inc ebx
jne 0x1013db08
mov ebx, dword [ebp - 0x18]
mov dword [ebp - 0x20], edi
mov ebx, dword [ebx + 8]
test ebx, ebx
je 0x1013db60
mov dword [ebp - 0x28], ebx
mov ebx, dword [ebp - 0x18]
mov ebx, dword [ebx + 0xc]
cmp ebx, dword [ebp - 0x28]
jb 0x1013db57
mov ebx, dword [ebp - 0x18]
mov dword [ebx + 0xc], 0
mov ebx, dword [ebp - 0x10]
mov word [ebx], 0xa0d
add ebx, 2
mov dword [ebp - 0x10], ebx
mov ebx, dword [ebp - 0x18]
add dword [ebx + 0x20], 2
mov ebx, dword [ebp - 0x18]
mov ebx, dword [ebx + 0xc]
mov edi, dword [ebp - 0x18]
add ebx, 4
mov dword [edi + 0xc], ebx
mov ebx, edx
shr edx, 4
shr eax, 6
mov edi, dword [ebp - 0x10]
and ecx, 0x3f
add dword [ebp - 0x20], 3
shr ebx, 0xa
and edx, 0x3f
and eax, 0x3f
and ebx, 0x3f
mov dl, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_OID.]
mov al, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_OID.]
mov bl, byte [ebx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_OID.]
mov byte [edi], bl
mov byte [edi + 1], dl
mov byte [edi + 2], al
mov al, byte [ecx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_OID.]
mov ebx, dword [ebp - 0x18]
mov byte [edi + 3], al
mov eax, dword [ebp - 0x14]
add edi, 4
mov edx, dword [ebx + 0x20]
mov dword [ebp - 0x10], edi
add edx, 4
cmp edx, eax
mov dword [ebx + 0x20], edx
jb 0x1013dbf1
mov ecx, dword [ebx + 0x10]
test ecx, ecx
je 0x1013dc01
mov eax, dword [ebx + 0x14]
mov edi, dword [ebx + 0x18]
mov dword [ebp - 0x10], edx
mov dword [ebp - 0x28], eax
call dword [section..00cfg]
push dword [ebp - 0x10]
mov dword [ebp - 0x10], edi
push edi
push dword [ebp - 0x28]
call ecx
add esp, 0xc
test eax, eax
js 0x1013dcbe
mov dword [ebx + 0x20], 0
mov ecx, dword [ebp - 0x1c]
mov edi, dword [ebp - 0x20]
cmp edi, ecx
jb 0x1013db01
jmp 0x1013dc40
mov ecx, dword [ebp - 0x1c]
mov edi, dword [ebp - 0x20]
cmp edi, ecx
jae 0x1013dbf7
cmp dword [0x101d4d40], 0
je 0x1013dd4f
push dword [0x101d4d30]
call dword [sym.imp.kernel32.dll_TlsGetValue]
test eax, eax
je 0x1013dd13
mov ebx, dword [ebp - 0x18]
xor ecx, ecx
mov dword [eax + 0x28], 0xffffe8b6
mov dword [eax + 0x2c], ecx
mov dword [eax + 0x30], ecx
jmp 0x1013dc4b
mov ecx, ebx
call fcn.1013dd80
test eax, eax
je 0x1013dc6b
mov eax, dword [ebx + 0x18]
test eax, eax
je 0x1013dc5c
push eax
call dword [sym.imp.mozglue.dll_free]
add esp, 4
push ebx
call dword [sym.imp.mozglue.dll_free]
add esp, 4
jmp 0x1013da08
mov eax, dword [ebx + 0x18]
mov edi, ebx
mov ebx, dword [ebx + 0x20]
mov ecx, edi
mov dword [edi + 0x18], 0
mov dword [ebp - 0x10], eax
call fcn.1013dd80
mov dword [ebp - 0x14], eax
mov eax, dword [edi + 0x18]
test eax, eax
je 0x1013dc98
push eax
call dword [sym.imp.mozglue.dll_free]
add esp, 4
push dword [ebp - 0x18]
call dword [sym.imp.mozglue.dll_free]
add esp, 4
cmp dword [ebp - 0x14], 0xffffffff
je 0x1013dcb9
cmp dword [ebp - 0x10], 0
jne 0x1013da2d
jmp 0x1013da08
push dword [ebp - 0x10]
jmp 0x1013dc5d
mov eax, dword [ebp - 0x10]
jmp 0x1013dc4e
xor eax, eax
push eax
push eax
push 1
push eax
call fcn.100e2c70
add esp, 0x10
jmp 0x1013d8ef
xor eax, eax
push eax
push eax
push 1
push eax
call fcn.100e2c70
add esp, 0x10
jmp 0x1013d93b
xor eax, eax
push eax
push eax
push 1
push eax
call fcn.100e2c70
add esp, 0x10
jmp 0x1013d9f9
xor eax, eax
push eax
push eax
push 1
push eax
call fcn.100e2c70
add esp, 0x10
jmp 0x1013d9cf
xor eax, eax
push eax
push eax
push 1
push eax
call fcn.100e2c70
add esp, 0x10
jmp 0x1013dc2c
call sym.nss3.dll_PR_Init
jmp 0x1013d8db
call sym.nss3.dll_PR_Init
jmp 0x1013d927
call sym.nss3.dll_PR_Init
jmp 0x1013d9e5
call sym.nss3.dll_PR_Init
jmp 0x1013d9bb
call sym.nss3.dll_PR_Init
jmp 0x1013dc18