Disable outgoing mail

Locked
prune
Posts: 85
Joined: Thu 14. Nov 2019, 11:22

Disable outgoing mail

Post by prune »

Hello,

Is it possible to disable outgoing mail for a user account? Just 1 account or just a mailbox in an account? If not disable, maybe just set to pending/for approval?

I want mailboxes for an account to be used for incoming mail only.
prune
Posts: 85
Joined: Thu 14. Nov 2019, 11:22

Re: Disable outgoing mail

Post by prune »

Hello,

Can someone assist in having KH block all outgoing mails for an account and allow only certain email addresses to send?
User avatar
george
Posts: 87
Joined: Fri 3. Jan 2020, 05:53
Location: AUSTRALIA

Re: Disable outgoing mail

Post by george »

Hi Prune,
this interested me, so...

I don't think there is such facility in KeyHelp panel.
With a few minutes search I found the following, but have not tested, you could try this:

Open the Postfix config file:
/etc/postfix/main.cf

Insert the following code, just before the line "smtpd_client_restrictions"
(replace "user" with the username to block)

Code: Select all

authorized_submit_users = !user, static:all
source: http://www.postfix.org/postconf.5.html

To block multiple users, I assume its like so:

Code: Select all

authorized_submit_users = !user, !user2, !user3, static:all
Save the file, then restart postfix.

Let us know how you go.
Locked