mirror of
https://github.com/opensolutions/ViMbAdmin.git
synced 2026-04-26 00:36:00 +03:00
[PR #290] [MERGED] Mailbox Automatic Aliases 2.0 #311
Labels
No labels
bug
feature
feature
improvement
improvement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ViMbAdmin-opensolutions#311
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/opensolutions/ViMbAdmin/pull/290
Author: @PhrozenByte
Created: 7/20/2022
Status: ✅ Merged
Merged: 2/23/2023
Merged by: @barryo
Base:
master← Head:enhancement/AutoAliases2📝 Commits (1)
713e5edMailbox Automatic Aliases 2.0📊 Changes
5 files changed (+436 additions, -227 deletions)
View changed files
📝
application/configs/application.ini.dist(+3 -12)📝
application/configs/application.ini.vagrant(+14 -8)📝
application/controllers/AliasController.php(+1 -1)📝
application/controllers/MailboxController.php(+14 -10)📝
application/plugins/MailboxAutomaticAliases.php(+404 -196)📄 Description
Refactors @mfechner's
ViMbAdminPlugin_MailboxAutomaticAliases. The new plugin is fully backwards compatible, but adds a whole lot of flexibility.One can now use plain usernames as default mapping (
defaultMapping.abuse = "postmaster"creates an alias abuse@example.com -> postmaster@example.com), as well as domain wildcards (defaultMapping.abuse = "@example.net"creates an alias abuse@example.com -> abuse@example.net). Additionally there's a wildcard mapping to simplify configuration (defaultMapping.* = "root@example.com"causes all automatic aliases without explicit default mapping to redirect to root@example.com). The plugin will furthermore respect full domain aliases (@example.com -> @example.net), bypassing the need to create distinct automatic aliases, since they are caught by the domain alias anyway.Protection rules are now fully enforced. Next to preventing domain admins to delete mailboxes that are used as goto address for an automatic alias, the plugin now enforces the same when disabling a mailbox, and when deleting or disabling another alias that is used as goto address. The plugin no longer relies on the default mappings for these checks, but actually checks the alias' goto address. As before, the actual automatic aliases are protected as well. The same now applies to domain aliases when there are no distinct automatic aliases.
Please note that protection rules aren't enforced recursively and not accross domain boundaries. These checks didn't exist before and IMHO aren't really worth the effort.
Also adds the
mailbox_toggleActive_preToggleevent and fixes the output of thealias_toggleActive_preToggleevent.Also see #179
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.