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

Email invitation for events should come from the user's email address, not server's [$20] #25470

Closed
fracture-point opened this issue Jul 13, 2016 · 24 comments

Comments

@fracture-point
Copy link

fracture-point commented Jul 13, 2016

Steps to reproduce

Using OC 9.0.3 + Calendar 1.2.2, invite someone to calendar event.
The outbound email "From" address shows as the server from, configured in
Admin-->Email Server-->From Address.

The email should come from the user's configured email address, not the server. This is especially confusing when the OC instance is host for a number of unrelated domains.

Expected behaviour

Tell us what should happen

Actual behaviour

Tell us what happens instead

Server configuration

Operating system:
Ubuntu 14.04
Web server:
Apache 2.4.7
Database:
MariaDB 10.0.26
PHP version:
php 5.5.9
ownCloud version: (see ownCloud admin page)
9.0.3
Contacts version: (see ownCloud apps page)
1.3.1.0 (calendar = 1.2.2)
Updated from an older ownCloud or fresh install:
Updated from 8.2.2
Signing status (ownCloud 9.0 and above):

No errors have been found.

List of activated apps:
Enabled:

activity: 2.2.1
calendar: 1.2.2
comments: 0.2
contacts: 1.3.1.0
dav: 0.1.6
federatedfilesharing: 0.1.0
federation: 0.0.4
files: 1.4.4
files_pdfviewer: 0.8.1
files_sharing: 0.9.1
files_texteditor: 2.1
files_trashbin: 0.8.0
files_versions: 1.2.0
files_videoplayer: 0.9.8
gallery: 14.5.0
notifications: 0.2.3
provisioning_api: 0.4.1
systemtags: 0.2
tasks: 0.8.1
updatenotification: 0.1.0 Disabled:
bookmarks
encryption
external
files_antivirus
files_external
firstrunwizard
news
notes
templateeditor
user_external
user_ldap

The content of config/config.php:

Are you using external storage, if yes which one: local/smb/sftp/...
No
Are you using encryption: yes/no
No
Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/...
No

Client configuration

Browser:
Chrome / Safari
Operating system:
OS X El Cap
CalDAV-clients:

Logs

Web server error log

N/A

ownCloud log (data/owncloud.log)

N/A

Browser log

N/A

@DeepDiver1975 DeepDiver1975 added this to the 9.2 milestone Jul 13, 2016
@DeepDiver1975
Copy link
Member

@georgehrke interested in having a look? THX

@georgehrke georgehrke self-assigned this Jul 13, 2016
@CliffMitchell
Copy link

CliffMitchell commented Nov 25, 2016

I think you have this covered but just in case you weren't aware this issue impacts Thunderbird users when Thunderbird/Lightning calendars sync with ownCloud:

The email address that Thunderbird (TB) is using for calendar invitations is the server level email address for ownCloud, not the email address of the calendar owner on ownCloud, and not the email address set in the calendar settings in Thunderbird. Indeed in my case the email address that is being used is not even set up in TB. This makes no sense and recipients of calendar invitations get emails from a completely unknown address. Surely this is not what TB or ownCloud intends?

@fracture-point
Copy link
Author

Hate bumping this @georgehrke but this makes invites unusable, and I really don't want to switch to nextcloud...

@DeepDiver1975 DeepDiver1975 changed the title Email invitation for events should come from the user's email address, not server's Email invitation for events should come from the user's email address, not server's [$20] Feb 7, 2017
@tcitworld
Copy link
Member

Some email providers won't like this and will ban the server which sends the notification. A better solution would be to show in the From header : From %user% via %servername%.

@fracture-point
Copy link
Author

Are you assuming that the user account specifies an email from a different domain (one for which the server is not authorized to send mail), or from an email that doesn't exist? Both of those are abuse scenarios, no?. It's the OC administrator's job to make sure that the server is authenticated to send emails from whatever domain(s) users use.

Your suggestion does not work in the case of multi-domain OC installations. Why would you not just send the email from the user account's email?

@DeepDiver1975
Copy link
Member

Why would you not just send the email from the user account's email?

well - the owncloud server cannot access the users mail account (smtp server to be precise).
Owncloud can only send a email via the configured smtp account and this might hold rules which denies sending emails for somebody else.

@fracture-point
Copy link
Author

fracture-point commented Feb 8, 2017

Correct, yes, by that I meant via the e.g. postfix server configured on the box. I'm not sure why you're concerned with whether or not a functional message will bounce, when we know that what we're sending right now is not functional (there's no point in sending out calendar invites from [email protected])? If it's rejected by the outbound mail server, then the admin needs to change their mail config or mail server.

@utrautmann
Copy link

utrautmann commented Feb 14, 2017

552/5000
For me the biggest problem is that in the invitation emails only the e-mail address and not the user name in the From header field is used for the sender.
For example:
The Admin account is maintained with [email protected] and "Bill Admin" as user name.
The Owncloud user who sends the invitation is maintained with the user name "Max Meyer".
Currently only "<[email protected]" is sent with From header field. Different mail clients (f.e. Google Mail) display "admin" as sender, what is confusing.
Why is not the invitation mail sent with the From header field: "Max Meyer [email protected]".

@PVince81
Copy link
Contributor

Moving to backlog since no one seems to be working on this right now. Let me know otherwise.

@zzgab
Copy link

zzgab commented Sep 25, 2017

Suggestion here: #29093 (comment)

@ghost
Copy link

ghost commented Oct 1, 2017

Fully quoting the the above suggestion #29093 (comment) in here:

At the very least, it could be an option in the settings. Most OC admins will know to configure properly their MTA to correctly send mail on behalf of registered users of the OC instance.
If they can't, they would uncheck the "send event invites from owner's email" checkbox that we could put in the settings.

@amnesiemaniac
Copy link

amnesiemaniac commented Oct 16, 2017

Another possibility: For me owncloud does not need to send event invites. My users have Thunderbird and send their invites and mails direct from Thunderbird. So they see outgoing and sent mails - owncloud is just used as a service to synchronize between users, groups and their devices.
So I would like to see a checkbox - dont send any invites.

@zzgab
Copy link

zzgab commented Oct 16, 2017

@amnesiemaniac This is certainly a valid use case -- but in our layout, we use web-based ownCloud, and smartphone clients. It would be helpful maybe if Calendar proposed a user-level setting (SMTP details) for example, to be used by Send Invite feature. I'm currently learning the project's code-base, to check if this is any feasible.

@amnesiemaniac
Copy link

There are many use cases for owncloud in different flavors.
Maybe a config-option for mailhandling in config.php would be enough.

@amnesiemaniac
Copy link

@DeepDiver1975 please change label from enhancement to bug. This bug is already existing and nobody is looking at it

@ownclouders
Copy link
Contributor

Hey, this issue has been closed because the label status/STALE is set and there were no updates for 7 days. Feel free to reopen this issue if you deem it appropriate.

(This is an automated comment from GitMate.io.

@vh-solutions
Copy link

Hi, what is the current state?

@zzgab
Copy link

zzgab commented Mar 21, 2018

@git-darius Didn't have any time to investigate, unfortunately. I hope someone will come up with a patch :)

@robertoschwald
Copy link

Still no solution for this?

xiboulay added a commit to xiboulay/core that referenced this issue Oct 30, 2018
To solve the problem described here owncloud#25470
@xiboulay
Copy link

Hi, editing the file https://github.com/owncloud/core/blob/master/apps/dav/lib/CalDAV/Schedule/IMipPlugin.php and adding the instruction ->setFrom([$sender => $senderName]) between lines 123 and 124 solved the problem

@drohhyn
Copy link

drohhyn commented Feb 5, 2019

Hi, editing the file https://github.com/owncloud/core/blob/master/apps/dav/lib/CalDAV/Schedule/IMipPlugin.php and adding the instruction ->setFrom([$sender => $senderName]) between lines 123 and 124 solved the problem

Would you please create a pull request?

@valentinstn
Copy link

@drohhyn I added a pull request.

@PVince81
Copy link
Contributor

will be released in 10.2

@KsmoinO
Copy link

KsmoinO commented Jul 21, 2019

Hello

This change causes my mail server to refuse sending mail.
In fact, I use an authenticated SMTP server which does not allow using "envelope mail from" address different from account one. This prevent SMTP spoofing.
Is it possible to reopen the case and apply one of the following:

  • add the possibility to avoid this change on SMTP server settings ?
  • use from headers instead of mail from envelope ?
  • permit each users ton configure their smtp settings to override default server one ?

Regards.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests