Function at 0x100393a0
Capabilities:
Initialize winhttp library
Make an http request with a cookie
Prepare http request
Read http header
Receive http response
Send data
Send http request
Set http header
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100af008
mov eax, dword fs:[0]
push eax
mov eax, 0x11a4
call fcn.10080720
mov eax, dword [0x100d65e8]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x1140], esi
cmp dword [esi + 0x18], 0
mov eax, dword [ebp + 8]
ja 0x100393f4
mov dword [esi + 0xf8], 3
xor al, al
jmp 0x1003a3dc
xor ecx, ecx
push 0xffffffffffffffff
push ecx
mov word [ebp - 0x1068], cx
mov dword [ebp - 0x1058], 0
mov dword [ebp - 0x1054], 0
push eax
lea ecx, [ebp - 0x1068]
mov dword [ebp - 0x1054], 7
mov dword [ebp - 0x1058], 0
call fcn.1000f660
mov dword [ebp - 4], 0
cmp dword [ebp - 0x1054], 8
lea eax, [ebp - 0x1068]
cmovae eax, dword [ebp - 0x1068]
push 0x100bdcac
push eax
call fcn.10081e9e
add esp, 8
test eax, eax
jne 0x1003946a
push 3
push 0x100bdcac
jmp 0x1003949b
cmp dword [ebp - 0x1054], 8
lea eax, [ebp - 0x1068]
cmovae eax, dword [ebp - 0x1068]
push str.POST
push eax
call fcn.10081e9e
add esp, 8
test eax, eax
jne 0x1003a393
push 4
push str.POST
lea ecx, [ebp - 0x1068]
call fcn.1000f9f0
cmp dword [esi], 0
mov ebx, 1
mov dword [ebp - 0x10fc], ebx
jne 0x100394ed
cmp dword [esi + 0x128], 8
lea eax, [esi + 0x114]
jb 0x100394c7
mov eax, dword [eax]
push 0
push 0
push 0
push 0
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov dword [esi], eax
test eax, eax
jne 0x100394ed
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esi + 0xf8], eax
jmp 0x1003a39d
push dword [esi + 0x184]
push dword [esi + 0x180]
push dword [esi + 0x17c]
push dword [esi + 0x178]
push dword [esi]
call dword [sym.imp.WINHTTP.dll_WinHttpSetTimeouts]
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x420], ax
lea eax, [ebp - 0x41e]
push eax
call fcn.1007f340
add esp, 0xc
xor eax, eax
push 0xa26
push eax
mov word [ebp - 0x1050], ax
lea eax, [ebp - 0x104e]
push eax
call fcn.1007f340
add esp, 0xc
lea eax, [ebp - 0x11b0]
push 0x3c
push 0
push eax
call fcn.1007f340
lea eax, [ebp - 0x420]
mov dword [ebp - 0x11a0], eax
lea eax, [ebp - 0x1050]
mov dword [ebp - 0x1184], eax
lea eax, [esi + 8]
add esp, 0xc
cmp dword [eax + 0x14], 8
mov dword [ebp - 0x11b0], 0x3c
mov dword [ebp - 0x119c], 0x104
mov dword [ebp - 0x1180], 0x514
mov dword [ebp - 0x11a8], ebx
jb 0x100395a3
mov eax, dword [eax]
lea ecx, [ebp - 0x11b0]
push ecx
push 0
push dword [esi + 0x18]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpCrackUrl]
test eax, eax
je 0x1003a39f
cmp word [ebp - 0x420], 0
jne 0x100395cc
xor ecx, ecx
jmp 0x100395e4
lea ecx, [ebp - 0x420]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x100395d5
sub ecx, edx
sar ecx, 1
push ecx
lea eax, [ebp - 0x420]
push eax
lea ecx, [esi + 0x20]
call fcn.1000f9f0
push 0
push dword [ebp - 0x1198]
lea eax, [ebp - 0x420]
push eax
push dword [esi]
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov dword [ebp - 0x114c], eax
test eax, eax
je 0x1003a39f
xor ecx, ecx
cmp dword [ebp - 0x11a4], 2
mov edx, 0x800000
cmove ecx, edx
cmp dword [ebp - 0x1054], 8
push ecx
push 0
push 0
push 0
push dword [ebp - 0x1184]
lea edx, [ebp - 0x1068]
cmovae edx, dword [ebp - 0x1068]
push edx
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov edi, eax
mov dword [ebp - 0x10ec], edi
test edi, edi
je 0x1003a385
cmp byte [esi + 4], 0
jne 0x1003968e
cmp dword [ebp - 0x11a4], 2
jne 0x1003968e
push 4
lea eax, [ebp - 0x10f0]
push eax
push 0x1f
push edi
mov dword [ebp - 0x10f0], 0x3100
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [ebp - 0x10e1], 0
xor ecx, ecx
lea ecx, [ecx]
mov eax, ecx
inc ecx
mov dword [ebp - 0x1150], ecx
cmp eax, 3
jae 0x1003a35d
mov ecx, dword [esi + 0xd8]
test ecx, ecx
je 0x100396e7
cmp dword [esi + 0xdc], 8
lea eax, [esi + 0xc8]
jb 0x100396cd
mov eax, dword [eax]
push 0x1000000
push ecx
push eax
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpAddRequestHeaders]
test eax, eax
jne 0x100396e7
call ebx
mov dword [esi + 0xf8], eax
cmp dword [esi + 0xb8], 0
jbe 0x1003975c
push str.Cookie:
lea ecx, [ebp - 0x1098]
call fcn.1000fb40
mov byte [ebp - 4], 1
push 0xffffffffffffffff
push 0
lea eax, [esi + 0xa8]
push eax
lea ecx, [ebp - 0x1098]
call fcn.100067b0
cmp dword [ebp - 0x1084], 8
push 0x1000000
push dword [ebp - 0x1088]
lea eax, [ebp - 0x1098]
cmovae eax, dword [ebp - 0x1098]
push eax
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpAddRequestHeaders]
test eax, eax
jne 0x1003974d
call ebx
mov dword [esi + 0xf8], eax
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x1098]
call fcn.100103e0
cmp dword [esi + 0xf0], 0
jbe 0x10039861
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x218], ax
xorps xmm0, xmm0
lea eax, [ebp - 0x216]
movq qword [ebp - 0x115c], xmm0
push eax
mov dword [ebp - 0x1154], 0
mov dword [ebp - 0x115c], 3
call fcn.1007f340
lea eax, [esi + 0xe0]
add esp, 0xc
cmp dword [eax + 0x14], 8
jb 0x100397b4
mov eax, dword [eax]
push eax
lea eax, [ebp - 0x218]
push 0x104
push eax
call fcn.10081006
add esp, 0xc
lea eax, [ebp - 0x218]
push 0xc
mov dword [ebp - 0x1158], eax
lea eax, [ebp - 0x115c]
push eax
push 0x26
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
test eax, eax
jne 0x100397f3
call ebx
mov dword [esi + 0xf8], eax
mov eax, dword [esi + 0x140]
test eax, eax
je 0x10039861
cmp dword [esi + 0x144], 8
lea ecx, [esi + 0x130]
jb 0x1003980e
mov ecx, dword [ecx]
add eax, eax
push eax
push ecx
push 0x1002
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
test eax, eax
jne 0x1003982a
call ebx
mov dword [esi + 0xf8], eax
mov eax, dword [esi + 0x158]
test eax, eax
je 0x10039861
cmp dword [esi + 0x15c], 8
lea ecx, [esi + 0x148]
jb 0x10039845
mov ecx, dword [ecx]
add eax, eax
push eax
push ecx
push 0x1003
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
test eax, eax
jne 0x10039861
call ebx
mov dword [esi + 0xf8], eax
push 0
push 0
push 0
push 0
push 0
push 0
push edi
xor bl, bl
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
jne 0x10039abe
xorps xmm0, xmm0
lea eax, [ebp - 0x1124]
push eax
movq qword [ebp - 0x1124], xmm0
movq qword [ebp - 0x111c], xmm0
call dword [sym.imp.WINHTTP.dll_WinHttpGetIEProxyConfigForCurrentUser]
test eax, eax
je 0x10039afb
mov eax, dword [ebp - 0x1120]
test eax, eax
je 0x100399a2
cmp dword [esi + 0x1c], 8
xorps xmm0, xmm0
movq qword [ebp - 0x116c], xmm0
mov dword [ebp - 0x116c], eax
lea eax, [esi + 8]
movq qword [ebp - 0x1174], xmm0
movq qword [ebp - 0x1164], xmm0
mov dword [ebp - 0x1174], 3
mov dword [ebp - 0x1170], 1
mov dword [ebp - 0x1160], 1
mov dword [ebp - 0x1164], 0
mov dword [ebp - 0x1168], 0
movq qword [ebp - 0x1130], xmm0
mov dword [ebp - 0x1128], 0
jb 0x10039924
mov eax, dword [eax]
lea ecx, [ebp - 0x1130]
push ecx
lea ecx, [ebp - 0x1174]
push ecx
push eax
push dword [esi]
call dword [sym.imp.WINHTTP.dll_WinHttpGetProxyForUrl]
test eax, eax
je 0x10039a72
push 0xc
lea eax, [ebp - 0x1130]
push eax
push 0x26
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
test eax, eax
je 0x10039979
push 0
push 0
push 0
push 0
push 0
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
movzx ebx, bl
test eax, eax
mov eax, 1
cmovne ebx, eax
mov eax, dword [ebp - 0x112c]
mov edi, dword [sym.imp.KERNEL32.dll_GlobalFree]
test eax, eax
je 0x1003998c
push eax
call edi
mov eax, dword [ebp - 0x1128]
test eax, eax
je 0x10039a7f
push eax
call edi
jmp 0x10039a7f
mov edi, dword [ebp - 0x111c]
test edi, edi
je 0x10039a9f
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x218], ax
xorps xmm0, xmm0
lea eax, [ebp - 0x216]
movq qword [ebp - 0x113c], xmm0
push eax
mov dword [ebp - 0x1134], 0
mov dword [ebp - 0x113c], 3
call fcn.1007f340
add esp, 0xc
lea eax, [ebp - 0x218]
push edi
push 0x104
push eax
call fcn.10081006
mov edi, dword [ebp - 0x1118]
add esp, 0xc
lea eax, [ebp - 0x218]
mov dword [ebp - 0x1138], eax
test edi, edi
je 0x10039a57
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x628], ax
lea eax, [ebp - 0x626]
push eax
call fcn.1007f340
add esp, 0xc
lea eax, [ebp - 0x628]
push edi
push 0x104
push eax
call fcn.10081006
lea eax, [ebp - 0x628]
add esp, 0xc
mov dword [ebp - 0x1134], eax
push 0xc
lea eax, [ebp - 0x113c]
push eax
push 0x26
push dword [ebp - 0x10ec]
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
test eax, eax
jne 0x10039a7f
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esi + 0xf8], eax
mov eax, dword [ebp - 0x1120]
mov edi, dword [sym.imp.KERNEL32.dll_GlobalFree]
test eax, eax
je 0x10039a92
push eax
call edi
mov eax, dword [ebp - 0x111c]
test eax, eax
je 0x10039a9f
push eax
call edi
mov eax, dword [ebp - 0x1118]
test eax, eax
je 0x10039ab0
push eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov edi, dword [ebp - 0x10ec]
test bl, bl
je 0x1003a331
mov eax, dword [esi + 0xc0]
test eax, eax
je 0x10039b0e
lea ecx, [ebp - 0x10f0]
push ecx
push dword [esi + 0xc4]
mov dword [ebp - 0x10f0], 0
push eax
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpWriteData]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x10039b14
call ebx
mov dword [esi + 0xf8], eax
jmp 0x10039b14
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
mov dword [esi + 0xf8], eax
jmp 0x1003a337
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x10039b01
push 0
lea eax, [ebp - 0x10e8]
push eax
push 0
push 0
push 0x16
push edi
mov dword [ebp - 0x10e8], 0
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
jne 0x10039b50
call ebx
cmp eax, 0x7a
jne 0x10039e82
mov eax, dword [ebp - 0x10e8]
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.1007d096
mov edi, eax
add esp, 4
mov dword [ebp - 0x1148], edi
test edi, edi
je 0x10039e7c
mov ecx, dword [ebp - 0x10e8]
add ecx, ecx
push ecx
push 0
push edi
call fcn.1007f340
add esp, 0xc
lea eax, [ebp - 0x10e8]
push 0
push eax
push edi
push 0
push 0x16
push dword [ebp - 0x10ec]
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
je 0x10039e73
lea ebx, [esi + 0x38]
push edi
mov ecx, ebx
call fcn.1000faf0
mov dword [ebp - 0x1108], 0
mov dword [ebp - 0x1104], 0
mov dword [ebp - 0x1100], 0
mov byte [ebp - 4], 2
push 0x100bd6c4
lea ecx, [ebp - 0x1080]
call fcn.1000fb40
mov byte [ebp - 4], 3
cmp byte [esi + 0x12c], 0
jne 0x10039c5d
push str.charset_A_Za_z0_9___
lea ecx, [ebp - 0x1080]
call fcn.1000faf0
push ecx
lea eax, [ebp - 0x1108]
push eax
push ebx
push ecx
lea ecx, [ebp - 0x1080]
call fcn.100386e0
add esp, 0x10
test al, al
je 0x10039c5d
mov ecx, dword [ebp - 0x1104]
mov edi, dword [ebp - 0x1108]
sub ecx, edi
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x10039c5d
lea ecx, [esi + 0x68]
cmp ecx, edi
je 0x10039c5d
push 0xffffffffffffffff
push 0
push edi
call fcn.1000f660
push str.Content_Length:__0_9_
lea ecx, [ebp - 0x1080]
call fcn.1000faf0
push ecx
lea eax, [ebp - 0x1108]
push eax
push ebx
push ecx
lea ecx, [ebp - 0x1080]
call fcn.100386e0
add esp, 0x10
test al, al
je 0x10039cc1
mov ecx, dword [ebp - 0x1104]
mov edi, dword [ebp - 0x1108]
sub ecx, edi
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x10039cc1
cmp dword [edi + 0x14], 8
jb 0x10039cb2
mov edi, dword [edi]
push edi
call fcn.1007f3d0
add esp, 4
mov dword [esi + 0x8c], eax
push str.Location:__0_9_
lea ecx, [ebp - 0x1080]
call fcn.1000faf0
push ecx
lea eax, [ebp - 0x1108]
push eax
push ebx
push ecx
lea ecx, [ebp - 0x1080]
call fcn.100386e0
add esp, 0x10
test al, al
je 0x10039d22
mov ecx, dword [ebp - 0x1104]
mov edi, dword [ebp - 0x1108]
sub ecx, edi
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x10039d22
lea ecx, [esi + 0x160]
cmp ecx, edi
je 0x10039d22
push 0xffffffffffffffff
push 0
push edi
call fcn.1000f660
push str.Set_Cookie:_b.__n
lea ecx, [ebp - 0x1080]
call fcn.1000faf0
push ecx
lea eax, [ebp - 0x1108]
push eax
push ebx
push ecx
lea ecx, [ebp - 0x1080]
call fcn.100386e0
add esp, 0x10
test al, al
je 0x10039e4f
mov ecx, dword [ebp - 0x1104]
mov ebx, dword [ebp - 0x1108]
sub ecx, ebx
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [ebp - 0x10f8], eax
je 0x10039e4f
xor edi, edi
test eax, eax
je 0x10039dca
dec eax
mov dword [ebp - 0x10f4], eax
lea eax, [esi + 0x90]
mov dword [ebp - 0x10f0], eax
mov esi, eax
push 0xffffffffffffffff
push 0
push ebx
mov ecx, esi
call fcn.100067b0
cmp edi, dword [ebp - 0x10f4]
je 0x10039db8
push 0x100be84c
mov ecx, esi
call fcn.10004bf0
inc edi
add ebx, 0x18
cmp edi, dword [ebp - 0x10f8]
jb 0x10039d98
mov esi, dword [ebp - 0x1140]
push 0x100bdce8
lea ecx, [ebp - 0x10c8]
call fcn.1000fb40
mov byte [ebp - 4], 4
lea eax, [ebp - 0x10c8]
lea edi, [esi + 0x90]
push eax
mov edx, edi
lea ecx, [ebp - 0x10e0]
call fcn.10038b40
add esp, 4
mov byte [ebp - 4], 5
push eax
mov ecx, edi
call fcn.10004bb0
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x10e0]
call fcn.100103e0
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x10c8]
call fcn.100103e0
mov ecx, dword [esi + 0xa0]
test ecx, ecx
je 0x10039e4f
cmp dword [edi + 0x14], 8
jb 0x10039e39
mov eax, dword [edi]
jmp 0x10039e3b
mov eax, edi
cmp word [eax + ecx*2 - 2], 0x3b
je 0x10039e4f
push 0x100be854
mov ecx, edi
call fcn.10004bf0
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x1080]
call fcn.100103e0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x1108]
call fcn.10025f30
mov edi, dword [ebp - 0x1148]
push edi
call fcn.1007f59b
add esp, 4
mov edi, dword [ebp - 0x10ec]
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
push 0
lea eax, [ebp - 0x10e8]
push eax
push 0
push 0
push 0x13
push edi
mov dword [ebp - 0x10e8], 0
call ebx
test eax, eax
jne 0x10039eb4
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
cmp eax, 0x7a
jne 0x10039f22
mov eax, dword [ebp - 0x10e8]
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.1007d096
mov edi, eax
add esp, 4
test edi, edi
je 0x10039f1c
mov ecx, dword [ebp - 0x10e8]
add ecx, ecx
push ecx
push 0
push edi
call fcn.1007f340
add esp, 0xc
lea eax, [ebp - 0x10e8]
push 0
push eax
push edi
push 0
push 0x13
push dword [ebp - 0x10ec]
call ebx
test eax, eax
je 0x10039f13
push edi
lea ecx, [esi + 0xfc]
call fcn.1000faf0
push edi
call fcn.1007f59b
add esp, 4
mov edi, dword [ebp - 0x10ec]
mov eax, dword [esi + 0x80]
mov ecx, 0x2800
xor ebx, ebx
mov dword [ebp - 0x10f4], ecx
test eax, eax
je 0x10039f48
push eax
call fcn.1007f59b
add esp, 4
mov dword [esi + 0x80], ebx
push 0x2800
call fcn.1007d096
add esp, 4
mov dword [esi + 0x80], eax
test eax, eax
je 0x1003a34b
push 0x2800
push 0
push eax
call fcn.1007f340
add esp, 0xc
lea eax, [ebp - 0x10e8]
push eax
push edi
mov dword [ebp - 0x10e8], 0
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
je 0x1003a0e9
push ebx
mov ecx, esi
call fcn.1003a480
mov eax, dword [ebp - 0x10e8]
inc eax
push eax
call fcn.1007d096
mov edi, eax
add esp, 4
test edi, edi
je 0x1003a0d4
mov ecx, dword [ebp - 0x10e8]
inc ecx
push ecx
push 0
push edi
call fcn.1007f340
add esp, 0xc
lea eax, [ebp - 0x10f8]
push eax
push dword [ebp - 0x10e8]
mov dword [ebp - 0x10f8], 0
push edi
push dword [ebp - 0x10ec]
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x1003a0cb
mov ecx, dword [ebp - 0x10f8]
mov edx, dword [ebp - 0x10f4]
lea eax, [ecx + ebx]
cmp eax, edx
jbe 0x1003a06d
mov eax, dword [esi + 0x80]
add edx, edx
push edx
mov dword [ebp - 0x10f0], eax
mov dword [ebp - 0x10f4], edx
call fcn.1007d096
add esp, 4
mov dword [esi + 0x80], eax
test eax, eax
je 0x1003a0f7
mov ecx, dword [ebp - 0x10f4]
push ecx
push 0
push eax
call fcn.1007f340
add esp, 0xc
push ebx
push dword [ebp - 0x10f0]
push dword [esi + 0x80]
call fcn.1007eab0
add esp, 0xc
push dword [ebp - 0x10f0]
call fcn.1007f59b
mov ecx, dword [ebp - 0x10f8]
add esp, 4
mov eax, dword [esi + 0x80]
push ecx
add eax, ebx
push edi
push eax
call fcn.1007eab0
add ebx, dword [ebp - 0x10f8]
add esp, 0xc
cmp byte [esi + 0x188], 0
je 0x1003a0cb
push 2
push 0
push 0
push dword [esi + 0x18c]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea eax, [ebp - 0x1144]
push eax
push dword [ebp - 0x10f8]
mov dword [ebp - 0x1144], 0
push edi
push dword [esi + 0x18c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1003a103
push edi
call fcn.1007f59b
add esp, 4
mov edi, dword [ebp - 0x10ec]
cmp dword [ebp - 0x10e8], 0
ja 0x10039f73
jmp 0x1003a10b
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esi + 0xf8], eax
jmp 0x1003a0da
mov eax, dword [ebp - 0x10f0]
mov dword [esi + 0x80], eax
xor al, al
mov dword [ebp - 0x10fc], eax
push ebx
mov ecx, esi
call fcn.1003a480
mov dword [esi + 0x84], ebx
lea eax, [esi + 0x68]
xor ebx, ebx
cmp dword [eax + 0x14], 8
mov edi, 1
mov dword [ebp - 0x10f4], ebx
mov dword [ebp - 0x10f0], edi
jb 0x1003a137
mov eax, dword [eax]
push 5
push 0x100be858
push eax
call fcn.100813b7
add esp, 0xc
test eax, eax
jne 0x1003a15e
mov ebx, 0xfde9
xor edi, edi
mov dword [ebp - 0x10f4], ebx
mov dword [ebp - 0x10f0], edi
mov eax, dword [esi + 0x84]
push 0
push 0
inc eax
push eax
push dword [esi + 0x80]
push edi
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
call ebx
mov edi, eax
test edi, edi
jg 0x1003a1b2
mov eax, dword [esi + 0x84]
push 0
push 0
inc eax
push eax
push dword [esi + 0x80]
mov dword [ebp - 0x10f4], 0
push 1
push 0
mov dword [ebp - 0x10f0], 1
call ebx
mov edi, eax
test edi, edi
jle 0x1003a21a
xor ecx, ecx
mov eax, edi
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.1007d096
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x1003a21a
lea ecx, [edi + edi]
push ecx
push 0
push ebx
call fcn.1007f340
mov eax, dword [esi + 0x84]
add esp, 0xc
inc eax
push edi
push ebx
push eax
push dword [esi + 0x80]
push dword [ebp - 0x10f0]
push dword [ebp - 0x10f4]
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jle 0x1003a211
push ebx
lea ecx, [esi + 0x50]
call fcn.1000faf0
push ebx
call fcn.1007f59b
add esp, 4
lea eax, [ebp - 0x1068]
push 0x100bdcac
push eax
mov byte [ebp - 0x10e1], 1
call fcn.1003c420
add esp, 8
test al, al
je 0x1003a373
push str._html_
lea ecx, [ebp - 0x10b0]
call fcn.1000fb40
mov byte [ebp - 4], 6
mov dword [ebp - 0x1114], 0
mov dword [ebp - 0x1110], 0
mov dword [ebp - 0x110c], 0
mov byte [ebp - 4], 7
push ecx
lea eax, [ebp - 0x1114]
push eax
lea edi, [esi + 0x50]
push edi
push ecx
lea ecx, [ebp - 0x10b0]
call fcn.100386e0
add esp, 0x10
test al, al
je 0x1003a30d
mov ecx, dword [ebp - 0x1110]
sub ecx, dword [ebp - 0x1114]
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x1003a30d
push str.__html_
lea ecx, [ebp - 0x10b0]
call fcn.1000faf0
push ecx
lea eax, [ebp - 0x1114]
push eax
push edi
push ecx
lea ecx, [ebp - 0x10b0]
call fcn.100386e0
add esp, 0x10
test al, al
je 0x1003a2fc
mov ecx, dword [ebp - 0x1110]
sub ecx, dword [ebp - 0x1114]
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
jne 0x1003a30d
mov dword [esi + 0xf8], 0xd
mov byte [ebp - 0x10e1], 0
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x1114]
call fcn.10025f30
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x10b0]
call fcn.100103e0
mov edi, dword [ebp - 0x10ec]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
cmp byte [ebp - 0x10e1], 0
jne 0x1003a373
mov ecx, dword [ebp - 0x1150]
jmp 0x100396a0
xor bl, bl
xor eax, eax
cmp byte [ebp - 0x10e1], al
movzx ebx, bl
cmove ebx, eax
jmp 0x1003a379
mov ebx, dword [ebp - 0x10fc]
xor eax, eax
cmp byte [ebp - 0x10e1], al
movzx ebx, bl
cmove ebx, eax
jmp 0x1003a379
mov ebx, dword [ebp - 0x10fc]
push dword [ebp - 0x10ec]
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
push dword [ebp - 0x114c]
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
jmp 0x1003a39f
mov dword [esi + 0xf8], 0x57
xor bl, bl
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x1054], 8
jb 0x1003a3bd
push dword [ebp - 0x1068]
call fcn.1007d9ed
add esp, 4
xor eax, eax
mov word [ebp - 0x1068], ax
mov dword [ebp - 0x1054], 7
mov dword [ebp - 0x1058], 0
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.1007e654
mov esp, ebp
pop ebp
ret 8