Function at 0x40baf8
Capabilities:
Write file on windows

Disassembly:
push 0x34
mov eax, 0x46eebc
call fcn.0045c39c
mov edi, ecx
mov esi, edx
mov eax, esi
call fcn.0040b995
test al, al
jne 0x40bb20
mov eax, 0x80040007
call fcn.0045c474
ret 0xc
mov bl, byte [esi + 0x50]
and bl, 1
mov byte [ebp - 0xd], bl
call fcn.0040a7a8
cmp dword [ebp + 8], 0xffffffff
jne 0x40bb38
push 6
jmp 0x40bb47
cmp dword [ebp + 0xc], 0
jne 0x40bb4e
test bl, bl
jne 0x40bb4e
push 0x80070057
mov eax, esi
call fcn.0040b322
mov eax, esi
call fcn.0040aac7
test al, al
je 0x40bb5e
mov eax, dword [esi + 0x10]
jmp 0x40bb18
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x40bb6d
mov eax, dword [ecx]
call dword [eax]
test al, al
je 0x40bb59
mov ebx, 0x49ed00
push ebx
lea ecx, [ebp - 0x14]
call fcn.00401e4f
and dword [ebp - 4], 0
cmp byte [ebp - 0xd], 0
jne 0x40bc4f
mov eax, dword [ebp + 0xc]
lea eax, [edi + eax - 1]
push eax
push edi
lea eax, [ebp - 0x14]
push str.Range:bytes_d__d
push eax
call fcn.004047a5
mov edi, dword [ebp - 0x14]
mov eax, dword [edi - 0xc]
mov ecx, dword [esi + 0x28]
mov edx, dword [esi + 0x1c]
mov edx, dword [edx + 0x20]
push 0
push 0x4000000
push eax
push edi
push ecx
push edx
call fcn.0044ef50
mov edi, eax
add esp, 0x28
test edi, edi
jne 0x40bc52
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov ecx, eax
call fcn.0040b235
push dword [esi + 0xc]
lea edi, [ebp + 0xc]
call fcn.0040aee4
pop ecx
push ebx
lea ecx, [ebp + 0x10]
mov byte [ebp - 4], 1
call fcn.00401e4f
mov byte [ebp - 4], 2
push dword [ebp - 0x14]
lea eax, [ebp + 0x10]
push dword [ebp + 0xc]
push str.desc_s___s_
push eax
call fcn.004047a5
mov eax, dword [esi + 0x10]
mov edi, dword [ebp + 0x10]
add esp, 0x10
push str.shared::lite::data::CInternetResource::Save
push eax
push edi
call fcn.004348d0
mov ecx, eax
call fcn.00434b80
mov esi, dword [esi + 0x10]
lea ecx, [edi - 0x10]
call fcn.00402595
mov ecx, dword [ebp + 0xc]
add ecx, 0xfffffff0
call fcn.00402595
mov ecx, dword [ebp - 0x14]
add ecx, 0xfffffff0
call fcn.00402595
mov eax, esi
jmp 0x40bb18
mov edi, dword [esi + 0x24]
push 0x400
lea ecx, [ebp - 0x40]
call fcn.0040a28c
xor eax, eax
mov byte [ebp - 4], 3
cmp dword [ebp - 0x24], eax
je 0x40bc6f
cmp dword [ebp - 0x20], eax
jne 0x40bc88
lea edi, [ebp - 0x40]
call fcn.00401920
mov esi, dword [esi + 0x10]
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 0
call fcn.0040a2c1
jmp 0x40bc3d
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x1c], eax
mov ebx, dword [ebp + 0x10]
test ebx, ebx
je 0x40bc9f
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax]
test al, al
je 0x40bd0b
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0x20]
push dword [ebp - 0x24]
push edi
call fcn.0044f0e0
add esp, 0x10
test eax, eax
je 0x40bcfd
cmp dword [ebp - 0x18], 0
je 0x40bd0b
test ebx, ebx
je 0x40bcca
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax]
test al, al
je 0x40bd0b
push 0
lea eax, [ebp - 0x1c]
push eax
push dword [ebp - 0x18]
push dword [ebp - 0x24]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40bcfd
test ebx, ebx
je 0x40bc8e
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax]
test al, al
je 0x40bd0b
push dword [ebp - 0x18]
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 4]
jmp 0x40bc8e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov ecx, eax
call fcn.0040b235
cmp byte [ebp - 0xd], 0
jne 0x40bc77
push edi
call fcn.0044ece0
pop ecx
jmp 0x40bc77