Function at 0x140033070
Capabilities:
Initialize winhttp library
Prepare http request
Receive http response

Disassembly:
push rbx
push rbp
push r15
sub rsp, 0x80
mov rbx, rcx
xor r15d, r15d
lea rcx, str.A_WinHTTP_Example_1.0
mov dword [rsp + 0x20], r15d
xor r9d, r9d
xor r8d, r8d
xor edx, edx
call qword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov rbp, rax
test rax, rax
jne 0x140033112
xorps xmm0, xmm0
lea ecx, [rax + 0x30]
movups xmmword [rbx], xmm0
mov qword [rbx + 0x10], r15
mov qword [rbx + 0x18], reloc.WS2_32.dll_ntohs
call fcn.14009acb8
mov qword [rbx], rax
mov rcx, rax
mov qword [rbx + 0x10], Ordinal_45
mov qword [rbx + 0x18], Ordinal_50
movups xmm0, xmmword [str.Error:_WinHTTP_session_failed_to_initialize.]
movups xmmword [rax], xmm0
movups xmm1, xmmword [0x1400b6e10]
movups xmmword [rax + 0x10], xmm1
movsd xmm0, qword [0x1400b6e20]
movsd qword [rax + 0x20], xmm0
mov eax, dword [0x1400b6e28]
mov dword [rcx + 0x28], eax
mov rax, rbx
mov byte [rcx + 0x2c], r15b
add rsp, 0x80
pop r15
pop rbp
pop rbx
ret
mov r8d, 0x50
mov qword [rsp + 0x70], r14
xor r9d, r9d
lea rdx, str.api.ipify.org
mov rcx, rbp
call qword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov r14, rax
test rax, rax
jne 0x140033197
mov rcx, rbp
call qword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
xorps xmm0, xmm0
lea ecx, [r14 + 0x30]
movups xmmword [rbx], xmm0
mov qword [rbx + 0x10], r15
mov qword [rbx + 0x18], reloc.WS2_32.dll_ntohs
call fcn.14009acb8
mov qword [rbx], rax
mov qword [rbx + 0x10], reloc.WLDAP32.dll_Ordinal_33
mov qword [rbx + 0x18], Ordinal_50
movups xmm0, xmmword [str.Error:_WinHTTP_connection_failed.]
movups xmmword [rax], xmm0
movups xmm1, xmmword [0x1400b6e60]
movups xmmword [rax + 0x10], xmm1
movzx ecx, byte [reloc.WLDAP32.dll_Ordinal_46]
mov byte [rax + 0x20], cl
mov byte [rax + 0x21], r15b
jmp 0x140033369
mov dword [rsp + 0x30], r15d
lea r8, [0x1400b6e74]
mov qword [rsp + 0x28], r15
lea rdx, [0x1400b6e78]
xor r9d, r9d
mov qword [rsp + 0x20], r15
mov rcx, r14
mov qword [rsp + 0xa0], rsi
call qword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov rsi, rax
test rax, rax
jne 0x140033246
mov rcx, r14
call qword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov rcx, rbp
call qword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
xorps xmm0, xmm0
lea ecx, [rsi + 0x20]
movups xmmword [rbx], xmm0
mov qword [rbx + 0x10], r15
mov qword [rbx + 0x18], reloc.WS2_32.dll_ntohs
call fcn.14009acb8
mov qword [rbx], rax
mov rdx, rax
mov qword [rbx + 0x10], reloc.WLDAP32.dll_Ordinal_30
mov qword [rbx + 0x18], Ordinal_35
movups xmm0, xmmword [str.Error:_WinHTTP_request_failed.]
movups xmmword [rax], xmm0
movsd xmm0, qword [0x1400b6e90]
movsd qword [rax + 0x10], xmm0
mov ecx, dword [0x1400b6e98]
mov dword [rax + 0x18], ecx
movzx eax, word [0x1400b6e9c]
mov word [rdx + 0x1c], ax
mov byte [rdx + 0x1e], r15b
jmp 0x140033361
mov qword [rsp + 0x30], r15
xor r9d, r9d
mov dword [rsp + 0x28], r15d
xor r8d, r8d
xor edx, edx
mov dword [rsp + 0x20], r15d
mov rcx, rsi
call qword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
je 0x14003349d
xor edx, edx
mov rcx, rsi
call qword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x14003343a
lea rdx, [rsp + 0xa8]
mov dword [rsp + 0xb0], r15d
mov rcx, rsi
mov dword [rsp + 0xa8], r15d
call qword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
je 0x1400333e0
mov ecx, dword [rsp + 0xa8]
inc ecx
mov qword [rsp + 0x78], rdi
call fcn.14009af68
mov r8d, dword [rsp + 0xa8]
xor edx, edx
inc r8d
mov rcx, rax
mov rdi, rax
call sub.VCRUNTIME140.dll_memset
mov r8d, dword [rsp + 0xa8]
lea r9, [rsp + 0xb0]
mov rdx, rdi
mov rcx, rsi
call qword [sym.imp.WINHTTP.dll_WinHttpReadData]
xorps xmm0, xmm0
test eax, eax
je 0x14003337d
movups xmmword [rsp + 0x48], xmm0
mov qword [rsp + 0x58], r15
mov r8, 0xffffffffffffffff
mov qword [rsp + 0x60], r15
inc r8
cmp byte [rdi + r8], r15b
jne 0x140033312
mov rdx, rdi
lea rcx, [rsp + 0x48]
call fcn.1400386a0
mov rcx, rdi
call fcn.14009ab20
mov rcx, rsi
call qword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov rcx, r14
call qword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov rcx, rbp
call qword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
movups xmm0, xmmword [rsp + 0x48]
movups xmm1, xmmword [rsp + 0x58]
movups xmmword [rbx], xmm0
movups xmmword [rbx + 0x10], xmm1
mov rdi, qword [rsp + 0x78]
mov rsi, qword [rsp + 0xa0]
mov r14, qword [rsp + 0x70]
mov rax, rbx
add rsp, 0x80
pop r15
pop rbp
pop rbx
ret
movups xmmword [rbx], xmm0
mov ecx, reloc.WLDAP32.dll_Ordinal_32
mov qword [rbx + 0x10], r15
mov qword [rbx + 0x18], reloc.WS2_32.dll_ntohs
call fcn.14009acb8
mov qword [rbx], rax
mov rdx, rax
mov qword [rbx + 0x10], reloc.WLDAP32.dll_Ordinal_30
mov qword [rbx + 0x18], Ordinal_35
movups xmm0, xmmword [str.Error:_WinHttpReadData_failed.]
movups xmmword [rax], xmm0
movsd xmm0, qword [0x1400b6ee0]
movsd qword [rax + 0x10], xmm0
mov ecx, dword [0x1400b6ee8]
mov dword [rax + 0x18], ecx
movzx eax, word [0x1400b6eec]
mov word [rdx + 0x1c], ax
mov byte [rdx + 0x1e], r15b
jmp 0x14003335c
xorps xmm0, xmm0
mov ecx, Ordinal_50
movups xmmword [rbx], xmm0
mov qword [rbx + 0x10], r15
mov qword [rbx + 0x18], reloc.WS2_32.dll_ntohs
call fcn.14009acb8
mov qword [rbx], rax
mov qword [rbx + 0x10], Ordinal_45
mov qword [rbx + 0x18], Ordinal_50
movups xmm0, xmmword [str.Error:_WinHttpQueryDataAvailable_failed.]
movups xmmword [rax], xmm0
movups xmm1, xmmword [0x1400b6eb0]
movups xmmword [rax + 0x10], xmm1
movsd xmm0, qword [0x1400b6ec0]
movsd qword [rax + 0x20], xmm0
mov byte [rax + 0x28], r15b
jmp 0x140033361
xorps xmm0, xmm0
mov ecx, Ordinal_50
movups xmmword [rbx], xmm0
mov qword [rbx + 0x10], r15
mov qword [rbx + 0x18], reloc.WS2_32.dll_ntohs
call fcn.14009acb8
mov qword [rbx], rax
mov rdx, rax
mov qword [rbx + 0x10], Ordinal_41
mov qword [rbx + 0x18], Ordinal_50
movups xmm0, xmmword [str.Error:_WinHttpReceiveResponse_failed.]
movups xmmword [rax], xmm0
movups xmm1, xmmword [0x1400b6f00]
movups xmmword [rax + 0x10], xmm1
mov ecx, dword [0x1400b6f10]
mov dword [rax + 0x20], ecx
movzx eax, byte [reloc.WLDAP32.dll_Ordinal_46]
mov byte [rdx + 0x24], al
mov byte [rdx + 0x25], r15b
jmp 0x140033361
xorps xmm0, xmm0
mov ecx, Ordinal_50
movups xmmword [rbx], xmm0
mov qword [rbx + 0x10], r15
mov qword [rbx + 0x18], reloc.WS2_32.dll_ntohs
call fcn.14009acb8
mov qword [rbx], rax
mov qword [rbx + 0x10], reloc.WLDAP32.dll_Ordinal_33
mov qword [rbx + 0x18], Ordinal_50
movups xmm0, xmmword [str.Error:_WinHttpSendRequest_failed.]
movups xmmword [rax], xmm0
movups xmm1, xmmword [0x1400b6f28]
movups xmmword [rax + 0x10], xmm1
movzx ecx, byte [reloc.WLDAP32.dll_Ordinal_46]
mov byte [rax + 0x20], cl
mov byte [rax + 0x21], r15b
jmp 0x140033361