Function at 0x10130da0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x58
mov eax, dword [0x101d2014]
xor esi, esi
xor eax, ebp
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x44], esi
mov dword [ebp - 0x48], esi
push 0x800
call sym.nss3.dll_PORT_NewArena_Util
add esp, 4
test eax, eax
je 0x10130e0a
mov edi, eax
call sym.nss3.dll_PK11_GetInternalKeySlot
xor ebx, ebx
mov dword [ebp - 0x58], eax
dec ebx
test eax, eax
je 0x1013102b
mov dword [ebp - 0x50], edi
mov edi, dword [ebp + 0x14]
push edi
push 1
push eax
call sym.nss3.dll_PK11_Authenticate
add esp, 0xc
test eax, eax
je 0x10130e20
mov dword [ebp - 0x54], 0
xor esi, esi
mov ebx, eax
mov edi, dword [ebp - 0x50]
jmp 0x10131032
lea eax, [ebp - 0x4c]
push 0
push eax
call sym.nss3.dll_SECITEM_FreeItem_Util
add esp, 8
xor ebx, ebx
dec ebx
jmp 0x10131082
mov eax, dword [ebp + 8]
cmp dword [eax + 8], 0
je 0x10130e43
push edi
mov dword [ebp - 0x5c], eax
push eax
push 0x133
push dword [ebp - 0x58]
call fcn.10131cc0
add esp, 0x10
jmp 0x10130ecf
mov esi, dword [0x101d59cc]
test esi, esi
je 0x10130e74
push dword [0x101d4d30]
call dword [sym.imp.kernel32.dll_TlsGetValue]
test eax, eax
mov dword [ebp - 0x54], eax
je 0x1013109d
lea eax, [esi + 0x1c]
push eax
call dword [sym.imp.kernel32.dll_EnterCriticalSection]
mov eax, dword [ebp - 0x54]
mov dword [esi + 8], eax
push edi
push 0x101d40f8
push 0x133
push dword [ebp - 0x58]
call fcn.10131cc0
add esp, 0x10
test eax, eax
jne 0x10130eb1
xor eax, eax
push edi
push 5
push 0x900
push 0x101d40f8
push eax
push 0xffffffffffffffff
push eax
push 0x133
push dword [ebp - 0x58]
call fcn.10132570
add esp, 0x24
mov ecx, dword [0x101d59cc]
mov dword [ebp - 0x5c], 0x101d40f8
test ecx, ecx
je 0x10130ecf
push ecx
mov esi, eax
call sym.nss3.dll_PR_Unlock
mov eax, esi
add esp, 4
mov edi, dword [ebp - 0x50]
xor esi, esi
test eax, eax
je 0x1013102b
push eax
mov dword [ebp - 0x54], eax
call fcn.10131fa0
add esp, 4
push eax
push 0x133
call fcn.101245f0
add esp, 8
test eax, eax
je 0x10130e02
mov edi, eax
push eax
push dword [ebp - 0x54]
push 0x104
push 0x133
call sym.nss3.dll_PK11_CreateContextBySymKey
add esp, 0x10
test eax, eax
je 0x10131096
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x64], eax
push 0
push 0x133
call sym.nss3.dll_PK11_GetBlockSize
add esp, 8
mov ebx, dword [esi + 8]
mov ecx, eax
xor edx, edx
mov eax, ebx
div ecx
sub ecx, edx
add ebx, ecx
mov dword [ebp - 0x60], ecx
mov dword [ebp - 0x44], ebx
push ebx
call sym.nss3.dll_PORT_Alloc_Util
add esp, 4
mov esi, eax
mov dword [ebp - 0x48], eax
mov eax, dword [ebp + 0xc]
push dword [eax + 8]
push dword [eax + 4]
push esi
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 8]
cmp eax, ebx
jae 0x10130f83
mov ecx, dword [ebp - 0x60]
mov byte [esi + eax], cl
inc eax
mov ebx, dword [ebp - 0x44]
mov esi, dword [ebp - 0x48]
cmp eax, ebx
jb 0x10130f75
lea eax, [ebp - 0x14]
mov dword [eax], ebx
push ebx
push dword [ebp - 0x50]
call sym.nss3.dll_PORT_ArenaAlloc_Util
add esp, 8
lea ecx, [ebp - 0x14]
mov dword [ecx - 4], eax
push ebx
push esi
push ebx
push ecx
push eax
mov esi, dword [ebp - 0x64]
push esi
call sym.nss3.dll_PK11_CipherOp
add esp, 0x18
mov ebx, eax
test eax, eax
jne 0x10130fff
push esi
call fcn.10115490
add esp, 4
mov ecx, dword [ebp - 0x5c]
lea eax, [ebp - 0x34]
movsd xmm0, qword [ecx]
movsd qword [eax - 0xc], xmm0
mov ecx, dword [ecx + 8]
mov dword [eax - 4], ecx
push eax
push dword [ebp - 0x50]
push edi
push 7
call fcn.101249b0
add esp, 0x10
mov ebx, eax
test eax, eax
jne 0x10130fff
lea eax, [ebp - 0x40]
push 0x101d4104
push eax
push dword [ebp + 0x10]
push 0
call sym.nss3.dll_SEC_ASN1EncodeItem_Util
add esp, 0x10
cmp eax, 1
sbb ebx, ebx
lea eax, [ebp - 0x4c]
push 0
push eax
call sym.nss3.dll_SECITEM_FreeItem_Util
add esp, 8
xor eax, eax
inc eax
push eax
push dword [ebp - 0x50]
call sym.nss3.dll_PORT_FreeArena_Util
add esp, 8
xor eax, eax
inc eax
push eax
push esi
call sym.nss3.dll_PK11_DestroyContext
add esp, 8
jmp 0x1013104d
mov dword [ebp - 0x54], 0
lea eax, [ebp - 0x4c]
push 0
push eax
call sym.nss3.dll_SECITEM_FreeItem_Util
add esp, 8
push 1
push edi
call sym.nss3.dll_PORT_FreeArena_Util
add esp, 8
mov edi, esi
test edi, edi
je 0x1013105c
push 1
push edi
call sym.nss3.dll_SECITEM_FreeItem_Util
add esp, 8
mov eax, dword [ebp - 0x54]
test eax, eax
je 0x1013106c
push eax
call sym.nss3.dll_PK11_FreeSymKey
add esp, 4
mov eax, dword [ebp - 0x58]
test eax, eax
je 0x10131082
lock dec dword [eax + 0x48]
jne 0x10131082
push eax
call fcn.10135de0
add esp, 4
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.10192ef0
mov eax, ebx
add esp, 0x58
pop esi
pop edi
pop ebx
pop ebp
ret
mov esi, edi
jmp 0x10130e02
xor eax, eax
push eax
push eax
push 1
push eax
call fcn.100e2c70
add esp, 0x10
mov dword [ebp - 0x54], eax
jmp 0x10130e64