Function at 0x10006af0
Capabilities:
Check http status code
Initialize winhttp library
Prepare http request
Read http header
Receive http response
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x4c34
call fcn.1001a150
mov eax, dword [0x10029494]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edx, str.ENTERING________________________________________________________________________EHCreateFolderOnServerNeo
mov esi, 0x1002c2c8
call fcn.10001830
call fcn.1000aa60
mov ecx, 0x1002b2c0
call fcn.10009a30
test eax, eax
jne 0x10006b53
mov edx, str.ERROR____________________The_GetServerUploadFolderName_Failed
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push 0x1002b2c0
lea eax, [ebp - 0x3408]
push 0x400
push eax
call fcn.1000bb31
add esp, 0xc
push str.FolderToCreate
lea ecx, [ebp - 0x2408]
push 0x400
push ecx
call fcn.1000bb31
add esp, 0xc
lea edx, [ebp - 0x3408]
push edx
lea eax, [ebp - 0x2408]
push 0x400
push eax
call fcn.1000c903
add esp, 0xc
push 0
push 0
push 0
push 0
push str.OTPDoQuery
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov ebx, eax
mov dword [ebp - 0x4c24], ebx
test ebx, ebx
jne 0x10006beb
mov edx, str.ERROR___________________hSession__WinHttpOpen__NULL
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push 0x186a0
push 0x186a0
push 0x186a0
push 0x186a0
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpSetTimeouts]
test eax, eax
jne 0x10006c3d
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov edx, str.ERROR___________________bResults__WinHttpSetTimeouts__FALSE
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push 0x1002bac0
lea ecx, [ebp - 0x4c08]
push 0x400
push ecx
call fcn.1000bb31
add esp, 0xc
push 0
push 0x1bb
lea edx, [ebp - 0x4c08]
push edx
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov esi, eax
mov dword [ebp - 0x4c20], esi
test esi, esi
jne 0x10006caa
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov edx, str.ERROR___________________hConnect__WinHttpConnect__NULL
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push str._downloads_uploadf.php
lea eax, [ebp - 0x4408]
push 0x400
push eax
call fcn.1000bb31
add esp, 0xc
lea ecx, [ebp - 0x4408]
push ecx
lea edx, [ebp - 0x3c08]
push 0x400
push edx
call fcn.1000bb31
add esp, 0xc
push 0x800000
push 0
push 0
push 0
lea eax, [ebp - 0x3c08]
push eax
push str.POST
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov edi, eax
test edi, edi
jne 0x10006d3a
mov edi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
push ebx
call edi
push esi
call edi
mov edx, str.ERROR___________________hRequest__WinHttpOpenRequest__NULL
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push 4
lea ecx, [ebp - 0x4c2c]
push ecx
push 0x1f
push edi
mov dword [ebp - 0x4c2c], 0x3300
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
test eax, eax
jne 0x10006d95
push ebx
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call ebx
push esi
call ebx
push edi
call ebx
mov edx, str.ERROR___________________bResults__WinHttpSetOption__NULL
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push str.Content_Type:_application_x_www_form_urlencoded
lea edx, [ebp - 0x1408]
push 0x400
push edx
call fcn.1000bb31
lea eax, [ebp - 0x2408]
add esp, 0xc
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x10006db7
sub eax, edx
sar eax, 1
inc eax
push eax
lea eax, [ebp - 0x2408]
push eax
push 0x400
lea ecx, [ebp - 0x408]
push ecx
lea edx, [ebp - 0x4c30]
push edx
call fcn.1000c8e3
lea eax, [ebp - 0x1408]
add esp, 0x14
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x10006df3
sub eax, edx
lea ecx, [ebp - 0x408]
lea edx, [ecx + 1]
sar eax, 1
mov dword [ebp - 0x4c0c], edx
mov dl, byte [ecx]
inc ecx
test dl, dl
jne 0x10006e11
sub ecx, dword [ebp - 0x4c0c]
push 0
lea edx, [ecx + eax]
push edx
push ecx
lea ecx, [ebp - 0x408]
push ecx
push eax
lea edx, [ebp - 0x1408]
push edx
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
jne 0x10006e7a
push ebx
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call ebx
push esi
call ebx
push edi
call ebx
mov edx, str.ERROR___________________bResults__WinHttpSendRequest__FALSE
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
jne 0x10006ec2
push ebx
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call ebx
push esi
call ebx
push edi
call ebx
mov edx, str.ERROR___________________bResults__WinHttpReceiveResponse__FALSE
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push 0
lea eax, [ebp - 0x4c28]
push eax
lea ecx, [ebp - 0x4c18]
push ecx
push 0
push 0x20000013
push edi
mov dword [ebp - 0x4c18], 0
mov dword [ebp - 0x4c28], 4
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
jne 0x10006f33
push ebx
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call ebx
push esi
call ebx
push edi
call ebx
mov edx, str.ERROR___________________bResults__WinHttpQueryHeaders__FALSE
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x4c18], 0xc8
je 0x10006f7a
push ebx
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call ebx
push esi
call ebx
push edi
call ebx
mov edx, str.ERROR___________________dwStatusCode___HTTP_STATUS_OK
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
cmp byte [0x1002f2d4], 0
je 0x10006fa5
push ebx
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call ebx
push esi
call ebx
push edi
call ebx
mov al, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
push 0x1002d2c8
lea edx, [ebp - 0x2c08]
push 0x400
push edx
call fcn.1000bb31
add esp, 0xc
lea eax, [ebp - 0x2c08]
push eax
lea ecx, [ebp - 0xc08]
push 0x400
push ecx
call fcn.1000bb31
add esp, 0xc
push str._responsefilefolder.txt
lea edx, [ebp - 0xc08]
push 0x400
push edx
call fcn.1000c903
add esp, 0xc
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
lea eax, [ebp - 0xc08]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x4c0c], eax
cmp eax, 0xffffffff
jne 0x10007090
push ebx
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call ebx
push esi
call ebx
push edi
call ebx
push str.ERROR______________hFile__INVALID_HANDLE_VALUE___FileName__
lea ecx, [ebp - 0x1c08]
push 0x400
push ecx
call fcn.1000bb31
add esp, 0xc
lea edx, [ebp - 0xc08]
push edx
lea eax, [ebp - 0x1c08]
push 0x400
push eax
call fcn.1000c903
add esp, 0xc
lea edx, [ebp - 0x1c08]
mov esi, 0x1002c2c8
call fcn.10001830
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
call fcn.10001830
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000bb22
mov esp, ebp
pop ebp
ret
lea ecx, [ebp - 0x4c10]
push ecx
push edi
mov dword [ebp - 0x4c10], 0
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
je 0x10007090
mov eax, dword [ebp - 0x4c10]
test eax, eax
je 0x1000715b
push eax
mov dword [ebp - 0x4c14], 0
call fcn.1000ba7a
add esp, 4
mov ebx, eax
mov eax, dword [ebp - 0x4c10]
lea edx, [ebp - 0x4c14]
push edx
push eax
push ebx
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x10007141
mov edx, dword [ebp - 0x4c14]
mov eax, dword [ebp - 0x4c0c]
push 0
lea ecx, [ebp - 0x4c1c]
push ecx
push edx
push ebx
push eax
mov dword [ebp - 0x4c1c], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x10007124
mov edx, str.ERROR____________________WriteFile_failed_for_response_file
mov esi, 0x1002c2c8
call fcn.10001830
mov ecx, dword [ebp - 0x4c14]
cmp ecx, dword [ebp - 0x4c1c]
je 0x10007141
mov edx, str.ERROR_____________________dwBytes_dwBytesWritten__failed_for_response_file
mov esi, 0x1002c2c8
call fcn.10001830
push ebx
call fcn.1000bd44
mov ebx, dword [ebp - 0x4c24]
mov esi, dword [ebp - 0x4c20]
add esp, 4
jmp 0x10007090
mov edx, dword [ebp - 0x4c0c]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call ebx
push esi
call ebx
push edi
call ebx
mov edx, str.Leaving________________________________________________________________________EHCreateFolderOnServerNeo
mov esi, 0x1002c2c8
call fcn.10001830
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
mov al, 1
pop ebx
call fcn.1000bb22
mov esp, ebp
pop ebp
ret