I set the email address in the basic configuration, but reported a 400 error

Support intro

Sorry to hear you’re facing problems. :slightly_frowning_face:

The community help forum (help.nextcloud.com) is for home and non-enterprise users. Support is provided by other community members on a best effort / “as available” basis. All of those responding are volunteering their time to help you.

If you’re using Nextcloud in a business/critical setting, paid and SLA-based support services can be accessed via portal.nextcloud.com where Nextcloud engineers can help ensure your business keeps running smoothly.

Getting help

In order to help you as efficiently (and quickly!) as possible, please fill in as much of the below requested information as you can.

Before clicking submit: Please check if your query is already addressed via the following resources:

(Utilizing these existing resources is typically faster. It also helps reduce the load on our generous volunteers while elevating the signal to noise ratio of the forums otherwise arising from the same queries being posted repeatedly).

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can. :heart:

The Basics

  • Nextcloud Server version (e.g., 29.x.x):
    • 31
  • Operating system and version (e.g., Ubuntu 24.04):
    • centos10 docker
  • Web server and version (e.g, Apache 2.4.25):
    • docker image version
  • Reverse proxy and version _(e.g. nginx 1.27.2)
    • NOT
  • PHP version (e.g, 8.3):
    • replace me
  • Is this the first time you’ve seen this error? (Yes / No):
    • replace me
  • When did this problem seem to first start?
    • today
  • Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
    • cmd
  • Are you using CloudfIare, mod_security, or similar? (Yes / No)
    • NO

Summary of the issue you are facing:

You can see that after I click test send, it will report a 400 error. Is there a corresponding solution for this

After searchin for “smtp.qq.com” I found a lot of messages on the internet where users are reporting similar errors with all kind of client programs. Based on these messages I guess that the server somehow sends strange replies which causes Nextcloud to fail.
For further debugging you can enable enhanced mail logging, as described in the admin guide:

TransportException
Connection could not be established with host "ssl://mail..com:25": stream_socket_client(): SSL operation failed with code 1. OpenSSL Error messages: error:0A00010B:SSL routines::wrong version number
Sending mail to "Array ( [ITCenter@
.com] => admin ) " with subject “电子邮箱设置测试” failed

hello,i find this debug info .

I passed through
cp your_certificate.crt /usr/local/share/ca-certificates/
update-ca-certificates

Include both the root certificate and the certificate for the domain name itself
However, the effect remains the same even after restarting