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

Disassembly:
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x18], r8
mov dword [rsp + 0x10], edx
mov qword [rsp + 8], rcx
sub rsp, 0x98
mov dword [rsp + 0x40], 0
mov ecx, 0x2000
call fcn.180050ef0
mov qword [rsp + 0x78], rax
mov rax, qword [rsp + 0x78]
mov qword [rsp + 0x68], rax
mov ecx, 0x2000
call fcn.180050ef0
mov qword [rsp + 0x80], rax
mov rax, qword [rsp + 0x80]
mov qword [rsp + 0x70], rax
mov dword [rsp + 0x28], 0x1000
mov rax, qword [rsp + 0x68]
mov qword [rsp + 0x20], rax
mov r9d, 0xffffffff
mov r8, qword [rsp + 0xa0]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov dword [rsp + 0x28], 0x1000
mov rax, qword [rsp + 0x70]
mov qword [rsp + 0x20], rax
mov r9d, 0xffffffff
mov r8, qword [rsp + 0xb0]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov dword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
mov edx, 1
lea rcx, str.ROWE_Twain_Driver_1.0
call qword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov rcx, qword [rsp + 0xc0]
mov qword [rcx], rax
mov rax, qword [rsp + 0xc0]
cmp qword [rax], 0
je 0x180021bb2
mov dword [rsp + 0x20], 0x1388
mov r9d, 0x1388
mov r8d, 0x1388
mov edx, 0x1388
mov rax, qword [rsp + 0xc0]
mov rcx, qword [rax]
call qword [sym.imp.WINHTTP.dll_WinHttpSetTimeouts]
test eax, eax
jne 0x180021b79
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, str.Error__u_in_WinHttpSetTimeouts._n
call fcn.1800182f0
movzx eax, word [rsp + 0xa8]
mov word [rsp + 0x44], ax
xor r9d, r9d
movzx r8d, word [rsp + 0x44]
mov rdx, qword [rsp + 0x68]
mov rax, qword [rsp + 0xc0]
mov rcx, qword [rax]
call qword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov rcx, qword [rsp + 0xc8]
mov qword [rcx], rax
jmp 0x180021bcc
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x58], eax
mov edx, dword [rsp + 0x58]
lea rcx, str.WinHttpOpen_returned_NULL_handle___last_error:__i_n
call fcn.1800182f0
mov rax, qword [rsp + 0xc8]
cmp qword [rax], 0
je 0x180021c3e
mov dword [rsp + 0x50], 0x800000
cmp dword [rsp + 0xa8], 0x1bb
je 0x180021bf7
mov dword [rsp + 0x50], 0
mov eax, dword [rsp + 0x50]
mov dword [rsp + 0x30], eax
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
xor r9d, r9d
mov r8, qword [rsp + 0x70]
lea rdx, [0x180083620]
mov rax, qword [rsp + 0xc8]
mov rcx, qword [rax]
call qword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov rcx, qword [rsp + 0xb8]
mov qword [rcx], rax
jmp 0x180021c58
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x5c], eax
mov edx, dword [rsp + 0x5c]
lea rcx, str.WinHttpConnect_returned_NULL_handle___last_error:__i_n
call fcn.1800182f0
mov rax, qword [rsp + 0xb8]
cmp qword [rax], 0
je 0x180021d47
mov dword [rsp + 0x60], 0x1100
mov r9d, 4
lea r8, [rsp + 0x60]
mov edx, 0x1f
mov rax, qword [rsp + 0xb8]
mov rcx, qword [rax]
call qword [sym.imp.WINHTTP.dll_WinHttpSetOption]
mov dword [rsp + 0x40], eax
cmp dword [rsp + 0x40], 0
jne 0x180021cd4
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x48], eax
cmp dword [rsp + 0x48], 0x2ee2
jne 0x180021cc4
mov edx, dword [rsp + 0x48]
lea rcx, str.TIMEOUT___u__in_WinHttpSetOption_n
call fcn.1800182f0
jmp 0x180021cd4
mov edx, dword [rsp + 0x48]
lea rcx, str.ERROR___u__in_WinHttpSetOption_n
call fcn.1800182f0
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov dword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rax, qword [rsp + 0xb8]
mov rcx, qword [rax]
call qword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
mov dword [rsp + 0x40], eax
cmp dword [rsp + 0x40], 0
jne 0x180021d47
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x4c], eax
cmp dword [rsp + 0x4c], 0x2ee2
jne 0x180021d37
mov edx, dword [rsp + 0x4c]
lea rcx, str.TIMEOUT___u__in_WinHttpSendRequest_n
call fcn.1800182f0
jmp 0x180021d47
mov edx, dword [rsp + 0x4c]
lea rcx, str.ERROR___u__in_WinHttpSendRequest_n
call fcn.1800182f0
cmp dword [rsp + 0x40], 0
je 0x180021d67
xor edx, edx
mov rax, qword [rsp + 0xb8]
mov rcx, qword [rax]
call qword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
mov dword [rsp + 0x40], eax
jmp 0x180021d81
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x54], eax
mov edx, dword [rsp + 0x54]
lea rcx, str.Error__u_in_WinHttpReceiveResponse_n
call fcn.1800182f0
mov eax, dword [rsp + 0x40]
add rsp, 0x98
ret