OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
RE: Programmatic access to the showq daemon/data

From: Ward, Martin (Martin.Wardcolt.net)
Date: Tue Oct 02 2007 - 03:40:16 CDT


> > I ask because I have a number of mail servers that regularly have
mail
> > queues 300,000 emails and a lot of these queues are bounces and
> > double-bounces. Right now I have a simple script that someone wrote
> > (possibly it even came with the Postfix installation since I didn't
> > perform the installation) which runs the "postqueue -p" command,
> > grep/awks out the message ID of the unwanted emails and runs
> > "postsuper -d" for each ID.
>
> EEEEKS!
>
> Don't accept mail for bogus senders, so that you don't have
> to send bounces later!
>
> Talk about fixing the wrong problem at the wrong end!
>

Unfortunately I didn't design or implement this system and I have
to work with what I have been given, a complete rewrite of the
System is not going to happen! As for bogus senders, this is
something that will be looked at but how can I verify them?

1. DNS check of the mail domain, but mail domains are easily
   faked.
2. SPF. Not implemented widely enough to be useful, but is
   certianly one thing I will be looking at.
3. Forward/reverse resolution of the name/IP address of the
   sending server is not a good test by any means given the
   number of hosts that will route emails for other domains
   (my company offers such a service).

How else can I use Postfix to verify the sender address?

> The postqueue command takes long because it has to examine
> every queue file. There is no way that you can speed that up
> except by strong the entire mail queue metadata in a database.
>

Yes, I was afraid that was the case. I wanted to see if there
was programmatic access to the postqueue/showq functionality
so that I could at least limit the amount of processing involved
In generating a list of mail senders.

Thanks for your thoughts.

|\/|artin

*************************************************************************************
The message is intended for the named addressee only and may not be disclosed to or used by anyone else, nor may it be copied in any way.

The contents of this message and its attachments are confidential and may also be subject to legal privilege. If you are not the named addressee and/or have received this message in error, please advise us by e-mailing securitycolt.net and delete the message and any attachments without retaining any copies.

Internet communications are not secure and COLT does not accept responsibility for this message, its contents nor responsibility for any viruses.

No contracts can be created or varied on behalf of COLT Telecommunications, its subsidiaries or affiliates ("COLT") and any other party by email Communications unless expressly agreed in writing with such other party.

Please note that incoming emails will be automatically scanned to eliminate potential viruses and unsolicited promotional emails. For more information refer to www.colt.net or contact us on +44(0)20 7390 3900.