header checks

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

header checks

Gabriele Brosulo
Hi all,
I need to permit address [hidden email] to send email whith no To and Cc address,
just Bcc ones.. When that address try to send such messagges recive a 'My
name isn't Undisclosed Recipients' error.
I tryed the following configuration, but it still dosen't work..

dns1:/etc/postfix# more main.cf | grep header_checks
header_checks = regexp:/etc/postfix/header_checks
dns1:/etc/postfix# more header_checks
[..snip..]
# permetto di spedire a chi usa undisclosed_recipients
/^From:.*@yyy\.com.*$/ OK

#Strange From: and To: headers
/^To: .*ndisclosed.*$/ REJECT My name isn't Undisclosed Recipients.
/^To: $/ REJECT I have a name
[..snip..]

Thanks a lot, and sorry for my bad English..

--
g4b0, linux user n. 369000
http://gabo.homelinux.com
Reply | Threaded
Open this post in threaded view
|

Re: header checks

Magnus Bäck
On Friday, July 11, 2008 at 11:08 CEST,
     Gabriele Brosulo <[hidden email]> wrote:

> I need to permit address [hidden email] to send email whith no To and Cc
> address, just Bcc ones.. When that address try to send such messagges
> recive a 'My name isn't Undisclosed Recipients' error.

Sounds like an absurd policy. What actual problem are you trying to
solve?

> I tryed the following configuration, but it still dosen't work..
>
> dns1:/etc/postfix# more main.cf | grep header_checks
> header_checks = regexp:/etc/postfix/header_checks

You can't use header_checks for this, at least not if you want it to
apply to only some messages. You need a content filter.

[...]

--
Magnus Bäck
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: header checks

Gabriele Brosulo
On Friday 11 July 2008 11:40:41 Magnus Bäck wrote:
> On Friday, July 11, 2008 at 11:08 CEST,
>
>      Gabriele Brosulo <[hidden email]> wrote:
> > I need to permit address [hidden email] to send email whith no To and Cc
> > address, just Bcc ones.. When that address try to send such messagges
> > recive a 'My name isn't Undisclosed Recipients' error.
>
> Sounds like an absurd policy. What actual problem are you trying to
> solve?

Do you think that is absurd to block all mail without To and Bcc, or to permit
such mail from just some domains?

>
> > I tryed the following configuration, but it still dosen't work..
> >
> > dns1:/etc/postfix# more main.cf | grep header_checks
> > header_checks = regexp:/etc/postfix/header_checks
>
> You can't use header_checks for this, at least not if you want it to
> apply to only some messages. You need a content filter.

Can you kindly provide an example, please?

thanks for your time

--
g4b0, linux user n. 369000
http://gabo.homelinux.com
Reply | Threaded
Open this post in threaded view
|

Re: header checks

Magnus Bäck
On Friday, July 11, 2008 at 12:00 CEST,
     Gabriele Brosulo <[hidden email]> wrote:

> On Friday 11 July 2008 11:40:41 Magnus Bäck wrote:
>
> > Sounds like an absurd policy. What actual problem are you trying
> > to solve?
>
> Do you think that is absurd to block all mail without To and Bcc,
> or to permit such mail from just some domains?

Sorry, I misread your question. I thought you wanted to reject messages
*with* To or Cc headers. Rejecting messages *without* those headers
makes more sense, but I still don't understand what actual problem
you're trying to solve.

If you want to stop spam there are much more effective methods. Spend
your time on them instead of chasing noneffective methods that (in this
case) are relatively expensive to implement.

> > You can't use header_checks for this, at least not if you want
> > it to apply to only some messages. You need a content filter.
>
> Can you kindly provide an example, please?

http://www.postfix.org/FILTER_README.html
http://www.postfix.org/SMTPD_PROXY_README.html
http://www.postfix.org/MILTER_README.html

I haven't heard of a Postfix-style content filter that'll do what you're
asking for, but perhaps there are Milters to do this.

--
Magnus Bäck
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: header checks

Gabriele Brosulo
On Friday 11 July 2008 12:36:42 Magnus Bäck wrote:

> On Friday, July 11, 2008 at 12:00 CEST,
>
>      Gabriele Brosulo <[hidden email]> wrote:
> > On Friday 11 July 2008 11:40:41 Magnus Bäck wrote:
> > > Sounds like an absurd policy. What actual problem are you trying
> > > to solve?
> >
> > Do you think that is absurd to block all mail without To and Bcc,
> > or to permit such mail from just some domains?
>
> Sorry, I misread your question. I thought you wanted to reject messages
> *with* To or Cc headers. Rejecting messages *without* those headers
> makes more sense, but I still don't understand what actual problem
> you're trying to solve.
>
> If you want to stop spam there are much more effective methods. Spend
> your time on them instead of chasing noneffective methods that (in this
> case) are relatively expensive to implement.
>
> > > You can't use header_checks for this, at least not if you want
> > > it to apply to only some messages. You need a content filter.
> >
> > Can you kindly provide an example, please?
>
> http://www.postfix.org/FILTER_README.html
> http://www.postfix.org/SMTPD_PROXY_README.html
> http://www.postfix.org/MILTER_README.html
>
> I haven't heard of a Postfix-style content filter that'll do what you're
> asking for, but perhaps there are Milters to do this.

Ok, thanks a lot! Now I'll read the link you proposed..

--
g4b0, linux user n. 369000
http://gabo.homelinux.com
Reply | Threaded
Open this post in threaded view
|

Re: header checks

mouss-2
In reply to this post by Gabriele Brosulo
Gabriele Brosulo wrote:

> On Friday 11 July 2008 11:40:41 Magnus Bäck wrote:
>  
>> On Friday, July 11, 2008 at 11:08 CEST,
>>
>>      Gabriele Brosulo <[hidden email]> wrote:
>>    
>>> I need to permit address [hidden email] to send email whith no To and Cc
>>> address, just Bcc ones.. When that address try to send such messagges
>>> recive a 'My name isn't Undisclosed Recipients' error.
>>>      
>> Sounds like an absurd policy. What actual problem are you trying to
>> solve?
>>    
>
> Do you think that is absurd to block all mail without To and Bcc, or to permit
> such mail from just some domains?
>  

it is absurd to block mail because the To is "unidsclosed recipients"
because
1- you block legitimate mail (all recipients are in Bcc header).
2- this is easily beaten. senders (spammers or legitimate) can put any
address in the To: header. Even when using "standard MUAs", people can
put a freemail address in the To: header.


did you really see a lot of spam with "To: undisclosed recipients..."?

>>> I tryed the following configuration, but it still dosen't work..
>>>
>>> dns1:/etc/postfix# more main.cf | grep header_checks
>>> header_checks = regexp:/etc/postfix/header_checks
>>>      
>> You can't use header_checks for this, at least not if you want it to
>> apply to only some messages. You need a content filter.
>>    
>
> Can you kindly provide an example, please?
>  

header_checks are global and apply to ONE header at a time.

Try spamassassin instead.