Function at 0x5521a0
Capabilities:
Initialize winhttp library
Prepare http request
Receive http response
Reference cloudflare dns server
Set http header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
push ebx
push esi
xor ebx, ebx
push edi
mov dword [ebp - 8], ebx
mov dword [ebp - 0x18], ebx
call fcn.00552080
test al, al
jne 0x5521c5
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov ax, 1
lock xadd word [0x6364e4], ax
inc ax
push 0x1000
push 4
push dword [0x636044]
movzx esi, ax
mov dword [ebp - 0x10], esi
mov dword [ebp - 4], 0x1000
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
push 1
push esi
push dword [ebp + 0x10]
mov esi, dword [0x6383e4]
mov edi, eax
push dword [ebp + 0xc]
lea eax, [ebp - 4]
mov dword [ebp - 0xc], edi
push eax
push edi
mov ecx, esi
call dword [0x5a48f4]
call esi
test eax, eax
setne cl
test eax, eax
jne 0x552270
push edi
push eax
push dword [0x636044]
call dword [sym.imp.ntdll.dll_RtlFreeHeap]
push dword ds:[ebp - 4]
push 4
push dword [0x636044]
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov esi, dword [0x6383e4]
mov edi, eax
push 1
push dword [ebp - 0x10]
mov dword [ebp - 0xc], eax
mov ecx, esi
push dword [ebp + 0x10]
lea eax, [ebp - 4]
push dword [ebp + 0xc]
push eax
push edi
call dword [0x5a48f4]
call esi
test eax, eax
setne cl
test cl, cl
je 0x552549
test byte [0x633634], 1
mov edi, str.1.1.1.1
mov eax, dword [ebp - 4]
mov esi, dword [ebp + 8]
mov dword [ebp - 0x30], eax
jne 0x5523d9
mov ecx, 0x633634
lock bts dword [ecx], 0x1f
setb al
test al, al
je 0x5522bd
test byte [0x633634], 1
jne 0x5523d9
xor edx, edx
call sym.SystemInformer.exe_PhfWaitForEvent
jmp 0x5523d9
cmp dword [0x62fbb0], 0x3f
push 0
sbb eax, eax
push 0
and eax, 0xfffffffc
push 0
add eax, 4
push eax
push 0
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov dword [0x6383f0], eax
test eax, eax
je 0x5523cf
cmp dword [0x62fbb0], 0x3f
push 4
jae 0x552303
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x14], 0xa00
push ecx
push 0x54
push eax
jmp 0x55237d
lea ecx, [ebp - 0x1c]
mov dword [ebp - 0x1c], 0x2800
push ecx
push 0x54
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
push 4
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 3
push eax
push 0x76
push dword [0x6383f0]
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
mov eax, dword [0x62fbb0]
cmp eax, 0x64
jb 0x55235f
push 4
lea eax, [ebp - 0x24]
mov dword [ebp - 0x24], 1
push eax
push 0x85
push dword [0x6383f0]
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
mov eax, dword [0x62fbb0]
nop
cmp eax, 0x72
jb 0x552386
push 4
lea eax, [ebp - 0x28]
mov dword [ebp - 0x28], 1
push eax
push 0xc3
push dword [0x6383f0]
lea ecx, [ecx]
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
push 4
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], 1
push eax
push 0x49
push dword [0x6383f0]
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
cmp dword [0x62fbb0], 0x64
jb 0x5523cf
push 0
test esi, esi
mov eax, edi
push 0x1bb
cmovne eax, esi
push eax
push dword [0x6383f0]
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov dword [0x6383f4], eax
mov ecx, 0x633634
call sym.SystemInformer.exe_PhfEndInitOnce
cmp dword [0x62fbb0], 0x64
jae 0x552402
push 0
test esi, esi
push 0x1bb
cmovne edi, esi
push edi
push dword [0x6383f0]
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov dword [0x6383f4], eax
jmp 0x552407
mov eax, dword [0x6383f4]
test eax, eax
je 0x55253f
push 0x800000
push 0x63362c
push 0
push 0
push str._dns_query
push str.POST
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov edi, eax
test edi, edi
je 0x55253f
push 0xa0000000
push 0xffffffffffffffff
push str.Content_Type:_application_dns_message
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpAddRequestHeaders]
cmp dword [0x62fbb0], 0x3e
ja 0x55246a
push 4
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], 0x1000
push eax
push 0x1f
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
mov eax, dword [ebp - 0x30]
push 0
push eax
push eax
push dword [ebp - 0xc]
push 0
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
nop
test eax, eax
je 0x552525
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x552525
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 8]
push eax
push edi
call sym.SystemInformer.exe_PhHttpSocketReadDataToBuffer
test al, al
je 0x552522
mov esi, dword [ebp - 0x30]
mov dword [ebp - 0x14], ebx
cmp esi, 0xffff
ja 0x552522
mov ebx, dword [ebp - 8]
movzx eax, word [ebx]
mov dh, al
mov dl, ah
movzx eax, word [ebx + 4]
mov ch, al
mov word [ebx], dx
mov cl, ah
movzx eax, word [ebx + 6]
mov word [ebx + 4], cx
mov ch, al
mov cl, ah
movzx eax, word [ebx + 8]
mov word [ebx + 6], cx
mov ch, al
mov cl, ah
movzx eax, word [ebx + 0xa]
mov word [ebx + 8], cx
mov ch, al
mov cl, ah
mov word [ebx + 0xa], cx
cmp dx, word [ebp - 0x10]
jne 0x552525
lea eax, [ebp - 0x14]
push eax
push esi
mov esi, dword [0x6383e8]
mov ecx, esi
push ebx
call dword [0x5a48f4]
call esi
mov eax, dword ds:[ebp - 0x14]
xor ecx, ecx
test eax, eax
cmovne ecx, eax
mov dword [ebp - 0x18], ecx
jmp 0x552525
mov ebx, dword [ebp - 8]
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
test ebx, ebx
je 0x55253f
push ebx
push 0
push dword [0x636044]
call dword [sym.imp.ntdll.dll_RtlFreeHeap]
mov eax, dword [ebp - 0xc]
test eax, eax
je 0x55255c
push eax
jmp 0x55254e
test edi, edi
je 0x55255c
push edi
push 0
push dword [0x636044]
call dword [sym.imp.ntdll.dll_RtlFreeHeap]
mov eax, dword [ebp - 0x18]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc