Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Account/mailbox delegation #7723

Closed
2 tasks done
Tracked by #66
miaulalala opened this issue Dec 2, 2022 · 10 comments · Fixed by nextcloud/documentation#10335
Closed
2 tasks done
Tracked by #66

Account/mailbox delegation #7723

miaulalala opened this issue Dec 2, 2022 · 10 comments · Fixed by nextcloud/documentation#10335
Assignees
Labels
2. developing enhancement feature: mailbox sharing Sharing ACLs for Mailboxes skill:backend Issues and PRs that require backend development skills skill:frontend Issues and PRs that require JavaScript/Vue/styling development skills

Comments

@miaulalala
Copy link
Contributor

miaulalala commented Dec 2, 2022

Is your feature request related to a problem? Please describe.

As shared mailboxes are often used for cases such as support or contact mailboxes, a user might not want to expose their private email address when sending an email from that mailbox.

Describe the solution you'd like

Case A - not everyone needs to see sent replies

Add an alias for the shared mailbox email address and allow it to be selected from the alias dropdown. This could also include fancy stuff like having the Display Name still set to the current user but still having the shared email address as the FROM email address.

Case B - everyone should see the sent replies

Admins or users should be able to set a custom "sent" mailbox. I don't think it's neccessary or even possible for this mailbox to be a special use mailbox "\SENT".

This custom "sent" mailbox will need to be a shared mailbox and the sending user needs ACL permissions lrwip on the custom "sent" mailbox.

  • Allow setting the shared mailbox email address as a sender in the alias dropdown
  • After sending, move the sent email not to the user's SENT mailbox but also COPY it to the shared "sent" mailbox

Describe alternatives you've considered

If it isn't possible to send from alternative senders in Horde, allow setting the Reply-To header to the shared mailbox email address - either by handling a sending fail and resending the email automatically in the backend, or by allowing the user to have a "FROM - REPLY-TO" configuration stored.

Additional context

#7057

Outlook 365 by default has no shared sent mailbox but needs to be set up specifically: https://learn.microsoft.com/en-us/microsoft-365/admin/email/configure-a-shared-mailbox?view=o365-worldwide#allow-everyone-to-see-the-sent-email-the-replies

Investigative findings

Delegation can mean many things:

  • Case A: A complete new mail account that is provisioned to the users which works as a normal mail account. Several users are logged in at the same time. This concept already works.
  • Case B: A mail box that i can fetch mail from. Solved via ACLs
  • Case C: A shared mailbox where I am allowed to send as.

Implementation ideas

For admins

  • define email accounts and their aliases in settings (as configured on the mail server)
  • possibly define shared "sent" mailboxes that "send as" messages should be copied to

For users

  • be able to delegate based on admin aliases definition
    • should create a new alias for delegated users
  • be able to see and choose "send as" aliases
  • possibly be able to differentiate between their own aliases and delegated aliases
  • delegated aliases should be read only
  • be able to define a shared "sent" mailbox when delegating their account where "send as" sent emails are copied to.

Work packages

@miaulalala miaulalala added enhancement 0. to triage 1. to develop skill:backend Issues and PRs that require backend development skills skill:frontend Issues and PRs that require JavaScript/Vue/styling development skills feature: mailbox sharing Sharing ACLs for Mailboxes and removed 0. to triage labels Dec 2, 2022
@ChristophWurst ChristophWurst changed the title Sending an email from a shared mailbox Delegation Dec 6, 2022
@ChristophWurst
Copy link
Member

Bildschirmfoto vom 2022-12-06 10-45-13

Sogo can do it.

There is also a setting in mailcow

Bildschirmfoto vom 2022-12-06 10-41-10

@ChristophWurst ChristophWurst changed the title Delegation Account delegation Feb 21, 2023
@ChristophWurst ChristophWurst changed the title Account delegation Account/mailbox delegation Feb 21, 2023
@miaulalala miaulalala self-assigned this Feb 22, 2023
@miaulalala

This comment was marked as off-topic.

@miaulalala
Copy link
Contributor Author

miaulalala commented Feb 22, 2023

send request in sogo (user nctest2 with delegation from nctest1):

{
    "to": [
        "xxxxxxxx@gmail.com"
    ],
    "cc": [],
    "bcc": [],
    "isHTML": 1,
    "text": "Rwa",
    "from": "nctest1 <nctest1@bitgrid.net>",
    "locale": "en",
    "subject": "Test"
}

With delegation I see all aliases of the delegating user in the delegated to user.
An example:
nctest1 delegates to nctest2
nctest2 shows all aliases for nctest1 in the dropdown for the "From:" address.

@miaulalala
Copy link
Contributor Author

@miaulalala
Copy link
Contributor Author

@miaulalala
Copy link
Contributor Author

@ChristophWurst
Copy link
Member

Moving from target Nextcloud 26 to 27

@ChristophWurst
Copy link
Member

Tested account delegation on two accounts on mailcow.

  1. Account 1 was configured to be allowed to send as account 2.
  2. I set up account 1 in Mail
  3. I added an alias for account 2's email to account 1
  4. I sent an email from account but select the account 2 alias as sender

Message is sent as if account 2 sent it ✔️

@ChristophWurst
Copy link
Member

Phrazed differently: it works with existing features. There are certainly setups where the alias should come automagically but a manual setup is possible today. We will document the steps and limitations.

@nielsranosch
Copy link

Thank you for documenting the delegation with mail server. Unfortunately, the mail server we use does not support delegation, and - in my estimation - most small mail providers will not support it. And even if it did, I think there is still a gap: A group mailbox. I think a mailbox that is assigned to a group (in Nextcloud) would be a good option to kill two birds with one stone: both non-personal mailboxes (NPMs) and mailbox delegation could be covered with it.

Would you be open to adding a "group mailbox" feature to the backlog?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2. developing enhancement feature: mailbox sharing Sharing ACLs for Mailboxes skill:backend Issues and PRs that require backend development skills skill:frontend Issues and PRs that require JavaScript/Vue/styling development skills
Projects
Development

Successfully merging a pull request may close this issue.

4 participants