Function at 0x473200
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, 0x88
mov edi, dword [ebp + 0xc]
mov esi, dword [ebp + 8]
mov eax, dword [0x7024bc]
xor eax, ebp
mov dword [esp + 0x80], eax
mov eax, dword [esi]
mov dword [esp + 4], eax
xor eax, eax
mov dword [esp + 0x6c], eax
mov dword [esp + 0x68], eax
mov dword [esp + 0x64], eax
cmp dword [esi + 0xf0], 2
jne 0x473259
xor eax, eax
cmp dword [esi + 0x1ac], 0xffffffff
setne al
shl eax, 4
cmp dword [esi + eax + 0x210], 2
jne 0x473261
lea eax, [esi + 0xa0]
jmp 0x473267
lea eax, [esi + 0xe4]
mov ebx, dword [eax]
mov eax, dword [0x703648]
shl edi, 4
mov ecx, dword [esi + edi + 0x1f8]
lea edx, [esp + 0x6c]
push edx
push 0x53
push dword [ecx + 4]
call dword [eax + 0x2c]
test eax, eax
jne 0x4732be
mov ecx, dword [esp + 0x6c]
test ecx, ecx
je 0x4732be
cmp dword [esi + 0xf0], 2
jne 0x4732b3
xor eax, eax
cmp dword [esi + 0x1ac], 0xffffffff
setne al
shl eax, 4
cmp dword [esi + eax + 0x210], 2
jne 0x4732e4
cmp dword [esi + 0x240], 0
jne 0x4732ed
jmp 0x473331
push eax
push esi
call fcn.00467dde
add esp, 8
push eax
push str.schannel:_Failed_to_read_remote_certificate_context:__s
push dword [esp + 0xc]
call fcn.004624d0
add esp, 0xc
mov ebx, 0x33
jmp 0x47362c
cmp dword [esi + 0x264], 0
je 0x473331
lea eax, [esi + edi]
add eax, 0x1f8
mov eax, dword [eax]
cmp byte [eax + 0x47], 0
je 0x473331
sub esp, 0x10
movaps xmm0, xmmword [0x685510]
movups xmmword [esp], xmm0
call fcn.004683f4
add esp, 0x10
test al, al
je 0x473415
push str.schannel:_this_version_of_Windows_is_too_old_to_support_certificate_verification_via_CA_bundle_file.
push dword [esp + 8]
call fcn.004624d0
add esp, 8
jmp 0x473627
mov dword [esp + 0x1c], ebx
mov dword [esp], 0
mov esi, dword [esp + 4]
xorps xmm0, xmm0
lea edx, [esp + 0x30]
movups xmmword [edx + 0x24], xmm0
movups xmmword [edx + 0x14], xmm0
movups xmmword [edx + 4], xmm0
mov dword [edx], 0x34
xor eax, eax
cmp byte [esi + 0x431], 0
sete al
shl eax, 0x1d
lea edi, [esp + 0x68]
xor ebx, ebx
push edi
push ebx
push eax
push edx
push dword [ecx + 0x10]
push ebx
push ecx
push dword [esp + 0x80]
call dword [sym.imp.CRYPT32.dll_CertGetCertificateChain]
test eax, eax
je 0x4733e7
mov eax, dword [esp + 0x68]
mov eax, dword [eax + 0x10]
mov eax, dword [eax]
mov ecx, dword [eax + 4]
mov eax, ecx
and eax, 0xfffffffd
je 0x47346c
test cl, 4
jne 0x4735ec
bt ecx, 0x10
mov edi, dword [esp]
jb 0x473633
test cl, 0x20
jne 0x473669
test cl, 1
jne 0x4737c1
test cl, 0x40
jne 0x473ab0
push eax
push str.schannel:_CertGetCertificateChain_error_mask:_0x_08x
push dword [esp + 0xc]
call fcn.004624d0
add esp, 0xc
jmp 0x473ac1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 8]
call fcn.00467dde
add esp, 8
push eax
push str.schannel:_CertGetCertificateChain_failed:__s
push esi
call fcn.004624d0
add esp, 0xc
mov dword [esp + 0x68], 0
jmp 0x4735fd
sub esp, 0x14
movaps xmm0, xmmword [0x685520]
movups xmmword [esp], xmm0
mov dword [esp + 0x10], 0
call dword [sym.imp.CRYPT32.dll_CertOpenStore]
test eax, eax
je 0x473605
mov edi, eax
cmp dword [esi + 0xf0], 2
jne 0x473461
xor eax, eax
cmp dword [esi + 0x1ac], 0xffffffff
setne al
shl eax, 4
cmp dword [esi + eax + 0x210], 2
jne 0x473673
lea eax, [esi + 0x240]
jmp 0x473679
mov ecx, dword [ebp + 8]
cmp dword [ecx + 0xf0], 2
jne 0x473495
xor eax, eax
cmp dword [ecx + 0x1ac], 0xffffffff
setne al
shl eax, 4
cmp dword [ecx + eax + 0x210], 2
jne 0x47363d
cmp byte [ecx + 0x239], 0
je 0x47364a
mov edi, dword [esp + 0x6c]
mov ebx, dword [ecx]
sub esp, 0x18
movaps xmm0, xmmword [0x685550]
movups xmmword [esp + 4], xmm0
mov dword [esp], edi
mov dword [esp + 0x14], 0
call dword [sym.imp.CRYPT32.dll_CertGetNameStringW]
test eax, eax
je 0x47364e
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
add eax, eax
push eax
call dword [0x700018]
add esp, 4
mov esi, eax
push dword [esp + 8]
push eax
push 0
push 0x10002
push 6
push edi
call dword [sym.imp.CRYPT32.dll_CertGetNameStringW]
cmp eax, dword [esp + 8]
jne 0x47373c
mov dword [esp + 0x14], ebx
xor eax, eax
mov ebx, 0x33
mov edi, esi
mov dword [esp + 0xc], esi
cmp ebx, 0x33
jne 0x4735b9
cmp word [edi + eax*2], 0
je 0x4735b9
mov dword [esp + 4], eax
lea ebx, [edi + eax*2]
push ebx
call fcn.00450b8e
add esp, 4
test eax, eax
je 0x47356a
mov esi, eax
mov edi, dword [esp + 0x1c]
push edi
push eax
call fcn.004530dc
add esp, 8
cmp eax, 1
jne 0x473571
push esi
push edi
push str.schannel:_connection_hostname___s__validated_against_certificate_name___s__n
push dword [esp + 0x20]
call fcn.0046235f
add esp, 0x10
xor ebx, ebx
jmp 0x47359d
mov ebx, 0x1b
jmp 0x4735ab
push esi
push edi
push str.schannel:_connection_hostname___s__did_not_match_against_certificate_name___s__n
push dword [esp + 0x20]
call fcn.0046235f
add esp, 0x10
push ebx
call fcn.0065e7c2
add esp, 4
mov ecx, dword [esp + 4]
add ecx, eax
inc ecx
mov dword [esp + 4], ecx
mov ebx, 0x33
push esi
call dword [0x70001c]
add esp, 4
mov edi, dword [esp + 0xc]
mov eax, dword [esp + 4]
cmp eax, dword [esp + 8]
jb 0x473516
test ebx, ebx
je 0x473a8a
cmp ebx, 0x33
mov edi, dword [esp]
jne 0x473a8f
push dword [esp + 0x1c]
push str.schannel:_CertGetNameString___failed_to_match_connection_hostname___s__against_server_certificate_names
push dword [esp + 0x1c]
call fcn.004624d0
add esp, 0xc
mov ebx, 0x33
jmp 0x473aa0
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_IS_REVOKED
push dword [esp + 8]
call fcn.004624d0
add esp, 8
mov edi, dword [esp]
jmp 0x473ac1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
call fcn.00467ab7
add esp, 8
push eax
push str.schannel:_failed_to_create_certificate_store:__s
push dword [esp + 0xc]
call fcn.004624d0
add esp, 0xc
mov ebx, 0x4d
xor edi, edi
jmp 0x473ac6
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_IS_PARTIAL_CHAIN
jmp 0x473ab5
cmp byte [ecx + 0x25d], 0
jne 0x4734a2
xor ebx, ebx
jmp 0x473661
push str.schannel:_CertGetNameString___returned_no_certificate_name_information
push ebx
call fcn.004624d0
add esp, 8
mov ebx, 0x33
mov edi, dword [esp]
jmp 0x473ac6
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_IS_UNTRUSTED_ROOT
jmp 0x473ab5
lea eax, [esi + 0x264]
mov ecx, dword [eax]
mov eax, dword [esi]
mov dword [esp + 8], eax
xor eax, eax
dec eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x30], eax
mov dword [esp + 0xc], ecx
push ecx
call fcn.00450b28
add esp, 4
test eax, eax
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x14], eax
je 0x473720
sub esp, 0x1c
movaps xmm0, xmmword [0x685530]
movups xmmword [esp + 4], xmm0
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 0x47375f
lea ecx, [esp + 0x30]
push ecx
mov dword [esp + 0x14], eax
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x473791
mov ecx, dword [esp + 0x30]
mov eax, dword [esp + 0x34]
cmp ecx, 0x100001
sbb eax, 0
jl 0x4737cb
push 0x100000
push str.schannel:_CA_file_exceeds_max_size_of__u_bytes
push dword [esp + 0x10]
call fcn.004624d0
add esp, 0xc
jmp 0x4739ee
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
call fcn.00467ab7
add esp, 8
push eax
push dword [esp + 0x10]
push str.schannel:_invalid_path_name_for_CA_file__s:__s
jmp 0x473779
push str.schannel:_CertGetNameString___returned_certificate_name_information_of_unexpected_size
push ebx
call fcn.004624d0
add esp, 8
mov ebx, 0x33
test esi, esi
mov edi, dword [esp]
jne 0x473aa4
jmp 0x473ac6
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
call fcn.00467ab7
add esp, 8
push eax
push dword [esp + 0x10]
push str.schannel:_failed_to_open_CA_file__s:__s
push dword [esp + 0x14]
call fcn.004624d0
add esp, 0x10
mov ebx, 0x4d
xor eax, eax
jmp 0x473a0a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
call fcn.00467ab7
add esp, 8
push eax
push dword [esp + 0x10]
push str.schannel:_failed_to_determine_size_of_CA_file__s:__s
push dword [esp + 0x14]
call fcn.004624d0
add esp, 0x10
mov ebx, 0x4d
jmp 0x4739f3
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_IS_NOT_TIME_VALID
jmp 0x473ab5
mov ebx, ecx
lea eax, [ecx + 1]
push eax
call dword [0x700018]
add esp, 4
test eax, eax
je 0x4739ee
mov dword [esp], edi
mov edi, 0
test ebx, ebx
mov dword [esp + 0x18], eax
je 0x473836
mov ecx, ebx
xor ebx, ebx
mov edi, ecx
mov edx, edi
sub edx, ebx
xor ecx, ecx
mov dword [esp + 0x78], ecx
lea ecx, [eax + ebx]
xor eax, eax
push eax
lea eax, [esp + 0x7c]
push eax
push edx
push ecx
push dword [esp + 0x20]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x473b18
mov eax, dword [esp + 0x78]
test eax, eax
cmove edi, ebx
add eax, ebx
mov ebx, eax
cmp edi, eax
mov eax, dword [esp + 0x18]
ja 0x4737f8
mov byte [eax + edi], 0
mov cl, 1
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x28], 0
mov dword [esp + 0x20], eax
xor ebx, ebx
mov edi, dword [esp]
mov ecx, dword [esp + 8]
mov edx, dword [esp + 0xc]
mov eax, edx
mov edx, ecx
mov ecx, dword [esp + 0x20]
cmp byte [ecx], 0
je 0x473b40
push str._____BEGIN_CERTIFICATE______n
push ecx
call fcn.006461a0
add esp, 8
test eax, eax
je 0x473b4a
mov edi, eax
push str._n_____END_CERTIFICATE_____
push eax
call fcn.006461a0
add esp, 8
test eax, eax
je 0x473b7b
xor ecx, ecx
mov dword [esp + 0x74], ecx
mov dword [esp + 0x70], ecx
add eax, 0x1a
mov dword [esp + 0x24], eax
sub eax, edi
mov dword [esp + 0x7c], edi
mov dword [esp + 0x78], eax
sub esp, 0x2c
lea eax, [esp + 0xa0]
mov dword [esp + 0x28], eax
mov dword [esp + 0x24], ecx
mov dword [esp + 0x20], ecx
mov dword [esp + 0x1c], ecx
lea eax, [esp + 0x9c]
mov dword [esp + 0x18], eax
movaps xmm0, xmmword [0x685540]
movups xmmword [esp + 8], xmm0
lea eax, [esp + 0xa4]
mov dword [esp + 4], eax
mov dword [esp], 2
call dword [sym.imp.CRYPT32.dll_CryptQueryObject]
test eax, eax
je 0x473943
mov eax, dword [esp + 0x70]
cmp eax, 1
mov edi, dword [esp]
jne 0x473972
push 0
push 4
push dword [esp + 0x7c]
push edi
call dword [sym.imp.CRYPT32.dll_CertAddCertificateContextToStore]
mov edi, eax
push dword [esp + 0x74]
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateContext]
test edi, edi
je 0x473999
inc dword [esp + 0x28]
mov eax, dword [esp + 0x24]
mov dword [esp + 0x20], eax
mov edi, dword [esp]
mov eax, dword [esp + 0x2c]
jmp 0x4739d1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
call fcn.00467ab7
add esp, 8
push eax
push dword [esp + 0x10]
push str.schannel:_failed_to_extract_certificate_from_CA_file__s:__s
push dword [esp + 0x14]
call fcn.004624d0
add esp, 0x10
mov ebx, 0x4d
xor eax, eax
jmp 0x4739ce
push dword [esp + 0xc]
push eax
push str.schannel:_unexpected_content_type__d_when_extracting_certificate_from_CA_file__s
push dword [esp + 0x14]
call fcn.004624d0
add esp, 0x10
mov ebx, 0x4d
xor eax, eax
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x20], ecx
jmp 0x4739d1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
call fcn.00467ab7
add esp, 8
push eax
push dword [esp + 0x10]
push str.schannel:_failed_to_add_certificate_from_CA_file__sto_certificate_store:__s
push dword [esp + 0x14]
call fcn.004624d0
add esp, 0x10
mov ebx, 0x4d
xor eax, eax
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x20], ecx
mov edi, dword [esp]
mov dword [esp + 0x2c], eax
test al, 1
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 8]
mov edx, dword [esp + 0xc]
jne 0x473859
jmp 0x473b59
mov ebx, 0x1b
mov dword [esp + 0x18], 0
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x18]
push eax
call dword [0x70001c]
add esp, 4
push dword [esp + 0x14]
call dword [0x70001c]
add esp, 4
test ebx, ebx
jne 0x473ac6
xorps xmm0, xmm0
lea eax, [esp + 0x30]
movups xmmword [eax + 0x20], xmm0
movups xmmword [eax + 0x14], xmm0
movups xmmword [eax + 4], xmm0
mov dword [eax], 0x30
mov dword [eax + 0x28], edi
lea ecx, [esp + 0x64]
push ecx
push eax
call dword [sym.imp.CRYPT32.dll_CertCreateCertificateChainEngine]
test eax, eax
je 0x473a61
mov dword [esp], edi
mov ecx, dword [esp + 0x6c]
jmp 0x47333c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
call fcn.00467ab7
add esp, 8
push eax
push str.schannel:_failed_to_create_certificate_chain_engine:__s
push dword [esp + 0xc]
call fcn.004624d0
add esp, 0xc
mov ebx, 0x4d
jmp 0x473ac6
mov edi, dword [esp]
jmp 0x473aa0
push str.schannel:_server_certificate_name_verification_failed
push dword [esp + 0x18]
call fcn.004624d0
add esp, 8
mov esi, dword [esp + 0xc]
push esi
call dword [0x70001c]
add esp, 4
jmp 0x473ac6
push str.schannel:_CertGetCertificateChain_trust_error_CERT_TRUST_REVOCATION_STATUS_UNKNOWN
push dword [esp + 8]
call fcn.004624d0
add esp, 8
mov ebx, 0x33
mov eax, dword [esp + 0x64]
test eax, eax
je 0x473ad5
push eax
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateChainEngine]
test edi, edi
je 0x473ae2
push 0
push edi
call dword [sym.imp.CRYPT32.dll_CertCloseStore]
mov eax, dword [esp + 0x68]
test eax, eax
je 0x473af1
push eax
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateChain]
mov eax, dword [esp + 0x6c]
test eax, eax
je 0x473b00
push eax
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateContext]
mov ecx, dword [esp + 0x80]
xor ecx, ebp
call fcn.0064180a
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
call fcn.00467ab7
add esp, 8
push eax
push dword [esp + 0x10]
push str.schannel:_failed_to_read_from_CA_file__s:__s
push dword [esp + 0x14]
call fcn.004624d0
add esp, 0x10
jmp 0x473b90
mov ecx, edx
mov edx, eax
mov eax, dword [esp + 0x10]
jmp 0x473b59
mov edi, dword [esp]
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 8]
mov edx, dword [esp + 0xc]
test ebx, ebx
jne 0x4739ff
mov eax, dword [esp + 0x28]
test eax, eax
je 0x473b9d
push edx
push eax
push str.schannel:_added__d_certificate_s__from_CA_file__s_n
push ecx
call fcn.0046235f
add esp, 0x10
jmp 0x473bac
push dword [esp + 0xc]
push str.schannel:_CA_file__s_is_not_correctly_formatted
push dword [esp + 0x10]
call fcn.004624d0
add esp, 0xc
mov ebx, 0x4d
mov edi, dword [esp]
jmp 0x4739fb
push edx
push str.schannel:_did_not_add_any_certificates_from_CA_file__s_n
push ecx
call fcn.0046235f
add esp, 0xc
xor ebx, ebx
jmp 0x4739fb