Re: [Exim] Lots of Frozen mails on my server

Page principale
Supprimer ce message
Répondre à ce message
Auteur: sanjay singh
Date:  
À: exim-users
CC: Sanvir Singh Jham
Sujet: Re: [Exim] Lots of Frozen mails on my server
hi

you can also test this setting:

put the following line in exim configure file:

message_filter = /usr/exim/msgfilter


and then create a file called /usr/exim/msgfilter

if $header_from: contains "virus@???"
then
  fail text "This message has been rejected because your email has been blocked by the administrator\n\
                \tof yourcompany.com. For details contact postmaster@???"
noerror deliver virus@???
  seen finish
endif





regards
sanjay

--
Sanjay Kr. Singh
Head - Systems
Net4India Ltd.
B-4/47, Safdarjung Enclave
New Delhi - 110029
Phone +91 11 6104192/93
Fax +91 11 6102781
<sanjay.s@???>
www.net4india.com



exim-users-request@??? wrote:

> Send Exim-users mailing list submissions to
>         exim-users@???

>
> To subscribe or unsubscribe via the World Wide Web, visit
>         http://www.exim.org/mailman/listinfo/exim-users
> or, via email, send a message with subject or body 'help' to
>         exim-users-request@???

>
> You can reach the person managing the list at
>         exim-users-admin@???

>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Exim-users digest..."
>
> ------------------------------------------------------------------------
> Today's Topics:
>
>    1. Re: Lots of Frozen mails on my server (Sanvir Singh Jham)
>    2. Re: LDAP woes (Philip Hazel)
>    3. Re: uid/gid (Philip Hazel)
>    4. Re: 2 patches for exim 3.30 (Philip Hazel)
>    5. Re: Lots of Frozen mails on my server (Suresh Ramasubramanian)
>    6. Re: FreeBSD 4.3 - Exim and mailer.conf (Philip Hazel)
>    7. Re: uid/gid (Tim Waugh)
>    8. Re: uid/gid (Midwest Mold)
>    9. Re: FreeBSD 4.3 - Exim and mailer.conf (Sheldon Hearn)
>   10. Re: uid/gid (Patrick Boutilier)
>   11. Re: delivery for frozen mails (Sheldon Hearn)
>   12. Re: uid/gid (Philip Hazel)
>   13. Re: uid/gid (Sheldon Hearn)
>   14. Re: uid/gid (Sheldon Hearn)
>   15. Re: uid/gid (Sheldon Hearn)
>   16. Maximun numbers of supported domains... (mAnu)

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] Lots of Frozen mails on my server
> Date: Fri, 29 Jun 2001 16:46:14 +0530
> From: Sanvir Singh Jham <sanvir.jham@???>
> To: Suresh Ramasubramanian <mallet@???>
> CC: exim-users@???
> References: <20010628150501.A1026@???> <1667.993741626@???> <20010629000154.C6249@???>
>
> Hi Suresh:
>
> I don't think the sender_reject is working, since the mails from rocke2@??? is still being coming
> in and residing on my server.
>
> I am using the following configurations as suggested by you:
>
> # mail only from resolvable domains
> sender_verify
> sender_verify_reject = true
> # dont verify anything from our own networks
> sender_verify_hosts = !localhost:!mydomain.com:!192.1
> 68.200.0/24:0.0.0.0/0
> sender_reject = @@partial-lsearch*;/etc/blacklist.senders
> # this last line may wrap - careful
> prohibition_message = "${lookup{$prohibition_reason}lsearch{/etc/reject.messages
> }{${expand:$value}}}"
>
> and in blacklist.senders the enteries are:
>
> # block rocke2@???
> norman.bay9.com: rocke2
> # block all rubbish from cypo.com
> cypo.com: *
> # block jay@???
> newtechcorp.com: jay
> # admin__@any-domain is a virus mail
> *: admin__
> # funglow
> flowgo.com: funonabun : updates : stoneage
> # block some giftlist
> planetgroupe.com: gartner
> hotmail.com: jtoddkline
> mail.cistemsindia.com: kkmehrotra
> flashmail.com: smilie1000
> icecom.ice.co.cr: ehf4mmkJE
> robotmail.ne.jp: godfrey12a
> dq.directqlick.com: mail
>
> I have put in the colons as suggested in the exim manual, after it did not work in the initial config as
> suggested by you. But, it doesn't seem to work now also.
>
> I am clueless, pls give more pointers as to how I can solve this issue.
>
> Thanks in advance
>
> Regards,
> Sanvir
>
> Suresh Ramasubramanian wrote:
>
> > Sheldon Hearn [exim-users] <28/06/01 17:20 +0200>:
> > > On Thu, 28 Jun 2001 15:05:01 +0530, Suresh Ramasubramanian wrote:
> > >
> > > > sender_verify tends to take its own time about it, politely assuming that the
> > > > sending mailserver has a DNS problem - and returns 4xx errors the first few
> > > > times. A straightforward "550 Get lost spammer" works far better for me.
> > >
> > > If that works for you, great. However, in an environment where you're
> > > offering a corporate pop-before-smtp relay service, an immediate "Get
> > > lost spammer" [1] because of a transient DNS failure isn't smart.
> >
> > This seems to be a communication gap. I use sender_verify for the case you
> > mention - and I'm happy with the 4xx it returns. As I control a fairly large
> > corporate network or two (and some mobile phone <-> sms gateway servers) I
> > can't return a 550 on transient dns failures.
> >
> > However, for deliberately broken dns (spammers configuring their MXs to point
> > to an IP, or just rejecting mail from:<> and stuffing my queue full of junk)
> > I prefer to use sender_reject.
> >
> > That's all I said. Sorry if I didn't make myself clear enough.
> >
> >         --suresh

> >
> > --
> > Suresh Ramasubramanian <--> mallet <at> efn <dot> org
> > EMail Sturmbannfuhrer, Lower Middle Class Unix Sysadmin
> >
> > --
> > ## List details at http://www.exim.org/mailman/listinfo/exim-users Exim details at http://www.exim.org/ ##
>
> --
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Sanvir Singh Jham                   Tel: 694 1831/6619/6612/8617/ 5226/7/8
> Velocient Technologies Limited      Fax: 694 3732
> New Delhi                           E-Mail:sanvir.jham@???
>                                             ssjham@???
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>                          Just Believe in the Best

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] LDAP woes
> Date: Fri, 29 Jun 2001 12:23:04 +0100 (BST)
> From: Philip Hazel <ph10@???>
> To: Lauri Tischler <lauri.tischler@???>
> CC: "exim-users@???" <exim-users@???>
>
> On Fri, 29 Jun 2001, Lauri Tischler wrote:
>
> > ps. is The Book out?
> > Local bookstore said 15.6 but thats gone allready.
>
> O'Reilly said June 27th, but yesterday I heard "any day now". That is
> for publication in the US. It then takes a couple of weeks before it
> gets to Europe, I was told.
>
> --
> Philip Hazel            University of Cambridge Computing Service,
> ph10@???      Cambridge, England. Phone: +44 1223 334714.

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] uid/gid
> Date: Fri, 29 Jun 2001 12:26:19 +0100 (BST)
> From: Philip Hazel <ph10@???>
> To: Sheldon Hearn <sheldonh@???>
> CC: exim <exim-users@???>
>
> On Fri, 29 Jun 2001, Sheldon Hearn wrote:
>
> > No chance of allowing the use of compile-time names instead of numbers?
>
> If you can tell me how to persuade the C compiler to do the lookup...
>
> Actually, I'm kidding. The data is preprocessed before it gets made into
> anything the compiler sees, so I could probably make it support names.
> (The use of numbers goes back into Exim pre-history.) I'll look into it.
>
> --
> Philip Hazel            University of Cambridge Computing Service,
> ph10@???      Cambridge, England. Phone: +44 1223 334714.

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] 2 patches for exim 3.30
> Date: Fri, 29 Jun 2001 12:29:26 +0100 (BST)
> From: Philip Hazel <ph10@???>
> To: Marc MERLIN <marc_news@???>
> CC: <exim-users@???>
>
> On Fri, 29 Jun 2001, Marc MERLIN wrote:
>
> > I am aware that they may never make it in the main exim 3.x tree since it's
> > not actively maintained anymore, but that's ok. If they can be useful to
> > you, this mail wasn't useless :-)
>
> Just to be pedantic in case anybody gets worried by that statement about
> Exim 3. It *is* actively maintained, but no new functionality is to be
> added. In other words, bugs will still be fixed and new releases may
> happen.
>
> I don't want the phrase "Exim isn't being maintained" to become widely
> believed!
>
> --
> Philip Hazel            University of Cambridge Computing Service,
> ph10@???      Cambridge, England. Phone: +44 1223 334714.

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] Lots of Frozen mails on my server
> Date: Fri, 29 Jun 2001 16:51:43 +0530
> From: Suresh Ramasubramanian <mallet@???>
> Organization: Hopelessly Disorganized
> To: exim-users@???
> References: <20010628150501.A1026@???> <1667.993741626@???> <20010629000154.C6249@???> <3B3C637E.84651DAB@???>
>
> Sanvir Singh Jham [exim-users] <29/06/01 16:46 +0530>:
>
> > I don't think the sender_reject is working, since the mails from
> > rocke2@??? is still being coming
> > in and residing on my server.
>
> > sender_reject = @@partial-lsearch*;/etc/blacklist.senders
>
> And what does your blacklist.senders look like?
>
> > # block rocke2@???
> > norman.bay9.com: rocke2
>
> *.bay9.com              *

>
> or check the envelope sender ...
>
> and restart exim after applying changes to the config file.
>
> > flowgo.com: funonabun : updates : stoneage
>
> flowgo.com      *  (note teh format below)

>
> vsnl.com        linux:gtcdrom:samtec:lunkar:extractsoft:extractsoft1:digitalpages:globalcs:pauldiamonds:linit

>
> > # block some giftlist
> > planetgroupe.com: gartner
>
> no colon after the domain!
>
> --
> Suresh Ramasubramanian <--> mallet <at> efn <dot> org
> EMail Sturmbannfuhrer, Lower Middle Class Unix Sysadmin
>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] FreeBSD 4.3 - Exim and mailer.conf
> Date: Fri, 29 Jun 2001 12:32:40 +0100 (BST)
> From: Philip Hazel <ph10@???>
> To: Sheldon Hearn <sheldonh@???>
> CC: "Exim-Users@Exim. Org" <exim-users@???>
>
> On Fri, 29 Jun 2001, Sheldon Hearn wrote:
>
> > FreeBSD doesn't supply a purgestat link to mailwrapper(8), so unless we
> > supplied such a script with the port, it wouldn't do much good.
> >
> > If Philip wants this, I can certainly add it.
> >
> > Philip, FreeBSD's mailwrapper has the following names:
> >
> > sendmail
> > send-mail
> > mailq
> > newaliases
>
> How widespread is mailwrapper(8)? Is it only FreeBSD? If so, it's best
> left (IMHO) to the FreeBSD port.
>
> --
> Philip Hazel            University of Cambridge Computing Service,
> ph10@???      Cambridge, England. Phone: +44 1223 334714.

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] uid/gid
> Date: Fri, 29 Jun 2001 12:37:23 +0100
> From: Tim Waugh <twaugh@???>
> To: Philip Hazel <ph10@???>
> CC: Sheldon Hearn <sheldonh@???>, exim <exim-users@???>
> References: <23308.993807428@???> <Pine.SOL.4.33.0106291223120.24920-100000@???>
>
> On Fri, Jun 29, 2001 at 12:26:19PM +0100, Philip Hazel wrote:
>
> > If you can tell me how to persuade the C compiler to do the lookup...
> >
> > Actually, I'm kidding. The data is preprocessed before it gets made into
> > anything the compiler sees, so I could probably make it support names.
> > (The use of numbers goes back into Exim pre-history.) I'll look into it.
>
> The question then becomes: when should the names be bound to UIDs? If
> the answer is 'at build time', then the advantage over the current
> situation seems quite small to me (the extra time to run 'id' if you
> can't remember the numbers, over the time already spent hand-editing
> EDITME).
>
> If the answer is 'at run time', then a whole bunch of risks start to
> appear.
>
> At least with numbers the question doesn't come up. ;-)
>
> Tim.
> */
>
>   ------------------------------------------------------------------------
>    Part 1.3.7.1.2Type: application/pgp-signature

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] uid/gid
> Date: Fri, 29 Jun 2001 06:46:40 -0500
> From: Midwest Mold <midwestmold@???>
> To: Philip Hazel <ph10@???>
> CC: Sheldon Hearn <sheldonh@???>, exim <exim-users@???>
> References: <Pine.SOL.4.33.0106290920000.24920-100000@???>
>
> So how do I select the proper uid/gid. Do I randomly select a number out of a hat,
> or are there specific considerations I don't know about. I would rather not wreck
> the entire system by my ignorance.
> Thanks!
> Tim spencer
>
> Philip Hazel wrote:
>
> > On Thu, 28 Jun 2001, Sheldon Hearn wrote:
> >
> > > As an aside, I'd urge you to leave these values out of the compile-time
> > > options and supply them as values in the configuration file. That way,
> > > you can use names instead of numbers, which may become an issue as your
> > > installation grows beyond a single host.
> >
> > I have to differ here. It is (IMHO) much safer to have these values
> > built into the binary once and for all. No risk of screwing up as a
> > consequence of an accident while editing the runtime config.
> >
> > In fact, in Exim 4 you will be required to supply values at compile
> > time, though you could supply 0,0 and still override in the runtime
> > configuration if you really want to.
> >
> > Where you specify the uid does in fact make a difference. Here is a
> > comment from the Exim source, in code with comes before the runtime
> > configuration is read:
> >
> > /* If the configuration file name has been altered by an argument on the
> > command line (either a new file name or a macro definition) and the caller is
> > not root or the exim user, or if this is a filter testing run, remove any
> > setuid privilege the program has, and run as the underlying user. */
> >
> > The "exim user" that is referred to at that point is the value built
> > into the binary (obviously, really, since it hasn't read the runtime
> > configuration yet). This has to happen this way so that unprivileged
> > users can't use -C to read files to which they have no access.
> >
> > Further down in the Exim code, we have
> >
> > /* If we have removed the setuid privilege because of -C or -D, and it turns
> > out we were running as the exim user defined in the configuration file, log
> > an error, because this doesn't work. The exim user has to be built into the
> > binary for -C/-D to retain privilege. */
> >
> > --
> > Philip Hazel            University of Cambridge Computing Service,
> > ph10@???      Cambridge, England. Phone: +44 1223 334714.

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] FreeBSD 4.3 - Exim and mailer.conf
> Date: Fri, 29 Jun 2001 13:40:55 +0200
> From: Sheldon Hearn <sheldonh@???>
> To: Philip Hazel <ph10@???>
> CC: "Exim-Users@Exim. Org" <exim-users@???>
>
> On Fri, 29 Jun 2001 12:32:40 +0100, Philip Hazel wrote:
>
> > How widespread is mailwrapper(8)? Is it only FreeBSD? If so, it's best
> > left (IMHO) to the FreeBSD port.
>
> OpenBSD, FreeBSD and NetBSD. I don't know about the rest of the world.
> :-)
>
> But your advice applies regardless. Whether something's avilable in all
> BSDs or just one, we're still not talking about a hugely representative
> sample. ;-)
>
> Ciao,
> Sheldon.
>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] uid/gid
> Date: Fri, 29 Jun 2001 08:51:28 -0300
> From: Patrick Boutilier <boutilpj@???>
> To: exim <exim-users@???>
> References: <Pine.SOL.4.33.0106290920000.24920-100000@???> <3B3C6AA0.4E33FCA3@???>
>
> Create a user call exim (and a group called exim if your system doesn't
> automatically create one when creating the exim user) and then check
> /etc/passwd to get the numeric uid/gid of the exim user.
>
> Midwest Mold wrote:
>
> >So how do I select the proper uid/gid. Do I randomly select a number out of a hat,
> >or are there specific considerations I don't know about. I would rather not wreck
> >the entire system by my ignorance.
> >Thanks!
> >Tim spencer
> >
>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] delivery for frozen mails
> Date: Fri, 29 Jun 2001 13:20:54 +0200
> From: Sheldon Hearn <sheldonh@???>
> To: Suresh Ramasubramanian <mallet@???>
> CC: exim-users@???
>
> On Fri, 29 Jun 2001 16:17:33 +0530, Suresh Ramasubramanian wrote:
>
> > The way to go would be
> >
> > exim -Mrm `mailq|grep \<\>|cut -c 11-27`
> >
> > [assuming you want to get rid of _all_ bounces in your queue]
>
> I find the following Perl5 script useful. It allows me to strip
> recipients from messages, given a sender pattern and a recipient
> pattern. If it strips a recipient address from a message that is
> frozen, the message is thawed.
>
> Sometimes, this script will leave messages on the queue with no
> recipient addresses, but the next queue run catches them, so it's not a
> real issue for me.
>
> To achieve the example you gave above, you'd use:
>
>         exim_striprecip "" ".*"

>
> Ciao,
> Sheldon.
>
> --------
> #!/usr/bin/perl -w
>
> use strict;
>
> my $PROGNAME = "exim_striprecip";
> my $EXIM_PATH = "/usr/local/sbin/exim";
>
> my ($line, $match_recip, $match_sender);
>
> if (not defined($ARGV[0]) && defined($ARGV[1]) && !defined($ARGV[2])) {
>         die "usage: $PROGNAME sender_addr_regex recip_addr_regex\n";
> }
> $match_sender = $ARGV[0];
> $match_recip = $ARGV[1];

>
> open(QUEUE, "$EXIM_PATH -bp |");
>
> $line = <QUEUE>;
> OUTER: while ($line) {
>         my ($frozen, $msg_id, $recip, $sender);

>
>         if ($line !~ / ([a-zA-Z0-9-]+) <($match_sender)>( \*\*\* frozen|)/) {
>                 $line = <QUEUE>;
>                 next;
>         }

>
>         ($msg_id, $sender, $frozen) = ($1, $2, $3);
>         $line = <QUEUE>;
>         while ($line !~ /<.*>/) {
>                 if ($line =~ /  \b($match_recip)$/) {
>                         $recip = $1;
>                         system("$EXIM_PATH -Mmd $msg_id $recip");
>                         if ($frozen) {
>                                 system("$EXIM_PATH -Mt $msg_id");
>                                 $frozen = 0;
>                         }
>                 }
>                 if (not $line = <QUEUE>) {
>                         last OUTER;
>                 }
>         }
> }

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] uid/gid
> Date: Fri, 29 Jun 2001 14:09:02 +0100 (BST)
> From: Philip Hazel <ph10@???>
> To: Tim Waugh <twaugh@???>
> CC: Sheldon Hearn <sheldonh@???>, exim <exim-users@???>
>
> On Fri, 29 Jun 2001, Tim Waugh wrote:
>
> > The question then becomes: when should the names be bound to UIDs? If
> > the answer is 'at build time', then the advantage over the current
> > situation seems quite small to me (the extra time to run 'id' if you
> > can't remember the numbers, over the time already spent hand-editing
> > EDITME).
>
> My answer is indeed "at build time", and I agree with you. But (a) the
> work to do it is very small and (b) there could be advantages in setting
> up build-time configurations that are used on many different systems,
> where the actual numbers are different, but the names the same.
>
> In fact, I might well put
>
> EXIM_USER = exim
>
> as the default in the EDITME file, for instance.
>
> > If the answer is 'at run time', then a whole bunch of risks start to
> > appear.
>
> Indeed.
>
> --
> Philip Hazel            University of Cambridge Computing Service,
> ph10@???      Cambridge, England. Phone: +44 1223 334714.

>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] uid/gid
> Date: Fri, 29 Jun 2001 15:13:10 +0200
> From: Sheldon Hearn <sheldonh@???>
> To: Philip Hazel <ph10@???>
> CC: Tim Waugh <twaugh@???>, exim <exim-users@???>
>
> On Fri, 29 Jun 2001 14:09:02 +0100, Philip Hazel wrote:
>
> > In fact, I might well put
> >
> > EXIM_USER = exim
> >
> > as the default in the EDITME file, for instance.
>
> That would score first prize, I reckon. :-)
>
> Ciao,
> Sheldon.
>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] uid/gid
> Date: Fri, 29 Jun 2001 13:55:09 +0200
> From: Sheldon Hearn <sheldonh@???>
> To: Midwest Mold <midwestmold@???>
> CC: Philip Hazel <ph10@???>, exim <exim-users@???>
>
> On Fri, 29 Jun 2001 06:46:40 EST, Midwest Mold wrote:
>
> > So how do I select the proper uid/gid. Do I randomly select a number
> > out of a hat, or are there specific considerations I don't know
> > about. I would rather not wreck the entire system by my ignorance.
>
> First, pick numbers that aren't already in use, unless they're reserved
> for the username and group that you want to use (e.g. an existing group
> mail).
>
> Then, if you work with a distributed environment (for example, you use
> NFS), try to choose numbers that won't be reserved on your other hosts
> either.
>
> In fact, it's the NFS case that blocks the addition of an mta username
> to FreeBSD every time the issue is raised. :-(
>
> Ciao,
> Sheldon.
>
> ------------------------------------------------------------------------
>
> Subject: Re: [Exim] uid/gid
> Date: Fri, 29 Jun 2001 15:17:36 +0200
> From: Sheldon Hearn <sheldonh@???>
> To: Philip Hazel <ph10@???>
> CC: exim <exim-users@???>
>
> On Fri, 29 Jun 2001 12:26:19 +0100, Philip Hazel wrote:
>
> > Actually, I'm kidding. The data is preprocessed before it gets made into
> > anything the compiler sees, so I could probably make it support names.
> > (The use of numbers goes back into Exim pre-history.) I'll look into it.
>
> Actually, I'm thinking more of a runtime lookup, a la getpwuid(). I
> realize getpwuid() and friends were ommitted in POSIX 1003.1, but its
> included in the new draft, conditional on {_POSIX_SYSTEM_DATABASE}.
>
> And how many systems don't actually support it? :-)
>
> Ciao,
> Sheldon.
>
> ------------------------------------------------------------------------
>
> Subject: [Exim] Maximun numbers of supported domains...
> Date: Fri, 29 Jun 2001 15:58:46 +0200 (CEST)
> From: mAnu <mcardenas@???>
> To: exim-users@???
>
>         Hello!

>
>         How many local domains is supported by exim?

>
>         I think that if I use lookups there isn't limit, but I use static
> files or static lists the limit exist. Where?

>
>         Bye!

>
> --
>
> Manuel Cardeñas - aka... mAnu
> mcardenas@???
> IP Sistemas.
>
> --
>
> "There are two major products that come out of Berkeley: LSD and UNIX.
> We don't believe this to be a coincidence." -- Jeremy Anderson
>
> ------------------------------------------------------------------------
> --
> ## List details at http://www.exim.org/mailman/listinfo/exim-users Exim details at http://www.exim.org/ ##