Function at 0x4161fd
Capabilities:
Initialize winhttp library
Prepare http request
Read http header
Receive http response

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2d8
mov eax, dword [0x470008]
xor eax, ebp
mov dword [ebp - 8], eax
xor eax, eax
mov dword [ebp - 0x288], edx
mov dword [ebp - 0x274], eax
mov dword [ebp - 0x270], eax
mov dword [ebp - 0x26c], eax
mov dword [ebp - 0x224], eax
mov dword [ebp - 0x220], eax
mov dword [ebp - 0x218], eax
mov dword [ebp - 0x22c], eax
mov dword [ebp - 0x228], eax
mov dword [ebp - 0x238], eax
mov dword [ebp - 0x230], eax
mov dword [ebp - 0x23c], eax
mov dword [ebp - 0x250], eax
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x234], ebx
mov dword [ebp - 0x278], ecx
push esi
mov esi, eax
mov dword [ebp - 0x21c], esi
push edi
mov edi, eax
mov dword [ebp - 0x280], edi
test edx, edx
jne 0x41629b
mov ecx, 0x80070057
mov ebx, ecx
call fcn.0041802b
jmp 0x4168f5
test ebx, ebx
je 0x41628a
test ecx, ecx
je 0x41628a
push 0x3c
lea eax, [ebp - 0x2d4]
push 0
push eax
call sub.msvcrt.dll_memset
or dword [ebp - 0x2c0], 0xffffffff
lea eax, [ebp - 0x2d4]
or dword [ebp - 0x2a4], 0xffffffff
add esp, 0xc
mov dword [ebp - 0x2d4], 0x3c
push eax
push 0
push 0
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpCrackUrl]
test eax, eax
jne 0x4162f7
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.00417d89
mov ebx, eax
mov ecx, ebx
jmp 0x416291
push ecx
mov ecx, dword [ebp - 0x2c4]
lea eax, [ebp - 0x274]
push eax
push 0x2f
pop edx
call fcn.0041827e
mov ebx, eax
test ebx, ebx
js 0x4162f3
xor eax, eax
mov esi, 0x406f9c
cmp dword [ebp - 0x2c8], 2
sete al
mov dword [ebp - 0x27c], eax
test eax, eax
jne 0x416333
mov esi, 0x406fa8
xor ebx, ebx
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
movzx eax, word [ebp - 0x2bc]
push 0x406f7c
push ecx
push 0x10d
push ebx
push ecx
push esi
push eax
push 0x406fb4
push 0x4000000
call fcn.00414773
add esp, 0x10
xor edx, edx
mov ecx, eax
call fcn.00448387
push ebx
push ebx
push ebx
inc ebx
push ebx
push 0x406fd0
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
push eax
lea ecx, [ebp - 0x21c]
call fcn.00414c6b
mov esi, dword [ebp - 0x21c]
test esi, esi
je 0x4162e4
xor eax, eax
push eax
push eax
push eax
push eax
push 0x406fd0
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
push eax
lea ecx, [ebp - 0x224]
call fcn.00414c6b
cmp dword [ebp - 0x224], edi
je 0x4162e4
xor eax, eax
lea edi, [ebp - 0x248]
stosd dword es:[edi], eax
xor esi, esi
push 6
pop ecx
mov dword [ebp - 0x284], esi
stosd dword es:[edi], eax
stosd dword es:[edi], eax
xor eax, eax
lea edi, [ebp - 0x268]
rep stosd dword es:[edi], eax
lea edi, [ebp - 0x298]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [ebp - 0x298]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpGetIEProxyConfigForCurrentUser]
test eax, eax
je 0x416532
cmp dword [ebp - 0x298], 0
mov ecx, dword [ebp - 0x294]
mov esi, ecx
mov eax, dword [ebp - 0x28c]
mov edi, dword [ebp - 0x290]
mov dword [ebp - 0x238], esi
mov dword [ebp - 0x230], eax
je 0x416482
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
push 0x406f7c
push ecx
push 0x132
push 0
push ecx
push 0x406ffc
push 0x4000000
call fcn.00414773
pop ecx
pop ecx
xor edx, edx
mov ecx, eax
call fcn.00448387
mov ecx, dword [ebp - 0x294]
mov eax, ebx
mov dword [ebp - 0x268], ebx
mov dword [ebp - 0x264], 3
mov dword [ebp - 0x254], ebx
jmp 0x416488
mov eax, dword [ebp - 0x284]
test ecx, ecx
je 0x4164d6
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
push 0x406f7c
push ecx
push 0x13e
push 0
push ecx
push 0x407018
push 0x4000000
call fcn.00414773
pop ecx
pop ecx
xor edx, edx
mov ecx, eax
call fcn.00448387
or dword [ebp - 0x268], 2
mov eax, ebx
mov dword [ebp - 0x260], esi
mov dword [ebp - 0x254], ebx
test eax, eax
jne 0x41658c
test edi, edi
jne 0x416815
push edi
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
mov esi, 0x4000000
push 0x406f7c
push ecx
push 0x14a
push edi
push ecx
push 0x407038
push esi
call fcn.00414773
pop ecx
pop ecx
xor edx, edx
mov ecx, eax
call fcn.00448387
mov dword [ebp - 0x268], ebx
mov dword [ebp - 0x264], 3
mov dword [ebp - 0x254], ebx
jmp 0x416591
push esi
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
push 0x406f7c
push ecx
push 0x156
push esi
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x407050
mov esi, 0x4000000
push esi
call fcn.00414773
add esp, 0xc
xor edx, edx
mov ecx, eax
call fcn.00448387
mov edi, dword [ebp - 0x280]
mov dword [ebp - 0x268], ebx
mov dword [ebp - 0x264], 3
mov dword [ebp - 0x254], ebx
jmp 0x416591
mov esi, 0x4000000
xor ebx, ebx
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
push 0x406f7c
push ecx
push 0x163
push ebx
push ecx
push 0x407080
push esi
call fcn.00414773
pop ecx
pop ecx
xor edx, edx
mov ecx, eax
call fcn.00448387
lea eax, [ebp - 0x248]
push eax
lea eax, [ebp - 0x268]
push eax
push dword [ebp - 0x234]
push dword [ebp - 0x224]
call dword [sym.imp.WINHTTP.dll_WinHttpGetProxyForUrl]
test eax, eax
je 0x41661f
mov eax, dword [ebp - 0x244]
mov dword [ebp - 0x23c], eax
mov eax, dword [ebp - 0x240]
mov dword [ebp - 0x250], eax
mov esi, dword [ebp - 0x21c]
lea eax, [ebp - 0x248]
push 0xc
push eax
push 0x26
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
test eax, eax
jne 0x416693
jmp 0x4162e4
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
push 0x406f7c
push ecx
push 0x17e
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x407094
push esi
call fcn.00414773
add esp, 0xc
xor edx, edx
mov ecx, eax
call fcn.00448387
test edi, edi
jne 0x41681c
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
push 0x406f7c
push ecx
push 0x199
push ebx
push ecx
push 0x4070e0
push esi
call fcn.00414773
pop ecx
pop ecx
xor edx, edx
mov ecx, eax
call fcn.00448387
mov esi, dword [ebp - 0x21c]
mov eax, dword [ebp - 0x26c]
push ebx
push dword [ebp - 0x2bc]
push dword [eax]
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
push eax
lea ecx, [ebp - 0x220]
call fcn.00414c6b
cmp dword [ebp - 0x220], 0
je 0x4162e4
mov eax, dword [ebp - 0x27c]
neg eax
sbb eax, eax
and eax, 0x800000
push eax
push ebx
push ebx
push ebx
push dword [ebp - 0x2a8]
push 0x4070fc
push dword [ebp - 0x220]
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
push eax
lea ecx, [ebp - 0x218]
call fcn.00414c6b
cmp dword [ebp - 0x218], 0
je 0x4162e4
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push dword [ebp - 0x218]
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
je 0x4162e4
push ebx
push dword [ebp - 0x218]
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x4162e4
push 0x208
lea eax, [ebp - 0x214]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
mov dword [ebp - 0x24c], 0x206
lea eax, [ebp - 0x24c]
push ebx
push eax
lea eax, [ebp - 0x214]
push eax
push ebx
push 0x36
push dword [ebp - 0x218]
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
je 0x4162e4
mov eax, dword [ebp - 0x24c]
and eax, 0xfffffffe
cmp eax, 0x208
jae 0x4169e0
xor ecx, ecx
lea edx, [ebp - 0x228]
mov word [ebp + eax - 0x214], cx
lea ecx, [ebp - 0x214]
call fcn.00417dc4
mov ebx, eax
test ebx, ebx
js 0x4162f3
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, dword [ebp - 0x234]
push eax
push dword [ebp + 4]
lea eax, [ebp - 0x214]
push 0x406f7c
push ecx
push 0x1c4
push 0
push ecx
push eax
push ebx
push 0x407108
push 0x4000000
call fcn.00414773
add esp, 0x10
xor edx, edx
mov ecx, eax
call fcn.00448387
lea edx, [ebp - 0x22c]
mov ecx, ebx
call fcn.004160fd
mov ebx, eax
test ebx, ebx
jns 0x41686c
mov ecx, ebx
call fcn.0041802b
jmp 0x4168ef
xor ebx, ebx
mov esi, 0x4000000
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
push 0x406f7c
push ecx
push 0x185
push ebx
push ecx
push 0x4070c8
push esi
call fcn.00414773
pop ecx
pop ecx
xor edx, edx
mov ecx, eax
call fcn.00448387
mov eax, dword [ebp - 0x230]
mov dword [ebp - 0x248], 3
mov dword [ebp - 0x244], edi
mov dword [ebp - 0x240], eax
jmp 0x4165fe
mov ecx, dword [ebp - 0x22c]
xor esi, esi
inc esi
test ecx, ecx
je 0x4168d2
push 0xffffffffffffffff
lea eax, [ebp - 0x214]
push eax
push 0xffffffffffffffff
push ecx
push esi
push 0x409
call dword [sym.imp.KERNEL32.dll_CompareStringW]
dec eax
dec eax
jne 0x4168d2
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 4]
push 0x406f7c
push ecx
push 0x1cb
push 0
push ecx
push dword [ebp - 0x234]
push 0x407120
push 0x4000000
call fcn.00414773
add esp, 0xc
xor edx, edx
mov ecx, eax
call fcn.00448387
xor esi, esi
mov eax, dword [ebp - 0x288]
mov ecx, dword [ebp - 0x278]
mov dword [eax], esi
mov eax, dword [ebp - 0x228]
and dword [ebp - 0x228], 0
mov dword [ecx], eax
mov esi, dword [ebp - 0x21c]
mov ecx, ebx
call fcn.00418048
mov eax, dword [ebp - 0x250]
test eax, eax
je 0x41690d
push eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [ebp - 0x23c]
test eax, eax
je 0x41691e
push eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [ebp - 0x230]
test eax, eax
je 0x41692f
push eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
test edi, edi
je 0x41693a
push edi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [ebp - 0x238]
test eax, eax
je 0x41694b
push eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov ecx, dword [ebp - 0x228]
test ecx, ecx
je 0x41695a
call fcn.00417eee
mov ecx, dword [ebp - 0x22c]
test ecx, ecx
je 0x416969
call fcn.00417eee
cmp dword [ebp - 0x218], 0
je 0x41697e
push dword [ebp - 0x218]
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
cmp dword [ebp - 0x220], 0
je 0x416993
push dword [ebp - 0x220]
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
cmp dword [ebp - 0x224], 0
je 0x4169a8
push dword [ebp - 0x224]
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
test esi, esi
je 0x4169b3
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
push 0
lea ecx, [ebp - 0x274]
call fcn.0041cdf0
lea ecx, [ebp - 0x26c]
call fcn.0041543f
mov ecx, dword [ebp - 8]
mov eax, ebx
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00450290
mov esp, ebp
pop ebp
ret 4
call fcn.00450675
int3