Author Topic: Roundcube PostfixAdmin Alias's  (Read 3989 times)

Offline dylan_pedro

  • Newbie
  • *
  • Posts: 4
Roundcube PostfixAdmin Alias's
« on: December 23, 2017, 09:12:24 PM »
Hi,

I have a number of domains setup on postfix admin which also have a number of alias each.

The problem is, when I log into RoundCube, I am able to set up an identity for a completely different domain and still send an email.

How do I make sure the logged in user can only send from their own domain and only alias's setup for their domain?

Kind Regards,
Pedro

Offline JohnDoh

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2,855
Re: Roundcube PostfixAdmin Alias's
« Reply #1 on: December 24, 2017, 04:48:59 AM »
Have a look at this config opton:
Code: [Select]
// Set identities access level:
// 0 - many identities with possibility to edit all params
// 1 - many identities with possibility to edit all params but not email address
// 2 - one identity with possibility to edit all params
// 3 - one identity with possibility to edit all params but not email address
// 4 - one identity with possibility to edit only signature
$config['identities_level'] = 0;
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and more…

Offline dylan_pedro

  • Newbie
  • *
  • Posts: 4
Re: Roundcube PostfixAdmin Alias's
« Reply #2 on: December 24, 2017, 07:30:45 AM »
Hi,

This will adjust the front end of RoundCube from what I understand. I would like the change to happen in the back-end so RoundCube checks the database and only allows alias's assigned to the current user/domain?

Kind Regards,
PArd

Offline JohnDoh

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2,855
Re: Roundcube PostfixAdmin Alias's
« Reply #3 on: December 24, 2017, 09:47:33 AM »
you'd need a plugin to do something like that. you might want to look at the new_user_identity plugin which ships with roundcube. this uses an LDAP back end but it might give you a starting point. then you could populate the user's identity list at first login and use the regular config options to prevent users from altering them.
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and more…

Offline dylan_pedro

  • Newbie
  • *
  • Posts: 4
Re: Roundcube PostfixAdmin Alias's
« Reply #4 on: December 24, 2017, 09:58:41 PM »
Everything is stored in a database for postfix so will the plugin work in that kind of setup?

Offline JohnDoh

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2,855
Re: Roundcube PostfixAdmin Alias's
« Reply #5 on: December 26, 2017, 04:03:42 AM »
you could probably modify that plugin to read data from a database rather than ldap. there is also a plugin called virtuser_query which ships with rc. some of the comments in that code suggest it can also be used to create identities.
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and more…

Offline dylan_pedro

  • Newbie
  • *
  • Posts: 4
Re: Roundcube PostfixAdmin Alias's
« Reply #6 on: January 04, 2018, 08:51:48 PM »
Does anyone know how to use the virtuser_query plugin as I have followed the syntax but nothing is being pulled from the database?