Function at 0x418160
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x1c4
mov ecx, dword [esp + 0x1cc]
push ebx
push ebp
push esi
mov esi, dword [esp + 0x1d4]
lea ebp, [ecx + 0x45]
shl ebp, 4
mov eax, dword [esi]
push edi
mov dword [esp + 0x10], eax
mov eax, dword [esi + 0x358]
or edi, 0xffffffff
add ebp, esi
xor ebx, ebx
cmp eax, 2
mov dword [esp + 0x2c], edi
mov dword [esp + 0x30], ebp
mov dword [esp + 0x14], ebx
mov dword [esp + 0x24], ebx
jne 0x4181cb
mov ecx, dword [esi + 0x40c]
xor edx, edx
cmp ecx, edi
setne dl
add edx, 0x47
shl edx, 4
cmp dword [edx + esi], 2
je 0x4181cb
mov eax, dword [esi + 0x34c]
mov dword [esp + 0x20], eax
jmp 0x4181d5
mov ecx, dword [esi + 0x304]
mov dword [esp + 0x20], ecx
push 1
push 2
push 1
push 5
call fcn.004053e0
add esp, 0x10
test eax, eax
je 0x4181fb
mov edx, dword [esp + 0x10]
push str.schannel:_Windows_version_is_old_and_may_not_be_able_to_connect_to_some_servers_due_to_lack_of_SNI__algorithms__etc._n
push edx
call fcn.0040e110
add esp, 8
mov eax, dword [ebp + 8]
mov dword [eax + 0x4c], ebx
mov eax, dword [esi + 0x358]
cmp eax, 2
jne 0x41822d
mov edx, dword [esi + 0x40c]
xor ecx, ecx
cmp edx, edi
setne cl
add ecx, 0x47
shl ecx, 4
cmp dword [ecx + esi], 2
je 0x41822d
mov eax, dword [esi + 0x4d8]
jmp 0x418233
mov eax, dword [esi + 0x4a0]
cmp eax, ebx
je 0x418279
push 3
push 2
push 1
push 6
call fcn.004053e0
add esp, 0x10
test eax, eax
je 0x418257
mov edx, dword [ebp + 8]
mov dword [edx + 0x50], 1
jmp 0x41827f
mov eax, dword [esp + 0x10]
push str.schannel:_this_version_of_Windows_is_too_old_to_support_certificate_verification_via_CA_bundle_file.
push eax
call fcn.0040e1d0
add esp, 8
mov eax, 0x4d
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x50], ebx
mov edx, dword [ebp + 8]
mov dword [edx], ebx
mov eax, dword [esi + 0x358]
cmp eax, 2
jne 0x4182b4
mov ecx, dword [esi + 0x40c]
xor eax, eax
cmp ecx, edi
setne al
add eax, 0x47
shl eax, 4
cmp dword [eax + esi], 2
je 0x4182b4
mov ecx, dword [esp + 0x10]
mov eax, dword [ecx + 0x8e0]
jmp 0x4182be
mov edx, dword [esp + 0x10]
mov eax, dword [edx + 0x868]
cmp eax, ebx
je 0x4182fd
push esi
call fcn.00405bd0
mov eax, dword [esp + 0x1e0]
lea ecx, [esp + 0x28]
push eax
push ebx
push ecx
push esi
call fcn.00405c30
add esp, 0x14
test eax, eax
jne 0x4182f4
mov edx, dword [ebp + 8]
mov eax, dword [esp + 0x24]
mov dword [edx], eax
mov ecx, dword [ebp + 8]
mov eax, dword [ecx]
inc dword [eax + 0x10]
push esi
call fcn.00405c00
add esp, 4
mov edx, dword [ebp + 8]
cmp dword [edx], ebx
jne 0x418930
mov ecx, 0xe
xor eax, eax
lea edi, [esp + 0x5c]
rep stosd dword es:[edi], eax
mov eax, dword [esi + 0x4bc]
mov dword [esp + 0x5c], 4
cmp eax, ebx
je 0x418374
mov eax, dword [edx + 0x50]
mov edi, dword [esp + 0x10]
neg eax
sbb eax, eax
and al, 0xe8
add eax, 0x20
mov dword [esp + 0x8c], eax
mov ecx, dword [edi + 0x8a0]
cmp ecx, ebx
je 0x418354
or ah, 0x18
mov dword [esp + 0x8c], eax
jmp 0x418384
cmp dword [edi + 0x8a8], ebx
je 0x418368
or ah, 0x1a
mov dword [esp + 0x8c], eax
jmp 0x418384
or ah, 2
mov dword [esp + 0x8c], eax
jmp 0x418384
mov edi, dword [esp + 0x10]
mov eax, 0x1808
mov dword [esp + 0x8c], eax
cmp dword [esi + 0x4c0], ebx
jne 0x418395
or al, 4
mov dword [esp + 0x8c], eax
mov eax, dword [esi + 0x494]
cmp eax, 7
ja case.default.0x4183a4
jmp dword [eax*4 + 0x418bb0]
lea edx, [esp + 0x5c]
push esi
push edx
call fcn.00418c10
add esp, 8
cmp eax, ebx
je 0x4183da
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
mov dword [esp + 0x7c], 0x20
jmp 0x4183da
mov dword [esp + 0x7c], 8
mov ecx, dword [esi + 0x358]
cmp ecx, 2
jne 0x418406
mov edx, dword [esi + 0x40c]
xor eax, eax
cmp edx, 0xffffffff
setne al
add eax, 0x47
shl eax, 4
cmp dword [eax + esi], ecx
je 0x418406
mov eax, dword [esi + 0x4e8]
jmp 0x41840c
mov eax, dword [esi + 0x4b0]
cmp eax, ebx
je 0x418474
cmp ecx, 2
jne 0x418437
mov eax, dword [esi + 0x40c]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
add ecx, 0x47
shl ecx, 4
cmp dword [ecx + esi], 2
je 0x418437
mov eax, dword [esi + 0x4e8]
jmp 0x41843d
mov eax, dword [esi + 0x4b0]
lea edx, [esp + 0x5c]
push eax
push edx
call fcn.00418d10
mov edi, eax
add esp, 8
cmp edi, ebx
je 0x418470
mov eax, dword [esp + 0x10]
push str.Unable_to_set_ciphers_to_passed_via_SSL_CONN_CONFIG
push eax
call fcn.0040e1d0
add esp, 8
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
mov edi, dword [esp + 0x10]
mov eax, dword [edi + 0x880]
cmp eax, ebx
je 0x418821
xor edi, edi
cmp eax, ebx
mov dword [esp + 0x18], ebx
jne 0x41849c
pop edi
pop esi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x1c4
ret
lea ecx, [esp + 0x4c]
lea edx, [esp + 0x18]
push ecx
lea ecx, [esp + 0x2c]
push edx
push ecx
push eax
call fcn.00419920
mov ebp, eax
add esp, 0x10
cmp ebp, ebx
je 0x418729
mov edx, dword [esp + 0x10]
mov eax, dword [edx + 0x880]
cmp byte [eax], 0
je 0x4184dd
push 0x9f0430
push eax
call fcn.009bcdf4
add esp, 8
mov edi, eax
cmp edi, ebx
jne 0x418507
mov eax, dword [esp + 0x10]
mov ecx, dword [eax + 0x880]
push ecx
push str.schannel:_Failed_to_get_certificate_location_or_file_for__s
push eax
call fcn.0040e1d0
add esp, 0xc
mov eax, ebp
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
push 2
push ebx
push edi
mov dword [esp + 0x28], ebx
xor ebp, ebp
mov dword [esp + 0x40], ebx
mov dword [esp + 0x5c], ebx
call fcn.009bcd03
add esp, 0xc
neg eax
sbb eax, eax
inc eax
mov dword [esp + 0x94], eax
je 0x41857b
push edi
call fcn.009bc9ea
mov ebp, eax
add esp, 4
cmp ebp, ebx
jl 0x41857b
push 0
push 0
push edi
call fcn.009bcd03
mov ebx, eax
add esp, 0xc
neg ebx
sbb ebx, ebx
inc ebx
je 0x41857b
lea edx, [ebp + 1]
push edx
call dword [0x9f0290]
add esp, 4
mov dword [esp + 0x1c], eax
test eax, eax
je 0x41857b
push edi
push 1
push ebp
push eax
call fcn.009b587b
add esp, 0x10
cmp eax, 1
je 0x41857d
xor ebx, ebx
push edi
call fcn.009bc395
add esp, 4
test ebx, ebx
jne 0x4185be
mov eax, dword [esp + 0x10]
mov ecx, dword [eax + 0x880]
push ecx
push str.schannel:_Failed_to_read_cert_file__s
push eax
call fcn.0040e1d0
mov edx, dword [esp + 0x28]
push edx
call dword [0x9f0294]
add esp, 0x10
mov eax, 0x3a
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x58], eax
mov dword [esp + 0x54], ebp
mov edi, dword [ecx + 0x890]
test edi, edi
je 0x4185e6
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov edi, ecx
jmp 0x4185ea
mov edi, dword [esp + 0x34]
lea ebx, [edi + 1]
lea edx, [ebx + ebx]
push edx
call dword [0x9f0290]
add esp, 4
mov ebp, eax
test edi, edi
jbe 0x418621
mov eax, dword [esp + 0x10]
push ebx
push ebp
push edi
mov ecx, dword [eax + 0x890]
push ecx
push 8
push 0xfde9
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jl 0x418632
jmp 0x418625
mov eax, dword [esp + 0x50]
cmp eax, edi
jg 0x418632
mov word [ebp + eax*2], 0
jmp 0x418638
mov word [ebp], 0
push 0
lea edx, [esp + 0x58]
push ebp
push edx
call dword [sym.imp.CRYPT32.dll_PFXImportCertStore]
push ebp
mov edi, eax
call dword [0x9f0294]
mov eax, dword [esp + 0x20]
push eax
call dword [0x9f0294]
add esp, 8
test edi, edi
jne 0x4186bf
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x56
jne 0x418695
mov eax, dword [esp + 0x10]
mov ecx, dword [eax + 0x880]
push ecx
push str.schannel:_Failed_to_import_cert_file__s__password_is_bad
push eax
call fcn.0040e1d0
add esp, 0xc
mov eax, 0x3a
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
push eax
mov eax, dword [esp + 0x14]
mov edx, dword [eax + 0x880]
push edx
push str.schannel:_Failed_to_import_cert_file__s__last_error_is_0x_x
push eax
call fcn.0040e1d0
add esp, 0x10
mov eax, 0x3a
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
push 0
push 0
push 0
push 0
push 0x10001
push edi
call dword [sym.imp.CRYPT32.dll_CertFindCertificateInStore]
test eax, eax
mov dword [esp + 0x14], eax
jne 0x418714
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov eax, dword [esp + 0x14]
mov ecx, dword [eax + 0x880]
push ecx
push str.schannel:_Failed_to_get_certificate_from_file__s__last_error_is_0x_x
push eax
call fcn.0040e1d0
add esp, 0x10
push 0
push edi
call dword [sym.imp.CRYPT32.dll_CertCloseStore]
pop edi
pop esi
pop ebp
mov eax, 0x3a
pop ebx
add esp, 0x1c4
ret
lea edx, [esp + 0x14]
mov dword [esp + 0x60], 1
mov dword [esp + 0x64], edx
jmp 0x41880e
mov ecx, dword [esp + 0x28]
mov eax, dword [esp + 0x18]
or ch, 0x40
push eax
push ecx
push ebx
push ebx
push 9
call dword [sym.imp.CRYPT32.dll_CertOpenStore]
mov edi, eax
cmp edi, ebx
jne 0x418784
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x10]
push eax
mov eax, dword [esp + 0x2c]
push edx
push eax
push str.schannel:_Failed_to_open_cert_store__x__s__last_error_is_0x_x
push ecx
call fcn.0040e1d0
mov edx, dword [esp + 0x2c]
push edx
call dword [0x9f0294]
add esp, 0x18
mov eax, 0x3a
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
mov eax, dword [esp + 0x18]
push eax
call dword [0x9f0294]
add esp, 4
lea edx, [esp + 0x44]
lea ecx, [esp + 0xc0]
lea eax, [esp + 0xc0]
push ebx
push ebx
push edx
mov dword [esp + 0x54], ecx
mov ecx, dword [esp + 0x58]
push eax
push 4
push 0x28
push ecx
mov dword [esp + 0x60], 0x14
call dword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
push ebx
jne 0x4187df
push edi
call dword [sym.imp.CRYPT32.dll_CertCloseStore]
pop edi
pop esi
pop ebp
mov eax, 0x3a
pop ebx
add esp, 0x1c4
ret
lea edx, [esp + 0x48]
push edx
push 0x10000
push ebx
push 0x10001
push edi
call dword [sym.imp.CRYPT32.dll_CertFindCertificateInStore]
cmp eax, ebx
mov dword [esp + 0x14], eax
je 0x418869
lea eax, [esp + 0x14]
mov dword [esp + 0x60], 1
mov dword [esp + 0x64], eax
push 0
push edi
call dword [sym.imp.CRYPT32.dll_CertCloseStore]
mov ebp, dword [esp + 0x30]
mov edi, dword [esp + 0x10]
xor ebx, ebx
push 0x18
push 1
call dword [0x9f02a0]
mov ecx, dword [ebp + 8]
add esp, 8
mov dword [ecx], eax
mov edx, dword [ebp + 8]
mov eax, dword [edx]
cmp eax, ebx
jne 0x418881
push str.schannel:_unable_to_allocate_memory
push edi
call fcn.0040e1d0
mov eax, dword [esp + 0x1c]
add esp, 8
cmp eax, ebx
je 0x418859
push eax
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateContext]
pop edi
pop esi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x1c4
ret
push ebx
push edi
call dword [sym.imp.CRYPT32.dll_CertCloseStore]
pop edi
pop esi
pop ebp
mov eax, 0x3a
pop ebx
add esp, 0x1c4
ret
mov dword [eax + 0x10], 1
mov eax, dword [ebp + 8]
lea edx, [esp + 0x5c]
mov eax, dword [eax]
lea ecx, [eax + 8]
push ecx
push eax
mov eax, dword [0x9fd904]
push ebx
push ebx
push edx
push ebx
push 2
push str.Microsoft_Unified_Security_Protocol_Provider
push ebx
call dword [eax + 0xc]
mov edi, eax
mov eax, dword [esp + 0x14]
cmp eax, ebx
je 0x4188bb
push eax
call dword [sym.imp.CRYPT32.dll_CertFreeCertificateContext]
cmp edi, ebx
je 0x418930
lea ecx, [esp + 0xd4]
push 0x100
push ecx
push edi
call fcn.0043ac90
mov edx, dword [esp + 0x1c]
push eax
push str.schannel:_AcquireCredentialsHandle_failed:__s
push edx
call fcn.0040e1d0
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
push ecx
call dword [0x9f0294]
mov edx, dword [ebp + 8]
mov eax, edi
sub eax, 0x80090300
add esp, 0x1c
neg eax
sbb eax, eax
pop edi
and eax, 8
pop esi
mov dword [edx], ebx
pop ebp
add eax, 0x1b
pop ebx
add esp, 0x1c4
ret
push str.Unrecognized_parameter_passed_via_CURLOPT_SSLVERSION
push edi
call fcn.0040e1d0
add esp, 8
mov eax, 0x23
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
mov edi, dword [esp + 0x20]
lea eax, [esp + 0x98]
push eax
push edi
push 2
call fcn.0043bdb0
add esp, 0xc
test eax, eax
je 0x41895d
mov ecx, dword [esp + 0x10]
push str.schannel:_using_IP_address__SNI_is_not_supported_by_OS._n
push ecx
call fcn.0040e110
add esp, 8
push ebx
push ebx
lea edx, [esp + 0xb0]
push ebx
push edx
call fcn.00418bd0
lea eax, [esp + 0xb8]
push 1
lea ecx, [esp + 0xc8]
push eax
push ecx
call fcn.00418bf0
push ebx
push ebx
lea edx, [esp + 0x5c]
push ebx
push edx
call fcn.00418bd0
lea eax, [esp + 0x64]
push 1
lea ecx, [esp + 0xcc]
push eax
push ecx
call fcn.00418bf0
mov edx, dword [ebp + 8]
push 0x10
push 1
mov dword [edx + 0x38], 0x811c
call dword [0x9f02a0]
mov ecx, dword [ebp + 8]
add esp, 0x40
mov dword [ecx + 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 4]
cmp ecx, ebx
jne 0x4189ee
mov edx, dword [esp + 0x10]
push str.schannel:_unable_to_allocate_memory
push edx
call fcn.0040e1d0
add esp, 8
mov eax, 0x1b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
cmp edi, ebx
jne 0x418a02
pop edi
pop esi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x1c4
ret
lea edx, [ecx + 8]
push edx
lea edx, [eax + 0x3c]
push edx
lea edx, [esp + 0xa4]
push edx
push ecx
mov ecx, dword [eax + 0x4c]
lea edx, [esp + 0xc4]
neg ecx
sbb ecx, ecx
push ebx
and ecx, edx
mov edx, dword [esp + 0x34]
push ecx
mov ecx, dword [eax + 0x38]
mov eax, dword [eax]
push ebx
push ebx
push ecx
mov ecx, dword [0x9fd904]
push edx
push ebx
push eax
call dword [ecx + 0x18]
mov edi, eax
cmp edi, 0x90312
je 0x418b16
mov edx, dword [ebp + 8]
mov eax, dword [edx + 4]
push eax
call dword [0x9f0294]
mov ecx, dword [ebp + 8]
add esp, 4
cmp edi, 0x80090300
mov dword [ecx + 4], ebx
je 0x418adc
cmp edi, 0x80090322
push 0x100
je 0x418aa7
lea edx, [esp + 0xd8]
push edx
push edi
call fcn.0043ac90
push eax
mov eax, dword [esp + 0x20]
push str.schannel:_initial_InitializeSecurityContext_failed:__s
push eax
call fcn.0040e1d0
add esp, 0x18
mov eax, 0x23
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
lea ecx, [esp + 0xd8]
push ecx
push 0x80090322
call fcn.0043ac90
mov edx, dword [esp + 0x1c]
push eax
push str.schannel:_SNI_or_certificate_check_failed:__s
push edx
call fcn.0040e1d0
add esp, 0x18
mov eax, 0x3c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
lea eax, [esp + 0xd4]
push 0x100
push eax
push 0x80090300
call fcn.0043ac90
mov ecx, dword [esp + 0x1c]
push eax
push str.schannel:_initial_InitializeSecurityContext_failed:__s
push ecx
call fcn.0040e1d0
add esp, 0x18
mov eax, 0x1b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x40]
lea edx, [esp + 0x2c]
push edx
mov edx, dword [esp + 0x1e0]
push eax
push ecx
mov eax, dword [esi + edx*4 + 0x408]
push eax
push esi
call fcn.0040e560
mov ecx, dword [esp + 0x54]
mov edx, dword [0x9fd904]
add esp, 0x14
mov esi, eax
push ecx
call dword [edx + 0x40]
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x38]
cmp esi, ebx
jne 0x418b89
cmp ecx, eax
jne 0x418b89
mov eax, dword [ebp + 8]
pop edi
pop esi
mov dword [eax + 0x40], ebx
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x44], ebx
mov edx, dword [ebp + 8]
mov dword [edx + 0x48], ebx
mov eax, dword [ebp + 8]
mov dword [eax + 0x34], ebx
mov dword [ebp + 4], 1
pop ebp
xor eax, eax
pop ebx
add esp, 0x1c4
ret
push ecx
mov ecx, dword [esp + 0x14]
push eax
push str.schannel:_failed_to_send_initial_handshake_data:_sent__zd_of__lu_bytes
push ecx
call fcn.0040e1d0
add esp, 0x10
mov eax, 0x23
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret