Open monochromec opened 8 months ago
local_domain
gets set based on the value of overwrite.cli.url
per the code:
It's briefly mentioned in the docs under a note.
It doesn't appear we set any other fallback on our own, so Symfony's default - which appears to be [127.0.0.1]
- I'd expect to otherwise be used.
I'm wondering if we should set the fallback ourselves, choosing something reasonable if overwrite.cli.url
isn't set, such as the value of mail_from
.
In that case, either the documentation needs clarification concerning the mail_domain
parameter or the code readjusting to reflect the documentation :-).
Where does it say in the documentation that mail_domain
has anything to do with EHLO?
`The default domain name used for the sender address is the hostname where your Nextcloud installation is served. If you have a different mail domain name you can override this behavior by setting the following configuration parameter:
"mail_domain" => "example.com`
https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/email_configuration.html
Per SMTP specification, EHLO
The quoted part, including the example, is about the sender address / from.
Per SMTP specification, EHLO should be the sending domain. Which is precisely this use case.
I read the related part of the specification, https://www.rfc-editor.org/rfc/rfc5321#section-3.2, a bit different. EHLO should be an identifier for the connecting client, that can be the sending domain but also something different.
Also check the discussion in https://github.com/nextcloud/server/issues/29011.
From the link you quoted:
"In the EHLO command, the host sending the command identifies itself; the command may be interpreted as saying "Hello, I am
I rest my case :-).
I guess it's fine to add another configuration option to expose the local domain if there's the need for some to set a different value to overwrite.cli.url.
We are accepting pull requests :)
⚠️ This issue respects the following points: ⚠️
Bug description
When configuring an SMTP host, one would expect the content of the config parameter
mail_domain
to be used as the FQDN for the SMTP handshake when issuing an EHLO response (per documentation in https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/email_configuration.html ).Regardless of configuration, the content of this variable doesn't find it into the Symfony Mail SMTP transport component configuration dictionary entry
local_domain
as one would expect.Steps to reproduce
Expected behavior
FQDN is used when performing the initial HELO/EHLO handshake as per SMTP spec.
Installation method
Community Manual installation with Archive
Nextcloud Server version
28
Operating system
Debian/Ubuntu
PHP engine version
PHP 8.2
Web server
Apache (supported)
Database engine version
SQlite
Is this bug present after an update or on a fresh install?
Upgraded to a MAJOR version (ex. 22 to 23)
Are you using the Nextcloud Server Encryption module?
Encryption is Disabled
What user-backends are you using?
Configuration report
List of activated Apps
Nextcloud Signing status
Nextcloud Logs
Additional info
Please let me know if more info is required - happy to help!