MS/perl segfaults

shuttlebox shuttlebox at gmail.com
Sat Jan 17 15:14:23 GMT 2009


On Sat, Jan 17, 2009 at 3:03 PM, Julian Field
<MailScanner at ecs.soton.ac.uk> wrote:
> Re-visiting this issue.
> Is it still a problem?
> Is it worth attempting to solve?
>
> In the following descriptions, all timings would be configurable. It's just
> easier to think about the problem with real numbers in there.
>
> When we scan the queue to build a batch, we look for unlocked messages as
> normal. When we find an unlocked message, we look to see if it is in the
> database table and was first scanned less than 20 minutes ago.
> If it was first scanned 20 minutes ago, we ignore it in case it was a
> one-off failure, or a failure caused by other messages in the same batch.
> If it was first scanned 20-40 minutes ago, we scan it in a batch of 1
> message, on its own.
> If it was first scanned more than 40 minutes ago, we ignore it completely
> and log the event as a scanner failure. Or we could mark it as infected
> instead? What are your thoughts here? A DoS attack attempt would be a
> reasonable conclusion.
>
> I need to catch every time a message leaves the batch and remove it from the
> database table, that's my problem.
> Also, I need to find all the race conditions when checking the database
> about the message, but that's also my problem.
>
> What do you think of the approach above?

Do we need a database? Couldn't you just stat the queue files to see
how old they are and get the same result?

To me, the queue dir is like a database, and the queue files are like
records in the database. You have to put timestamps into the database
but the files already have that. There's no records to remove when the
message has been delivered because the files will be gone.

If I'm not missing something it seems unnecessarily complex with a database..?

-- 
/peter


More information about the MailScanner mailing list