From: "J. Roeleveld" on
On Thursday 04 March 2010 15:27:45 Jonathan Tripathy wrote:
> On Thursday 04 March 2010 14:55:59 you wrote:
> > 12:24:20 Stan Hoeppner wrote:
> > > J. Roeleveld put forth on 3/4/2010 2:12 AM:
> > > > On Thursday 04 March 2010 08:57:30 Jonathan Tripathy wrote:

<snipped non-relevant part>

> > Does that mean I'd need a autosendfolderfill for each user on the system?
>
> First, please keep responses on the List to make it possible for other
> people to find it with Google and also to allow other people to keep
> contributing.
>
> As for your question:
> No, you'll only need to create one of these users. The username doesn't
> matter, as long as this user can have a filter set up and is allowed to
> post messages into the Sent-folders of all the users.
>
> You will need to create a filter-entry for each of your users, eg.
> duplicate the following inside the filter for every user that is allowed
> to sent emails: --
>
> > if header :contains "From" "me(a)mydomain.com"
> > {
> > fileinto me+Sent;
> > stop;
> > }
>
> --
>
> HTH,
>
> Joost
> ---------------------------------------------------------------------------
> -------------------------------------
>
> Does this mean that mail received from the internet is also checked against
> this filter?
>

Yes, unless you configure postfix to not apply the "bcc" configuration against
email originating from the internet.

I am not certain if this is possible, but if it isn't, this would be a usefull
additional feature.

Please check the documentation for Postfix to see how to do this.

--
Joost

From: "J. Roeleveld" on
On Thursday 04 March 2010 16:10:21 Charles Marcus wrote:
> On 2010-03-04 9:08 AM, J. Roeleveld wrote:
> >>> I am not familiar with Dovecot, but the above might be doable with
> >>> Dovecot as well.
> >>
> >> Does that mean I'd need a autosendfolderfill for each user on the
> >> system?
> >
> > No, you'll only need to create one of these users. The username
> > doesn't matter, as long as this user can have a filter set up and is
> > allowed to post messages into the Sent-folders of all the users.
> >
> > You will need to create a filter-entry for each of your users, eg.
> > duplicate the following inside the filter for every user that is
> > allowed to sent emails:> --
> >
> >> if header :contains "From" "me(a)mydomain.com"
> >> {
> >> fileinto me+Sent;
> >> stop;
> >> }
>
> Interesting... yes, this is doable with dovecot if you are using its
> LDA, and you can do it via the global sieve script (which can be made
> mandatory for all users) - no need to make a script for each user.

My idea (NOTE: untested) would only require one dummy-account where this
filtering takes place.
The basic idea should be possible to be implemented with any filtering method
along with any mail-storage option you want.
The above is a bit more specific with Sieve-scripts, but I see no reason why
this approach wouldn't work with something like "procmail"

> So... two more questions...
>
> 1. Can '-o sender_bcc_maps=hash:/etc/postfix/sender_bcc' be added to the
> submission service in master.cf? If so, I think this could work.

I have no clue :)
As mentioned before, what I described is just the theory and I have no need to
implement this myself.
By putting this on the list, I am actually hoping for people who do know to
add their comments and perhaps get this written down as a working how-to
somewhere. (Add it to the postfix HOWTO-section?)

> 2. What happens if the smtp send transaction fails? Would the message
> still be bcc'd (hopefully not?)?

I think this depends where the failure occurs.
If it occurs after the BCC-email is created, then the email still appears in
the sent-folder.

Btw, another option, which I saw described somewhere (can't remember where)
was to have the mail client store the email in a folder like: "outbox" and
then have a process on the server poll the outboxes for each user, send the
actual email and then move it to the "sent" folder when succesfully sent.

I think this method is closer to the way MS Exchange/MS Outlook works, but
this would, I think, require more work?

--
Joost

From: Noel Jones on
On 3/4/2010 9:26 AM, J. Roeleveld wrote:
>> 1. Can '-o sender_bcc_maps=hash:/etc/postfix/sender_bcc' be added to the
>> submission service in master.cf? If so, I think this could work.
>

You can find which options are valid by reading the man page
for each daemon.

All the bcc functions are properties of the cleanup daemon,
not smtpd. It's possible to define a separate cleanup service
with sender_bcc_maps for submission. See the docs for adding
an alternate cleanup service.

>
>> 2. What happens if the smtp send transaction fails? Would the message
>> still be bcc'd (hopefully not?)?

The copy is created when postfix accepts the original message.

-- Noel Jones

From: Charles Marcus on
On 2010-03-04 10:26 AM, J. Roeleveld wrote:
>> Interesting... yes, this is doable with dovecot if you are using its
>> LDA, and you can do it via the global sieve script (which can be made
>> mandatory for all users) - no need to make a script for each user.

> My idea (NOTE: untested) would only require one dummy-account where this
> filtering takes place.

Yes, but didn't you later say:

> You will need to create a filter-entry for each of your users, eg.
> duplicate the following inside the filter for every user that is
> allowed to sent emails:> --"

What I meant was, if you were using dovecots LDA, you wouldn't need to
create these user scripts, the global script could handle it for
everyone (using user variables, ie, %%Lu in this case)...

> The basic idea should be possible to be implemented with any
> filtering method along with any mail-storage option you want. The
> above is a bit more specific with Sieve-scripts, but I see no reason
> why this approach wouldn't work with something like "procmail"

Correct...

>> So... two more questions...

These two questions weren't directed at you specifically, but in general
to someone who actually knows the answers... ;)

--

Best regards,

Charles

From: "J. Roeleveld" on
On Thursday 04 March 2010 16:57:02 Charles Marcus wrote:
> On 2010-03-04 10:26 AM, J. Roeleveld wrote:
> >> Interesting... yes, this is doable with dovecot if you are using its
> >> LDA, and you can do it via the global sieve script (which can be made
> >> mandatory for all users) - no need to make a script for each user.
> >
> > My idea (NOTE: untested) would only require one dummy-account where this
> > filtering takes place.
>
> Yes, but didn't you later say:
> > You will need to create a filter-entry for each of your users, eg.
> > duplicate the following inside the filter for every user that is
> > allowed to sent emails:> --"
>
> What I meant was, if you were using dovecots LDA, you wouldn't need to
> create these user scripts, the global script could handle it for
> everyone (using user variables, ie, %%Lu in this case)...

True, but it is my understanding, please correct me if I am wrong, that with
Postfix, the BCC-option forces a copy of the email (regardless of which user
sent it) to be delivered to a single email-address?
This would, at least the way I see it, mean that the filtering only needs to
be done by a single user (the owner of the bcc-email address).

Eg:
Email client
|
Postfix -> external SMTP-server
|
BCC to <bcc-user>@mydomain
|
Postfix
|
filtering tool for user "bcc-user"
|
delivery into senders "sent" folder
sender is determined by checking the "mail-from" header

> > The basic idea should be possible to be implemented with any
> > filtering method along with any mail-storage option you want. The
> > above is a bit more specific with Sieve-scripts, but I see no reason
> > why this approach wouldn't work with something like "procmail"
>
> Correct...
>
> >> So... two more questions...
>
> These two questions weren't directed at you specifically, but in general
> to someone who actually knows the answers... ;)

True, but I tend to, when I at least have a theory, to also answer with my
theory. I hope my reply made it clear that I was not 100% certain? :)

--
Joost

First  |  Prev  |  Next  |  Last
Pages: 1 2 3 4 5
Prev: quota with mysql
Next: postfix as "dispatcher"