Function at 0x403670
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x432cd8
mov eax, dword fs:[0]
push eax
push ecx
mov eax, 0x109c
call fcn.0041e5d0
mov eax, dword [0x448620]
xor eax, ebp
mov dword [ebp - 0x18], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov esi, edx
mov ebx, ecx
cmp byte [ebp + 0x14], 0
mov eax, dword [ebp + 0x18]
mov edi, dword [ebp + 0x1c]
mov dword [ebp - 0x1090], eax
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x1068], edi
mov dword [ebp - 0x108c], eax
mov dword [ebp - 0x1078], 0
jne 0x4036e1
push 0x43eed8
mov ecx, esi
call fcn.00404b30
push 0
push 0
push 0
push 0
push 1
push str.MFC_Sample_App
lea ecx, [ebp - 0x10a4]
mov dword [ebp - 0x107c], 0
call fcn.0040cdb9
mov dword [ebp - method.CInternetSession.virtual_0], 0x43eefc
mov dword [ebp - 4], 0
mov dword [ebp - 0x1060], 0
mov dword [ebp - 0x105c], 0
mov byte [ebp - 4], 1
call fcn.0040ca7a
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x40374a
push 0x80004005
call fcn.00403290
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x106c], eax
mov byte [ebp - 4], 2
call fcn.0040ca7a
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x40377a
push 0x80004005
call fcn.00403290
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x1064], eax
lea eax, [ebp - 0x1080]
mov byte [ebp - 4], 3
push eax
lea eax, [ebp - 0x1064]
push eax
lea eax, [ebp - 0x106c]
push eax
lea eax, [ebp - 0x1074]
push eax
push ebx
call fcn.0040d2a7
test eax, eax
je 0x403cca
mov al, byte [ebp + 0x10]
test al, al
jne 0x4037c8
cmp dword [ebp - 0x1074], 3
jmp 0x4037d6
cmp al, 1
jne 0x4037dc
cmp dword [ebp - 0x1074], 0x100b
jne 0x403cca
cmp dword [0x44d724], 0
je 0x4037f2
push 1
lea ecx, [ebp - 0x10a4]
call fcn.0040d436
push 0
push 0
push dword [ebp - 0x1080]
lea ecx, [ebp - 0x10a4]
push dword [ebp - 0x106c]
call fcn.0040d6ea
cmp byte [ebp + 0x10], 1
mov ebx, eax
mov ecx, 0xa4800000
mov dword [ebp - 0x1060], ebx
mov eax, 0xa0000000
cmove eax, ecx
mov ecx, ebx
push eax
push 0
push 0
push 1
push 0
push dword [ebp - 0x1064]
mov dword [ebp - 0x1084], eax
push edi
call fcn.0040d821
cmp dword [ebp - 0x1068], 0
mov edi, eax
mov dword [ebp - 0x105c], edi
je 0x403867
push 0xffffffffffffffff
push 0x10000000
push str.Content_Type:_text_plain
mov ecx, edi
call fcn.0040d23e
push 0
push 0
push 0
push 0
mov ecx, edi
call fcn.0040dd46
lea eax, [ebp - 0x1070]
mov ecx, edi
push eax
call fcn.0040d940
mov eax, dword [ebp - 0x1070]
cmp eax, 0x191
jne 0x4038ed
push 0
push 6
push 0x2eee
push 0
mov ecx, edi
call fcn.0040d492
cmp eax, 0x2f00
je 0x4038b4
mov ecx, 2
call fcn.00403600
push 0
push 0
push 0
push 0
mov ecx, edi
call fcn.0040dd46
lea eax, [ebp - 0x1070]
mov ecx, edi
push eax
call fcn.0040d940
call fcn.0040ca7a
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x4038fe
push 0x80004005
call fcn.00403290
cmp eax, 0x194
jne 0x4038d1
mov ecx, 3
call fcn.00403600
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x1058], eax
push 0
lea eax, [ebp - 0x1058]
mov byte [ebp - 4], 4
push eax
push 0x16
mov ecx, edi
call fcn.0040d8c9
mov eax, dword [ebp - 0x1070]
cmp eax, 0x12d
je 0x403943
cmp eax, 0x12e
je 0x403943
cmp eax, 0x12f
jne 0x403b37
push 0
lea eax, [ebp - 0x1058]
mov ecx, edi
push eax
push 0x16
call fcn.0040d8c9
mov eax, dword [ebp - 0x1058]
cmp dword [eax - 0xc], 0
jl 0x403cc0
push str.Location:
push eax
call fcn.0041b7f4
add esp, 8
test eax, eax
je 0x403cc0
sub eax, dword [ebp - 0x1058]
sar eax, 1
cmp eax, 0xffffffff
je 0x403cc0
add eax, 0xa
lea ecx, [ebp - 0x1058]
push eax
lea eax, [ebp - 0x1068]
push eax
call fcn.00403e70
push eax
lea ecx, [ebp - 0x1058]
mov byte [ebp - 4], 5
call fcn.00404be0
mov byte [ebp - 4], 4
or ecx, 0xffffffff
mov edx, dword [ebp - 0x1068]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4039d6
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x1058]
cmp dword [eax - 0xc], 0
jle 0x403a2f
push 0xa
push eax
call fcn.0041c089
add esp, 8
test eax, eax
je 0x403a2f
sub eax, dword [ebp - 0x1058]
sar eax, 1
test eax, eax
jle 0x403a2f
push eax
lea eax, [ebp - 0x1068]
push eax
lea ecx, [ebp - 0x1058]
call fcn.00403ea0
push eax
lea ecx, [ebp - 0x1058]
mov byte [ebp - 4], 6
call fcn.00404be0
lea ecx, [ebp - 0x1068]
mov byte [ebp - 4], 4
call fcn.00402e40
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 0x50]
mov eax, dword [edi]
mov ecx, edi
push 1
call dword [eax + 4]
mov eax, dword [ebx]
mov ecx, ebx
mov dword [ebp - 0x105c], 0
call dword [eax + 0xc]
mov eax, dword [ebx]
mov ecx, ebx
push 1
call dword [eax + 4]
lea eax, [ebp - 0x1080]
mov dword [ebp - 0x1060], 0
push eax
lea eax, [ebp - 0x1064]
push eax
lea eax, [ebp - 0x106c]
push eax
lea eax, [ebp - 0x1074]
push eax
push dword [ebp - 0x1058]
call fcn.0040d2a7
test eax, eax
jne 0x403a96
lea ecx, [eax + 5]
call fcn.00403600
cmp dword [ebp - 0x1074], 3
je 0x403aa9
mov ecx, 6
call fcn.00403600
push 0
push 0
push dword [ebp - 0x1080]
lea ecx, [ebp - 0x10a4]
push dword [ebp - 0x106c]
call fcn.0040d6ea
push dword [ebp - 0x1084]
mov ebx, eax
push 0
push 0
push 1
push 0
push dword [ebp - 0x1064]
mov ecx, ebx
mov dword [ebp - 0x1060], ebx
push 1
call fcn.0040d821
push 0xffffffffffffffff
mov edi, eax
push 0x10000000
push str.Content_Type:_text_plain
mov ecx, edi
mov dword [ebp - 0x105c], edi
call fcn.0040d23e
push 0
push 0
push 0
push 0
mov ecx, edi
call fcn.0040dd46
lea eax, [ebp - 0x1070]
mov ecx, edi
push eax
call fcn.0040d940
cmp dword [ebp - 0x1070], 0xc8
je 0x403b37
mov ecx, 7
call fcn.00403600
push 0x1000
mov ecx, edi
call fcn.0040ddb9
cmp byte [ebp + 0x14], 0
jne 0x403b7b
lea esp, [esp]
mov eax, dword [edi]
lea ecx, [ebp - 0x1024]
push 0x1000
push ecx
mov ecx, edi
call dword [eax + 0x60]
test eax, eax
je 0x403c51
lea eax, [ebp - 0x1024]
mov ecx, esi
push eax
call fcn.00403dd0
jmp 0x403b50
mov eax, dword [esi]
mov ecx, 1
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
or eax, ecx
jge 0x403b95
push 0
mov ecx, esi
call fcn.004031e0
push dword [esi]
lea ecx, [ebp - 0x103c]
call fcn.00403f10
mov byte [ebp - 4], 7
lea eax, [ebp - 0x1084]
cmp dword [ebp - 0x1028], 8
lea esi, [ebp - 0x103c]
push eax
cmovae esi, dword [ebp - 0x103c]
lea ecx, [ebp - 0x103c]
call fcn.00403fa0
lea ecx, [ebp - 0x1054]
push dword [eax]
push esi
call fcn.004046f0
mov byte [ebp - 4], 8
lea ecx, [ebp - 0x1054]
cmp dword [ebp - 0x1040], 0x10
mov edx, 0x43eeac
mov eax, 0x43eea8
cmovae ecx, dword [ebp - 0x1054]
cmp byte [ebp - 0x1090], 0
cmovne eax, edx
push eax
push ecx
lea eax, [ebp - 0x1078]
push eax
call fcn.0041bb96
add esp, 0xc
test eax, eax
jne 0x403cb0
nop
mov eax, dword [edi]
lea ecx, [ebp - 0x1024]
push 0x1000
push ecx
mov ecx, edi
call dword [eax + 0x38]
test eax, eax
jne 0x403c85
lea ecx, [ebp - 0x1054]
call fcn.00404b00
lea ecx, [ebp - 0x103c]
mov byte [ebp - 4], 4
call fcn.00403f70
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 0x50]
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 0xc]
lea ecx, [ebp - 0x1058]
call fcn.00402e40
lea ecx, [ebp - 0x1064]
call fcn.00402e40
lea ecx, [ebp - 0x106c]
call fcn.00402e40
jmp 0x403d16
push dword [ebp - 0x1078]
push 1
push eax
lea eax, [ebp - 0x1024]
push eax
call fcn.0041bd34
add esp, 0x10
cmp eax, 1
jae 0x403c20
mov ecx, 8
call fcn.00403600
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 9
call fcn.00403600
mov ecx, 4
call fcn.00403600
mov ecx, 1
call fcn.00403600
mov ecx, dword [ebp - 0x108c]
mov esi, dword [ebp - 0x1088]
test ecx, ecx
je 0x403cf3
mov eax, dword [esi]
push 0
push 0x400
push ecx
mov ecx, esi
call dword [eax + 0x10]
mov ecx, esi
mov dword [ebp - 0x107c], 0xb
call fcn.0040c642
mov eax, 0x403d0a
ret
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x1078]
test eax, eax
je 0x403d3b
push eax
call fcn.0041be69
push dword [ebp - 0x1078]
call fcn.0041c012
add esp, 8
test edi, edi
je 0x403d48
mov eax, dword [edi]
mov ecx, edi
push 1
call dword [eax + 4]
test ebx, ebx
je 0x403d55
mov eax, dword [ebx]
mov ecx, ebx
push 1
call dword [eax + 4]
lea ecx, [ebp - 0x10a4]
call fcn.0040d3ff
lea ecx, [ebp - 0x10a4]
mov dword [ebp - 4], 0xffffffff
call fcn.0040d0c5
mov eax, dword [ebp - 0x107c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x18]
xor ecx, ebp
call fcn.0041b38f
mov esp, ebp
pop ebp
ret