Function at 0x52d7d0
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x168
mov ebx, dword [ebp + 0x10]
mov edi, dword [ebp + 0xc]
mov eax, dword [0x7aa024]
xor eax, ebp
mov dword [esp + 0x160], eax
xor eax, eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x50], eax
cmp dword [edi + 0xb8], 2
jne 0x52d823
xor eax, eax
cmp dword [edi + 0x14c], 0xffffffff
setne al
shl eax, 4
cmp dword [edi + eax + 0x1b0], 2
jne 0x52d828
lea eax, [edi + 0x64]
jmp 0x52d82e
lea eax, [edi + 0xac]
mov eax, dword [eax]
mov dword [esp + 0x10], eax
mov eax, dword [0x7ba8b8]
mov ecx, dword [eax + 0x2c]
shl ebx, 4
mov eax, dword [edi + ebx + 0x198]
mov esi, dword [eax + 4]
call dword [section..00cfg]
lea eax, [esp + 0x58]
push eax
push 0x53
push esi
call ecx
mov esi, eax
test eax, eax
jne 0x52d8a1
cmp dword [esp + 0x58], 0
je 0x52d8a1
mov eax, dword [edi + 0xb8]
cmp eax, 2
jne 0x52d88a
xor ecx, ecx
cmp dword [edi + 0x14c], 0xffffffff
setne cl
shl ecx, 4
cmp dword [edi + ecx + 0x1b0], 2
jne 0x52d8df
cmp dword [edi + 0x1e0], 0
jne 0x52d8f5
cmp dword [edi + 0x204], 0
jne 0x52d8f5
jmp 0x52d93e
mov edi, 0x100
lea ebx, [esp + 0x60]
push edi
push 0xff
push ebx
call fcn.00650600
add esp, 0xc
push edi
push ebx
push esi
call fcn.0051d160
add esp, 0xc
push eax
push str.schannel:_Failed_to_read_remote_certificate_context:__s
push dword [ebp + 8]
call fcn.00515170
add esp, 0xc
mov ebx, 0x3c
jmp 0x52dc87
cmp dword [edi + 0x220], 0
jne 0x52d8f5
cmp dword [edi + 0x244], 0
je 0x52dcda
lea ecx, [edi + ebx]
add ecx, 0x198
mov ecx, dword [ecx]
cmp byte [ecx + 0x47], 0
je 0x52d93e
sub esp, 0x14
movaps xmm0, xmmword [0x755940]
movups xmmword [esp], xmm0
mov dword [esp + 0x10], 0
call fcn.00529cf0
add esp, 0x14
test al, al
mov ebx, dword [ebp + 8]
je 0x52d986
push str.schannel:_this_version_of_Windows_is_too_old_to_support_certificate_verification_via_CA_bundle_file.
push ebx
call fcn.00515170
add esp, 8
jmp 0x52dc82
xor esi, esi
mov ecx, dword [ebp + 8]
xorps xmm0, xmm0
movups xmmword [esp + 0x3c], xmm0
movups xmmword [esp + 0x2c], xmm0
movups xmmword [esp + 0x1c], xmm0
mov dword [esp + 0x18], 0x34
cmp eax, 2
jne 0x52d97b
xor eax, eax
cmp dword [edi + 0x14c], 0xffffffff
setne al
shl eax, 4
cmp dword [edi + eax + 0x1b0], 2
jne 0x52d9eb
mov dword [esp], esi
add ecx, 0x46f
jmp 0x52d9f4
sub esp, 0x14
movaps xmm0, xmmword [0x756a20]
movups xmmword [esp], xmm0
mov dword [esp + 0x10], 0
call dword [sym.imp.CRYPT32.dll_CertOpenStore]
test eax, eax
je 0x52dc4a
mov esi, eax
cmp dword [edi + 0xb8], 2
jne 0x52d9d2
xor eax, eax
cmp dword [edi + 0x14c], 0xffffffff
setne al
shl eax, 4
cmp dword [edi + eax + 0x1b0], 2
jne 0x52dcb0
mov eax, dword [edi + 0x204]
test eax, eax
jne 0x52dcbe
lea eax, [edi + 0x1e0]
jmp 0x52dd47
mov dword [esp], esi
add ecx, 0x4db
xor eax, eax
cmp byte [ecx], 0
sete al
shl eax, 0x1d
mov ecx, dword [esp + 0x58]
lea edx, [esp + 0x54]
xor esi, esi
lea ebx, [esp + 0x18]
push edx
push esi
push eax
push ebx
push dword [ecx + 0x10]
push esi
push ecx
push dword [esp + 0x6c]
call dword [sym.imp.CRYPT32.dll_CertGetCertificateChain]
test eax, eax
je 0x52da93
mov eax, dword [esp + 0x54]
mov eax, dword [eax + 0x10]
mov eax, dword [eax]
mov ecx, dword [eax + 4]
mov ebx, dword [ebp + 8]
cmp byte [ebx + 0x471], 0
mov edx, 0xfffffffd
mov eax, 0xfeffffbd
cmove eax, edx
and eax, ecx
je 0x52dada
test cl, 4
jne 0x52dc8e
bt ecx, 0x10
jb 0x52dc95
test cl, 0x20
mov esi, dword [esp]
jne 0x52dd2d
test cl, 1
jne 0x52dec7
test al, 0x40
jne 0x52df88
push eax
push str.schannel:_CertGetCertificateChain_error_mask:_0x_08x
push ebx
call fcn.00515170
add esp, 0xc
jmp 0x52dca6
mov esi, 0x100
lea edi, [esp + 0x60]
push esi
push 0xff
push edi
call fcn.00650600
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
push edi
push eax
call fcn.0051d040
add esp, 0xc
push eax
push str.schannel:_CertGetCertificateChain_failed:__s
push dword [ebp + 8]
call fcn.00515170
add esp, 0xc
mov dword [esp + 0x54], 0
jmp 0x52dca3
cmp dword [edi + 0xb8], 2
jne 0x52db00
xor eax, eax
cmp dword [edi + 0x14c], 0xffffffff
setne al
shl eax, 4
cmp dword [edi + eax + 0x1b0], 2
jne 0x52dcfe
cmp byte [edi + 0x211], 0
je 0x52dd0b
mov esi, dword [esp + 0x58]
xor edi, edi
mov ecx, ebx
mov edx, esi
push edi
push edi
call fcn.0052e420
add esp, 8
test eax, eax
je 0x52dd15
mov ecx, dword [fcn.005f2b30]
lea ebx, [eax + eax]
mov dword [esp + 0xc], eax
call dword [section..00cfg]
push ebx
call ecx
add esp, 4
test eax, eax
je 0x52dd37
mov edi, dword [ebp + 8]
mov ecx, edi
mov edx, esi
mov ebx, dword [esp + 0xc]
push ebx
mov esi, eax
push eax
call fcn.0052e420
add esp, 8
cmp eax, ebx
jne 0x52de98
xor ecx, ecx
mov ebx, 0x3c
mov edi, esi
mov dword [esp + 8], esi
cmp ebx, 0x3c
jne 0x52dc18
cmp word [edi + ecx*2], 0
je 0x52dc18
mov dword [esp + 4], ecx
lea ebx, [edi + ecx*2]
push ebx
call fcn.004fb0b0
add esp, 4
test eax, eax
je 0x52dbc9
mov esi, eax
mov edi, dword [esp + 0x10]
push edi
push eax
call fcn.004ff740
add esp, 8
cmp eax, 1
jne 0x52dbd0
push esi
push edi
push str.schannel:_connection_hostname___s__validated_against_certificate_name___s_
push dword [ebp + 8]
call fcn.00514fc0
add esp, 0x10
xor ebx, ebx
jmp 0x52dbfb
mov ebx, 0x1b
jmp 0x52dc08
push esi
push edi
push str.schannel:_connection_hostname___s__did_not_match_against_certificate_name___s_
push dword [ebp + 8]
call fcn.00514fc0
add esp, 0x10
push ebx
call fcn.0066b526
add esp, 4
mov ecx, dword [esp + 4]
add ecx, eax
inc ecx
mov dword [esp + 4], ecx
mov ebx, 0x3c
push esi
call fcn.005f2b80
add esp, 4
mov edi, dword [esp + 8]
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 4]
cmp ecx, eax
jb 0x52db76
test ebx, ebx
mov esi, dword [esp]
je 0x52deb0
cmp ebx, 0x3c
jne 0x52df9b
push dword [esp + 0x10]
push str.schannel:_CertGetNameString___failed_to_match_connection_hostname___s__against_server_certificate_names
push dword [ebp + 8]
call fcn.00515170
add esp, 0xc
mov ebx, 0x3c
jmp 0x52deb0
mov esi, 0x100
lea edi, [esp + 0x60]
push esi
push 0xff
push edi
call fcn.00650600
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
push edi
push eax
call fcn.0051d040
add esp, 0xc
push eax
push str.schannel:_failed_to_create_certificate_store:__s
push ebx
call fcn.00515170
add esp, 0xc
mov ebx, 0x4d
xor esi, esi
jmp 0x52e056
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_IS_REVOKED
jmp 0x52dc9a
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_IS_PARTIAL_CHAIN
push ebx
call fcn.00515170
add esp, 8
mov esi, dword [esp]
mov ebx, 0x3c
jmp 0x52e056
mov eax, dword [edi + 0x244]
test eax, eax
je 0x52dd41
mov edx, dword [eax]
mov ecx, esi
push ebx
push str._memory_blob_
push dword [eax + 4]
call fcn.0052e130
add esp, 0xc
mov ebx, eax
jmp 0x52e052
xorps xmm0, xmm0
movups xmmword [esp + 0x3c], xmm0
movups xmmword [esp + 0x2c], xmm0
movups xmmword [esp + 0x1c], xmm0
mov dword [esp + 0x18], 0x34
xor esi, esi
mov ecx, dword [ebp + 8]
jmp 0x52d962
cmp byte [edi + 0x251], 0
jne 0x52db0d
xor ebx, ebx
mov esi, dword [esp]
jmp 0x52e056
push str.schannel:_CertGetNameString___returned_no_certificate_name_information
push ebx
call fcn.00515170
add esp, 8
mov ebx, 0x3c
jmp 0x52dead
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_IS_UNTRUSTED_ROOT
jmp 0x52df8d
mov ebx, 0x1b
jmp 0x52dead
lea eax, [edi + 0x220]
mov ecx, dword [eax]
xor eax, eax
dec eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0xc], ecx
push ecx
call fcn.004fb040
add esp, 4
test eax, eax
je 0x52dde3
sub esp, 0x1c
movaps xmm0, xmmword [0x756a30]
movups xmmword [esp + 4], xmm0
mov dword [esp + 0x30], eax
mov dword [esp], eax
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x80
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
je 0x52de43
lea ecx, [esp + 0x18]
push ecx
mov dword [esp + 0xc], eax
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x52ded1
mov ebx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
cmp ebx, 0x100001
sbb eax, 0
jl 0x52df26
push 0x100000
push str.schannel:_CA_file_exceeds_max_size_of__u_bytes
push dword [ebp + 8]
call fcn.00515170
add esp, 0xc
jmp 0x52df14
mov eax, 0x100
lea ebx, [esp + 0x60]
push eax
push 0xff
push ebx
call fcn.00650600
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 0x100
push ecx
push ebx
push eax
call fcn.0051d040
add esp, 0xc
push eax
push dword [esp + 0x10]
push str.schannel:_invalid_path_name_for_CA_file__s:__s
push dword [ebp + 8]
call fcn.00515170
add esp, 0x10
mov ecx, dword [fcn.005f2b80]
call dword [section..00cfg]
push 0
call ecx
add esp, 4
mov ebx, 0x4d
jmp 0x52e052
mov eax, 0x100
lea ebx, [esp + 0x60]
push eax
push 0xff
push ebx
call fcn.00650600
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 0x100
push ecx
push ebx
push eax
call fcn.0051d040
add esp, 0xc
push eax
push dword [esp + 0x10]
push str.schannel:_failed_to_open_CA_file__s:__s
push dword [ebp + 8]
call fcn.00515170
add esp, 0x10
mov ebx, 0x4d
mov dword [esp + 4], 0
jmp 0x52e031
push str.schannel:_CertGetNameString___returned_certificate_name_information_of_unexpected_size
push edi
call fcn.00515170
add esp, 8
mov ebx, 0x3c
mov edi, esi
mov esi, dword [esp]
mov ecx, dword [fcn.005f2b80]
call dword [section..00cfg]
push edi
call ecx
add esp, 4
jmp 0x52e056
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_IS_NOT_TIME_VALID
jmp 0x52df8d
mov eax, 0x100
lea ebx, [esp + 0x60]
push eax
push 0xff
push ebx
call fcn.00650600
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 0x100
push ecx
push ebx
push eax
call fcn.0051d040
add esp, 0xc
push eax
push dword [esp + 0x10]
push str.schannel:_failed_to_determine_size_of_CA_file__s:__s
push dword [ebp + 8]
call fcn.00515170
add esp, 0x10
mov ebx, 0x4d
mov dword [esp + 4], 0
jmp 0x52e026
mov dword [esp], esi
mov ecx, dword [fcn.005f2b30]
lea esi, [ebx + 1]
call dword [section..00cfg]
push esi
call ecx
add esp, 4
test eax, eax
je 0x52dfb0
test ebx, ebx
mov dword [esp + 4], eax
je 0x52dfbf
xor esi, esi
mov edx, ebx
sub edx, esi
xor ecx, ecx
mov dword [esp + 0x5c], ecx
lea ecx, [eax + esi]
xor eax, eax
push eax
lea eax, [esp + 0x60]
push eax
push edx
push ecx
push dword [esp + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x52dfe0
mov eax, dword [esp + 0x5c]
test eax, eax
cmove ebx, esi
add eax, esi
mov esi, eax
cmp ebx, eax
mov eax, dword [esp + 4]
ja 0x52df4c
jmp 0x52dfc1
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_REVOCATION_STATUS_UNKNOWN
push ebx
call fcn.00515170
add esp, 8
jmp 0x52dca6
push str.schannel:_server_certificate_name_verification_failed
push dword [ebp + 8]
call fcn.00515170
add esp, 8
jmp 0x52deb0
mov ebx, 0x1b
mov dword [esp + 4], 0
jmp 0x52e023
xor ebx, ebx
mov byte [eax + ebx], 0
mov esi, dword [esp]
mov ecx, esi
mov edx, eax
push dword [ebp + 8]
push dword [esp + 0x10]
push ebx
call fcn.0052e130
add esp, 0xc
mov ebx, eax
jmp 0x52e026
mov esi, 0x100
lea ebx, [esp + 0x60]
push esi
push 0xff
push ebx
call fcn.00650600
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
push ebx
push eax
call fcn.0051d040
add esp, 0xc
push eax
push dword [esp + 0x10]
push str.schannel:_failed_to_read_from_CA_file__s:__s
push dword [ebp + 8]
call fcn.00515170
add esp, 0x10
mov ebx, 0x4d
mov esi, dword [esp]
mov eax, dword [esp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [fcn.005f2b80]
call dword [section..00cfg]
push dword [esp + 4]
call ecx
add esp, 4
push dword [esp + 0x14]
call fcn.005f2b80
add esp, 4
test ebx, ebx
je 0x52e0a8
mov eax, dword [esp + 0x50]
test eax, eax
je 0x52e065
push eax
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateChainEngine]
test esi, esi
je 0x52e072
push 0
push esi
call dword [sym.imp.CRYPT32.dll_CertCloseStore]
mov eax, dword [esp + 0x54]
test eax, eax
je 0x52e081
push eax
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateChain]
mov eax, dword [esp + 0x58]
test eax, eax
je 0x52e090
push eax
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateContext]
mov ecx, dword [esp + 0x160]
xor ecx, ebp
call fcn.0064d372
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
xorps xmm0, xmm0
lea eax, [esp + 0x18]
movups xmmword [eax + 0x20], xmm0
movups xmmword [eax + 0x14], xmm0
movups xmmword [eax + 4], xmm0
mov dword [eax], 0x30
mov dword [eax + 0x28], esi
lea ecx, [esp + 0x50]
push ecx
push eax
call dword [sym.imp.CRYPT32.dll_CertCreateCertificateChainEngine]
test eax, eax
je 0x52e0df
mov eax, dword [edi + 0xb8]
jmp 0x52d940
mov ebx, esi
mov esi, 0x100
lea edi, [esp + 0x60]
push esi
push 0xff
push edi
call fcn.00650600
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov esi, ebx
push edi
push eax
call fcn.0051d040
add esp, 0xc
push eax
push str.schannel:_failed_to_create_certificate_chain_engine:__s
push dword [ebp + 8]
call fcn.00515170
add esp, 0xc
mov ebx, 0x4d
jmp 0x52e056