Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

allowing relaying in Local_check_rcpt

5 views
Skip to first unread message

Aleksandar Milivojevic

unread,
Oct 14, 2005, 4:10:47 PM10/14/05
to
I've got lines like this in access database:

From:em...@foobar.com ERROR:554 5.0.0 Not allowed

This worked for a long time nicely for what I needed it.

However, now I need to make some exceptions and allow all of those
blocked senders to send to limited list of outside recipients. The
naive attempt of enabling delay_checks feature and adding following
line hasn't really worked:

To:em...@outside.com RELAY

So I went and attempted to modify my custom Local_check_rcpt set of
rules (that I have for some other purpuses). However, even if I return
OK for particular recipient in Local_check_rcpt, the check_mail is
still called and the em...@foobar.com line from access database kicks
in and blocks relaying. Is there anything I can do in Local_check_rcpt
that would result in check_mail not to be called?

One idea I had was to define Local_check_mail ruleset, however I can't
check who is the envelope recipient from Local_check_mail (I have
delay_checks, so I guess check_mail is called for each recipient, or I
got that part wrong?). Unless I'm missing something totally obvious.

Of course, one solution could be not to use access database at all, and
implement both things (blocking and allowing) in custom
Local_check_rcpt ruleset (something like those examples on Clauss's
page are doing), but that would require total reorganization of some
other stuff that I have, so I'm attempting to avoid that.

Thanks for any and all hints/adivce/ideas,
Aleksandar Milivojevic

Claus Aßmann

unread,
Oct 21, 2005, 12:07:50 AM10/21/05
to
Aleksandar Milivojevic wrote:
> I've got lines like this in access database:

> From:em...@foobar.com ERROR:554 5.0.0 Not allowed

> This worked for a long time nicely for what I needed it.

> However, now I need to make some exceptions and allow all of those
> blocked senders to send to limited list of outside recipients. The
> naive attempt of enabling delay_checks feature and adding following
> line hasn't really worked:

> To:em...@outside.com RELAY

That doesn't work (see cf/README), but there's a trick:
Add

define(`_RELAY_FULL_ADDR_', 1)

to your mc file.

> So I went and attempted to modify my custom Local_check_rcpt set of
> rules (that I have for some other purpuses). However, even if I return
> OK for particular recipient in Local_check_rcpt, the check_mail is
> still called and the em...@foobar.com line from access database kicks
> in and blocks relaying. Is there anything I can do in Local_check_rcpt
> that would result in check_mail not to be called?

cf/README:

These rules are called with the original arguments of the corresponding
check_* ruleset. If the local ruleset returns $#OK, no further checking
is done by the features described above and the mail is accepted.

--
Note: please read the netiquette before posting. I will almost never
reply to top-postings which include a full copy of the previous
article(s) at the end because it's annoying, shows that the poster
is too lazy to trim his article, and it's wasting the time of all readers.

0 new messages