[Mimedefang] running out of disk space?

Kees Cook kees at osdl.org
Wed Aug 27 16:38:00 EDT 2003


Say, I was looking at the Anomy::HTMLCleaner code, and noticed that it 
doesn't handle running out of disk space at all.  It actually doesn't look 
like "print" statements are tested anywhere in mimedefang.

I figure it's pretty rare that the situation would come up where you
couldn't write to disk (since sendmail would have stopped accepting
connections, etc), but it is _possible_.  Even though action_tempfail
exists, it seems like there should be a more generalized "I failed bad
enough that sendmail should temp fail" that is perhaps logged differently, 
that the serverloop will check for after each of the filter* calls.

Anyway, what concerns me most is MIME::Entity->print_body's lack of error
checking (it even returns a static "1"!) and mimedefang.pl's serverloop
snip:

            $rebuilt_flat->print_body(\*OUT);
            $rebuilt = $rebuilt_flat;
        } else {
            $rebuilt->print_body(\*OUT);
        }
        close(OUT);

I am totally crazy, or shouldn't there be more check of successful "print" 
and "close" statements?

-- 
Kees Cook
Open Souce Development Lab
kees at osdl.org



More information about the MIMEDefang mailing list