Function at 0x540b65
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x1f8
and dword [esp + 0x5c], 0
mov word [esp + 0x74], 0x401
mov dword [esp + 0x64], 4
and dword [esp + 0x6c], 0
and dword [esp + 0x68], 0
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x70], 0x10000
sub esp, 8
and dword [esp + 4], 0
and dword [esp], 0
push 0xa
pop ecx
xor edx, edx
xor ebx, ebx
call fcn.00541302
pop ecx
pop edx
test al, al
jne 0x540ccb
mov eax, dword [0x64fd94]
cmp eax, 2
push 0x1a
pop esi
jb 0x540c18
lea ecx, [esp + 0x80]
mov eax, str.velopack::shared::download
lea edi, [esp + 0x148]
mov dword [ecx], str.DANGER:_Discontinued_OS_version._TLS_certificate_verification_will_be_disabled.
mov dword [ecx + 4], 1
and dword [ecx + 0x10], 0
mov dword [ecx + 8], str.assertion_failed:_mid___self.len__chunk_size_must_be_non_zero
and dword [ecx + 0xc], 0
mov dword [edi], eax
mov dword [edi + 4], esi
mov dword [edi + 8], eax
mov dword [edi + 0xc], esi
mov dword [edi + 0x10], 0x6378c4
push 2
pop edx
push edi
call fcn.0045db8c
pop eax
mov eax, dword [0x64fd94]
cmp eax, 2
jb 0x540c6d
lea ecx, [esp + 0x80]
mov eax, str.velopack::shared::download
lea edi, [esp + 0x148]
mov dword [ecx], str.DANGER:_Discontinued_OS_version._TLS_certificate_verification_will_be_disabled.
mov dword [ecx + 4], 1
and dword [ecx + 0x10], 0
mov dword [ecx + 8], str.assertion_failed:_mid___self.len__chunk_size_must_be_non_zero
and dword [ecx + 0xc], 0
mov dword [edi], eax
mov dword [edi + 4], esi
mov dword [edi + 8], eax
mov dword [edi + 0xc], esi
mov dword [edi + 0x10], 0x6378d4
push 2
pop edx
push edi
call fcn.0045db8c
pop eax
mov eax, dword [0x64fd94]
cmp eax, 1
jbe 0x540cc2
lea ecx, [esp + 0x80]
mov eax, str.velopack::shared::download
lea edi, [esp + 0x148]
mov dword [ecx], str.DANGER:_Discontinued_OS_version._TLS_certificate_verification_will_be_disabled.
mov dword [ecx + 4], 1
and dword [ecx + 0x10], 0
mov dword [ecx + 8], str.assertion_failed:_mid___self.len__chunk_size_must_be_non_zero
and dword [ecx + 0xc], 0
mov dword [edi], eax
mov dword [edi + 4], esi
mov dword [edi + 8], eax
mov dword [edi + 0xc], esi
mov dword [edi + 0x10], 0x6378e4
push 2
pop edx
push edi
call fcn.0045db8c
pop eax
mov word [esp + 0x70], 0x101
mov bl, 1
push 0
push 0
push 0
push 0
push 2
call dword [sym.imp.crypt32.dll_CertOpenStore]
test eax, eax
je 0x540e80
movzx esi, bl
mov dword [esp + 8], eax
lea edx, [esp + 0x148]
lea ecx, [esp + 0x30]
lea ebx, [esp + 0xf4]
mov eax, esi
shl esi, 0x10
mov dword [edx], 0x62fd8c
shl eax, 8
or esi, eax
xor eax, eax
inc eax
mov dword [edx + 4], eax
and dword [edx + 0x10], 0
mov dword [edx + 8], ecx
and dword [edx + 0xc], 0
mov ecx, ebx
or esi, eax
call fcn.004ba4b9
push 8
pop ecx
push 4
pop edx
call fcn.004b8ae6
mov edi, eax
xor eax, eax
inc eax
mov dword [edi + 4], eax
mov dword [edi], eax
push 8
pop ecx
push 4
pop edx
call fcn.004b8ae6
xor ecx, ecx
inc ecx
mov dword [eax + 4], ecx
mov dword [eax], ecx
mov edx, ecx
mov ecx, 0x3b9aca00
mov dword [ebx - 0x74], 0x1e
and dword [ebx - 0x70], 0
and dword [ebx - 0x6c], 0
mov dword [ebx - 0x5c], ecx
mov dword [ebx - 0x4c], ecx
mov dword [ebx - 0x3c], ecx
xor ecx, ecx
mov dword [ebx - 0x34], edi
mov dword [ebx - 0x30], 0x6318f4
mov byte [ebx - 4], 4
mov dword [ebx + 0xc], 5
mov word [ebx + 0x10], 0x100
mov byte [ebx + 0x12], cl
mov byte [ebx + 0x30], cl
mov dword [ebx + 0x28], 0x64
mov dword [ebx + 0x2c], edx
mov dword [ebx + 0x14], eax
mov dword [ebx + 0x18], 0x6309c4
mov dword [ebx + 0x1c], 4
and dword [ebx + 0x20], 0
and dword [ebx + 0x24], 0
push 0x1c
pop ecx
push 4
pop edx
call fcn.004b8ae6
mov ecx, dword [esp + 8]
mov ebx, eax
xor eax, eax
inc eax
mov dword [ebx], eax
mov dword [ebx + 4], eax
and dword [ebx + 8], 0
and dword [ebx + 0xc], 0
mov dword [ebx + 0x10], ecx
mov dword [ebx + 0x14], esi
mov dword [ebx + 0x18], 0x401
lock dec dword [edi]
jne 0x540df2
lea ecx, [esp + 0xc0]
call fcn.004fe17b
lea eax, [esp + 0x80]
mov dword [eax + 0x40], ebx
mov dword [eax + 0x44], 0x634010
push 0xa8
push eax
lea eax, [esp + 0x150]
push eax
call fcn.00570db0
add esp, 0xc
cmp byte [esp + 0x1b8], 4
mov ebx, 1
jne 0x5410bd
cmp byte [esp + 0x1ec], 0
je 0x5410bd
lea esi, [esp + 0xc]
mov edx, 0x63070e
mov ecx, esi
push 9
call fcn.004e5b90
pop eax
cmp byte [esi + 0xc], 3
jne 0x540ee2
lea esi, [esp + 0x80]
lea edx, [esp + 0xc]
mov ecx, esi
call fcn.005080ee
cmp dword [esi], 3
je 0x541043
lea ecx, [esp + 0x80]
call fcn.00508709
jmp 0x540eeb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
lea edi, [esp + 0x80]
push edi
call fcn.004e3f50
pop eax
push 0x24
pop ecx
push 4
pop edx
call fcn.004b8ae6
mov dword [eax], 0x6354d0
lea ecx, [esp + 0x5c]
movsd xmm0, qword [edi]
movsd xmm1, qword [edi + 8]
movsd qword [eax + 4], xmm0
movsd qword [eax + 0xc], xmm1
movsd xmm0, qword [edi + 0x10]
mov edi, dword [esp + 0x1c]
movsd qword [eax + 0x14], xmm0
and dword [eax + 0x1c], 0
mov dword [eax + 0x20], esi
mov dword [edi + 4], eax
call fcn.005412c3
xor esi, esi
jmp 0x54122f
lea ecx, [esp + 0xc]
call fcn.0050871e
lea esi, [esp + 0xc]
mov edx, 0x630717
mov ecx, esi
push 9
call fcn.004e5b90
pop eax
cmp byte [esi + 0xc], 3
jne 0x540f2d
lea esi, [esp + 0x80]
lea edx, [esp + 0xc]
mov ecx, esi
call fcn.005080ee
cmp dword [esi], 3
je 0x541043
lea ecx, [esp + 0x80]
call fcn.00508709
jmp 0x540f36
lea ecx, [esp + 0xc]
call fcn.0050871e
lea esi, [esp + 0xc]
mov edx, 0x630720
mov ecx, esi
push 0xb
call fcn.004e5b90
pop eax
cmp byte [esi + 0xc], 3
jne 0x540f78
lea esi, [esp + 0x80]
lea edx, [esp + 0xc]
mov ecx, esi
call fcn.005080ee
cmp dword [esi], 3
je 0x541043
lea ecx, [esp + 0x80]
call fcn.00508709
jmp 0x540f81
lea ecx, [esp + 0xc]
call fcn.0050871e
lea esi, [esp + 0xc]
mov edx, 0x63072b
mov ecx, esi
push 0xb
call fcn.004e5b90
pop eax
cmp byte [esi + 0xc], 3
jne 0x540fc3
lea esi, [esp + 0x80]
lea edx, [esp + 0xc]
mov ecx, esi
call fcn.005080ee
cmp dword [esi], 3
je 0x541043
lea ecx, [esp + 0x80]
call fcn.00508709
jmp 0x540fcc
lea ecx, [esp + 0xc]
call fcn.0050871e
lea esi, [esp + 0xc]
mov edx, 0x630736
mov ecx, esi
push 0xa
call fcn.004e5b90
pop eax
cmp byte [esi + 0xc], 3
jne 0x54100a
lea esi, [esp + 0x80]
lea edx, [esp + 0xc]
mov ecx, esi
call fcn.005080ee
cmp dword [esi], 3
je 0x541043
lea ecx, [esp + 0x80]
call fcn.00508709
jmp 0x541013
lea ecx, [esp + 0xc]
call fcn.0050871e
lea esi, [esp + 0xc]
mov edx, 0x630740
mov ecx, esi
push 0xa
call fcn.004e5b90
pop eax
cmp byte [esi + 0xc], 3
jne 0x5410a6
lea esi, [esp + 0x80]
lea edx, [esp + 0xc]
mov ecx, esi
call fcn.005080ee
cmp dword [esi], 3
jne 0x5410b1
lea eax, [esp + 0x84]
push 0xa
pop ecx
lea edi, [esp + 0x30]
mov esi, eax
rep movsd dword es:[edi], dword [esi]
mov dl, byte [eax + 0x28]
movzx ecx, word [eax + 0x29]
mov al, byte [eax + 0x2b]
cmp dl, 4
mov word [esp + 4], cx
mov byte [esp + 6], al
je 0x5410bd
lea ebx, [esp + 0x190]
mov byte [esp + 8], dl
mov ecx, ebx
call fcn.005009b5
push 0xa
pop ecx
lea esi, [esp + 0x30]
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
mov al, byte [esp + 8]
movzx edx, word [esp + 4]
mov cl, byte [esp + 6]
mov byte [ebx + 0x28], al
mov word [ebx + 0x29], dx
mov byte [ebx + 0x2b], cl
xor ebx, ebx
inc ebx
jmp 0x5410bd
lea ecx, [esp + 0xc]
call fcn.0050871e
jmp 0x5410bd
lea ecx, [esp + 0x80]
call fcn.00508709
push 8
pop edx
mov ecx, 0x90
call fcn.004b8ae6
mov dword [eax], ebx
mov esi, eax
mov dword [eax + 4], ebx
add eax, 8
push 0x88
lea ecx, [esp + 0x14c]
push ecx
push eax
call fcn.00570db0
add esp, 0xc
mov eax, dword [esp + 0x1e4]
mov dword [esp + 8], eax
mov eax, dword [esp + 0x1e8]
mov dword [esp + 0x2c], eax
call fcn.004fbfb0
test eax, eax
je 0x541239
movsd xmm0, qword [eax + 8]
mov ecx, dword [eax]
mov edx, dword [eax + 4]
movsd qword [esp + 0x78], xmm0
movsd xmm0, qword [0x63b4f8]
mov dword [esp + 0x28], ecx
add ecx, ebx
mov dword [esp + 0x24], edx
mov dword [eax], ecx
mov ecx, edx
adc ecx, 0
mov dword [eax + 4], ecx
movsd qword [esp + 0x8b], xmm0
movsd xmm0, qword [0x63b4f0]
mov edi, dword [esp + 0x1d0]
movsd qword [esp + 0x83], xmm0
mov eax, dword [esp + 0x8f]
movsd xmm1, qword [esp + 0x80]
movsd xmm0, qword [esp + 0x88]
mov dword [esp + 0x3f], eax
mov eax, dword [esp + 0x1d4]
movsd qword [esp + 0x38], xmm0
movsd qword [esp + 0x30], xmm1
mov dword [esp + 0x20], eax
push 0x60
pop ecx
push 8
pop edx
call fcn.004b8ae6
mov ecx, dword [esp + 0x20]
mov dword [eax], ebx
mov dword [eax + 4], ebx
mov dword [eax + 8], edi
mov edi, dword [esp + 0x1c]
mov dword [eax + 0xc], ecx
and dword [eax + 0x10], 0
mov byte [eax + 0x14], 0
movsd xmm0, qword [esp + 0x30]
movsd xmm1, qword [esp + 0x38]
movsd qword [eax + 0x15], xmm0
movsd qword [eax + 0x1d], xmm1
movsd xmm0, qword [esp + 0x78]
mov ecx, dword [esp + 0x3f]
mov dword [eax + 0x24], ecx
mov ecx, dword [esp + 0x24]
mov dword [eax + 0x2c], ecx
mov ecx, dword [esp + 0x28]
mov dword [eax + 0x28], ecx
mov ecx, dword [esp + 8]
movsd qword [eax + 0x30], xmm0
mov dword [eax + 0x38], 4
and dword [eax + 0x3c], 0
and dword [eax + 0x40], 0
and dword [eax + 0x44], 0
mov dword [eax + 0x48], ecx
mov ecx, dword [esp + 0x2c]
mov dword [eax + 0x4c], ecx
movsd xmm0, qword [esp + 0x1d8]
movsd qword [eax + 0x50], xmm0
mov ecx, dword [esp + 0x1e0]
mov dword [eax + 0x58], ecx
lea ecx, [esp + 0x5c]
mov dword [edi + 4], eax
call fcn.005412c3
mov dword [edi], esi
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
push 0x46
pop edx
mov ecx, str.cannot_access_a_Thread_Local_Storage_value_during_or_after_destruction_rustc_82e1608dfa6e0b5569232559e3d385fea5a93112library_std_src_threadlocal.rs
push 0x63b4cc
push 0x62f49c
lea eax, [esp + 0x38]
push eax
call fcn.00581210
add esp, 0xc
ud2