Function at 0x1005aa85
Capabilities:
Encrypt data via sspi

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x50
mov eax, dword [ebp + 8]
lea ebx, [ebp - 0x40]
mov dword [ebp - 0x50], ecx
mov esi, edx
mov ecx, ebx
mov dword [edx + 0xd8], eax
call sym.schannel::tls_stream::TlsStream_LT_S_GT_::initialize::h0612b6d08cbc9854
mov eax, dword [ebx]
mov edi, dword [ebx + 4]
mov edx, dword [ebx + 8]
cmp eax, 2
je 0x1005ac0b
test eax, eax
je 0x1005ac04
mov eax, dword [esi + 0x120]
mov ecx, dword [esi + 0x110]
xor ecx, eax
or ecx, dword [esi + 0x114]
jne 0x1005ac59
mov ecx, dword [ebp + 0x10]
mov ebx, dword [ebp - 0x34]
cmp ecx, ebx
cmovb ebx, ecx
mov ecx, edi
add ecx, ebx
mov dword [ebp - 0x10], ebx
add edx, ecx
mov ebx, ecx
cmp eax, edx
jae 0x1005ab04
lea ecx, [esi + 0x118]
call sym.alloc::vec::Vec_LT_T_C_A_GT_::resize::h319274c7255c9d6c
mov eax, dword [esi + 0x120]
mov ecx, dword [esi + 0x11c]
mov edx, eax
push 0x101b90a0
push ebx
push edi
call sym.__LT_alloc..vec..Vec_LT_T_C_A_GT__u20_as_u20_core..ops..index..IndexMut_LT_I_GT__GT_::index_mut::h48cc404eb18754f6
add esp, 0xc
mov ecx, eax
push 0x101b90b0
push dword [ebp - 0x10]
push dword [ebp + 0xc]
call sym.core::slice::__LT_impl_u20__u5b_T_u5d__GT_::copy_from_slice::h077a5a2d401f045f
add esp, 0xc
mov ecx, dword [esi + 0x11c]
mov edx, dword [esi + 0x120]
push 0x101b90c0
push edi
call sym.__LT_alloc..vec..Vec_LT_T_C_A_GT__u20_as_u20_core..ops..index..IndexMut_LT_I_GT__GT_::index_mut::hb34d9ff47b0a8358
pop ecx
pop ecx
test eax, eax
mov ecx, dword [esi + 0x11c]
mov dword [ebp - 0x4c], eax
cmove edx, eax
mov dword [ebp - 0x48], edx
mov edx, dword [esi + 0x120]
push 0x101b90d0
push ebx
push edi
call sym.__LT_alloc..vec..Vec_LT_T_C_A_GT__u20_as_u20_core..ops..index..IndexMut_LT_I_GT__GT_::index_mut::h48cc404eb18754f6
add esp, 0xc
mov edi, edx
mov ecx, dword [esi + 0x11c]
mov edx, dword [esi + 0x120]
test eax, eax
mov dword [ebp - 0x44], eax
cmove edi, eax
push 0x101b90e0
push ebx
call sym.__LT_alloc..vec..Vec_LT_T_C_A_GT__u20_as_u20_core..ops..index..IndexMut_LT_I_GT__GT_::index_mut::h1094b8a2c4053b3d
pop ecx
pop ecx
mov ecx, dword [ebp - 0x48]
test eax, eax
cmove edx, eax
and dword [ebp - 0x1c], 0
and dword [ebp - 0x18], 0
and dword [ebp - 0x14], 0
mov dword [ebp - 0x40], ecx
mov ecx, dword [ebp - 0x4c]
mov dword [ebp - 0x3c], 7
mov dword [ebp - 0x38], ecx
mov ecx, dword [ebp - 0x44]
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x30], 1
mov dword [ebp - 0x2c], ecx
mov dword [ebp - 0x28], edx
mov dword [ebp - 0x24], 6
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x5c]
lea ecx, [ebp - 0x40]
and dword [eax], 0
mov dword [eax + 4], 4
mov dword [eax + 8], ecx
lea ecx, [esi + 0x140]
push 0
push eax
push 0
push ecx
call sub.secur32.dll_EncryptMessage
test eax, eax
je 0x1005ac2b
and dword [ebp - 0x40], 0
mov dword [ebp - 0x3c], eax
jmp 0x1005ac11
mov edx, 0x80090317
xor edi, edi
mov dword [ebp - 0x40], edi
mov dword [ebp - 0x3c], edx
mov ecx, dword [ebp - 0x50]
lea edx, [ebp - 0x40]
call sym.tokio_tls::cvt::h599fae3395203a5a
and dword [esi + 0xd8], 0
add esp, 0x50
pop esi
pop edi
pop ebx
pop ebp
ret
mov eax, dword [ebp - 0x34]
add eax, dword [ebp - 0x40]
add eax, dword [ebp - 0x28]
cmp dword [esi + 0x120], eax
jb 0x1005ac42
mov dword [esi + 0x120], eax
mov eax, dword [ebp - 0x10]
and dword [esi + 0x114], 0
and dword [esi + 0x110], 0
mov dword [esi + 0x170], eax
lea edi, [ebp - 0x40]
mov edx, esi
mov ecx, edi
call sym.schannel::tls_stream::TlsStream_LT_S_GT_::write_out::h4ed33d9cd1f8447e
cmp byte [edi], 4
je 0x1005ac71
mov eax, dword [ebp - 0x40]
cmp al, 4
jne 0x1005ac80
mov eax, dword [esi + 0x170]
mov dword [ebp - 0x3c], eax
mov byte [ebp - 0x40], 4
jmp 0x1005ac11
mov ecx, dword [ebp - 0x3c]
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], ecx
jmp 0x1005ac11