Email Test not work in basic setup (AIO Docker)

The IP 189.91.32.41 in the error message seem to be correct.
This is not “my” tool. Everybody can use it publicly.
May you send the documentation how to set up smtp with webcenter.com.br ?

I check their website, blog and webmail, but they do not have a documentation.

But the setup is smtp.webcenter.com.br port 465 for SSL and 587 for None/TLS (I tried TLS too). Is that way I set up my clients.

Hope it helps.

Can you test it with the smtp data for scavone.net.br or any other working smtp config ? Maybe another setting in Nextcloud AIO v7.11.2 is more restrictiv than your Outlook.


Just tried a fresh new gmail account, and tried SSL and TLS settings. Same result, same log.

TransportException
Connection could not be established with host "ssl://smtp.gmail.com:465": stream_socket_client(): Unable to connect to ssl://smtp.gmail.com:465 (Operation timed out)
Sending mail to "Array ( [cesar@scavone.net.br] => Cesar Scavone ) " with subject "Teste da configuração de e-mail" failed

There might be geoblocking or a strange firewall in the mix.

A port scan from client server in angola ist:

Nmap scan report for smtp.webcenter.com.br (189.91.32.41) [host down]
Read data files from: /usr/local/bin/…/share/nmap
Note: Host seems down. If it is really up, but blocking our ping probes, try -Pn
Nmap done: 1 IP address (0 hosts up) scanned in 3.28 seconds

from a client in germany:

Nmap scan report for smtp.webcenter.com.br (189.91.32.41)
Host is up (0.23s latency).
rDNS record for 189.91.32.41: avestruz.birdsnet.com.br
Not shown: 998 filtered ports
PORT STATE SERVICE
465/tcp open smtps
587/tcp open submission

Not importand yet, just to keep this in mind.

The gmail messages shows us that we should look at the configuration and check if we even can leave the network or what causes the timeout.

I need to eat some now, and try to be back soon.

1 Like

Did you login in your GMail account and allow pemission from non Google mail clients?
I do not know, whether this still is the most recent state:

1 Like

Yes, my friend… I got certified that GMAIL is accepting SMTP.

Please let’s check the following:

ping smtp.webcenter.com.br
nmap -v -p465,587 smtp.webcenter.com.br
traceroute smtp.webcenter.com.br
curl -vk  smtp.webcenter.com.br:587
curl -vk  smtp.webcenter.com.br:465

echo bla >mail.txt

Please fill in your real credentials and execute. You should be able to copy and paste:

curl --trace-ascii -  -k smtp://smtp.webcenter.com.br:587/ \
  --mail-from *your@email.net*'\
  --mail-rcpt *your@email.net*'\
  --upload-file mail.txt\
  --user 'your@email.net:password' --ssl

Let us now

1 Like

Here we go:

ping

Last login: Sun Feb  4 15:24:57 2024 from 177.33.136.200
root@ubuntu-DTX-2gb:~# ping smtp.webcenter.com.br
PING avestruz.birdsnet.com.br (189.91.32.41) 56(84) bytes of data.
64 bytes from avestruz.birdsnet.com.br (189.91.32.41): icmp_seq=1 ttl=53 time=142 ms
64 bytes from avestruz.birdsnet.com.br (189.91.32.41): icmp_seq=2 ttl=53 time=145 ms
64 bytes from avestruz.birdsnet.com.br (189.91.32.41): icmp_seq=3 ttl=53 time=141 ms
64 bytes from avestruz.birdsnet.com.br (189.91.32.41): icmp_seq=4 ttl=53 time=141 ms

nmap

Starting Nmap 7.94 ( https://nmap.org ) at 2024-02-04 22:19 UTC
Initiating Ping Scan at 22:19
Couldn't open a raw socket. Error: Permission denied (13)

Traceroute

traceroute to smtp.webcenter.com.br (189.91.32.41), 30 hops max, 60 byte packets
 1  45.61.142.1 (45.61.142.1)  6.841 ms  6.724 ms  6.640 ms
 2  23-29-126-168.static.hvvc.us (23.29.126.168)  11.936 ms  11.900 ms  11.860 ms
 3  10.253.17.81 (10.253.17.81)  22.128 ms  22.091 ms 10.253.17.49 (10.253.17.49)  20.114 ms
 4  10.253.16.25 (10.253.16.25)  12.065 ms 10.253.16.17 (10.253.16.17)  0.872 ms 10.253.16.13 (10.253.16.13)  0.831 ms
 5  10.253.16.6 (10.253.16.6)  5.731 ms  5.662 ms 10.253.16.10 (10.253.16.10)  0.871 ms
 6  100ge0-36.core1.dal2.he.net (184.104.196.190)  33.961 ms * *
 7  port-channel8.core4.dal1.he.net (184.105.213.53)  31.973 ms * *
 8  port-channel6.core2.hou1.he.net (184.105.213.137)  32.990 ms *  32.404 ms
 9  * * *
10  206.41.108.42 (206.41.108.42)  31.923 ms  31.899 ms  31.572 ms
11  177.190.109.16 (177.190.109.16)  139.999 ms 177.190.109.18 (177.190.109.18)  141.776 ms  141.836 ms
12  177.190.108.135 (177.190.108.135)  140.692 ms 177.190.108.141 (177.190.108.141)  141.536 ms  141.498 ms
13  * * *
14  * * *
15  * * *
16  * * *
17  * * *
18  * * *
19  * * *
20  * * *
21  * * *
22  * * *
23  * * *
24  * * *
25  * * *
26  * * *
27  * * *
28  * * *
29  * * *
30  * * *

curl 587

*   Trying 189.91.32.41:587...
* connect to 189.91.32.41 port 587 failed: Connection timed out
* Failed to connect to smtp.webcenter.com.br port 587 after 129279 ms: Connection timed out
* Closing connection 0
curl: (28) Failed to connect to smtp.webcenter.com.br port 587 after 129279 ms: Connection timed out

curl 465

*   Trying 189.91.32.41:465...
* connect to 189.91.32.41 port 465 failed: Connection timed out
* Failed to connect to smtp.webcenter.com.br port 465 after 130126 ms: Connection timed out
* Closing connection 0
curl: (28) Failed to connect to smtp.webcenter.com.br port 465 after 130126 ms: Connection timed out

--------

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0== Info:   Trying 189.91.32.41:587...
  0     0    0     0    0     0      0      0 --:--:--  0:02:09 --:--:--     0== Info: connect to 189.91.32.41 port 587 failed: Connection timed out
== Info: Failed to connect to smtp.webcenter.com.br port 587 after 130659 ms: Connection timed out
  0     0    0     0    0     0      0      0 --:--:--  0:02:10 --:--:--     0
== Info: Closing connection 0
curl: (28) Failed to connect to smtp.webcenter.com.br port 587 after 130659 ms: Connection timed out

--------

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0== Info:   Trying 189.91.32.41:465...
  0     0    0     0    0     0      0      0 --:--:--  0:02:10 --:--:--     0== Info: connect to 189.91.32.41 port 465 failed: Connection timed out
== Info: Failed to connect to smtp.webcenter.com.br port 465 after 130622 ms: Connection timed out
  0     0    0     0    0     0      0      0 --:--:--  0:02:10 --:--:--     0
== Info: Closing connection 0
curl: (28) Failed to connect to smtp.webcenter.com.br port 465 after 130622 ms: Connection timed out

you might add sudo to all commands please.

example:
sudo nmap -v -p465,587 smtp.webcenter.com.br

1 Like

im on root user

Ok,

let us focus on 2 things, I get:

Nmap scan report for smtp.webcenter.com.br (189.91.32.41)
Host is up (0.23s latency).
rDNS record for 189.91.32.41: avestruz.birdsnet.com.br
PORT STATE SERVICE
465/tcp open smtps
587/tcp open submission

you get:

Starting Nmap 7.94 ( https://nmap.org ) at 2024-02-04 22:19 UTC
Initiating Ping Scan at 22:19
Couldn’t open a raw socket. Error: Permission denied (13)

I can connect both with curl:

== Info: Connected to smtp.webcenter.com.br (189.91.32.41) port 465 (#0)
== Info: Connected to smtp.webcenter.com.br (189.91.32.41) port 587 (#0)

you get:

Failed to connect to smtp.webcenter.com.br port 465
Failed to connect to smtp.webcenter.com.br port 587

So we need more details about your system. Have you installed a firewall, is there anything extra in your routing? , and was there anything about your network settings. Is nmap -v localhost working? Might your provider block anything on the way out?

1 Like

Nope! nmap localhost is not working

Starting Nmap 7.94 ( https://nmap.org ) at 2024-02-04 23:43 UTC
Initiating SYN Stealth Scan at 23:43
Couldn't open a raw socket. Error: Permission denied (13)

:thinking:

Is nmap installed ?

apt-cache policy nmap

Looks like it is installed…

nmap:
  Installed: 7.91+dfsg1+really7.80+dfsg1-2ubuntu0.1
  Candidate: 7.91+dfsg1+really7.80+dfsg1-2ubuntu0.1
  Version table:
 *** 7.91+dfsg1+really7.80+dfsg1-2ubuntu0.1 500
        500 http://archive.ubuntu.com/ubuntu jammy-updates/universe amd64 Packages
        100 /var/lib/dpkg/status
     7.91+dfsg1+really7.80+dfsg1-2build1 500
        500 http://archive.ubuntu.com/ubuntu jammy/universe amd64 Packages

This is confusing. You are root, nmap is installed and you can’t nmap your localhost? And can’t curl properly

Please see where your nmap is?
which nmap
/usr/bin/nmap

Than execute:

/usr/bin/nmap -dd localhost -p22,443,80,587,465

For the 1st

/usr/bin/nmap

For the 2nd

Starting Nmap 7.80 ( https://nmap.org ) at 2024-02-05 00:00 UTC
Fetchfile found /usr/bin/../share/nmap/nmap-services
Fetchfile found /usr/bin/../share/nmap/nmap.xsl
The max # of sockets we are using is: 0
--------------- Timing report ---------------
  hostgroups: min 1, max 100000
  rtt-timeouts: init 1000, min 100, max 10000
  max-scan-delay: TCP 1000, UDP 1000, SCTP 1000
  parallelism: min 0, max 0
  max-retries: 10, host-timeout: 0
  min-rate: 0, max-rate: 0
---------------------------------------------
mass_rdns: Using DNS server 127.0.0.53
Fetchfile found /usr/bin/../share/nmap/nmap-payloads
Initiating SYN Stealth Scan at 00:00
Scanning localhost (127.0.0.1) [5 ports]
Packet capture filter (device lo): dst host 127.0.0.1 and (icmp or icmp6 or ((tcp or udp or sctp) and (src host 127.0.0.1)))
Discovered open port 80/tcp on 127.0.0.1
Changing ping technique for 127.0.0.1 to tcp to port 80; flags: S
Discovered closed port 587/tcp on 127.0.0.1
Changing ping technique for 127.0.0.1 to tcp to port 587; flags: S
Discovered open port 22/tcp on 127.0.0.1
Discovered open port 443/tcp on 127.0.0.1
Discovered closed port 465/tcp on 127.0.0.1
Changing global ping host to 127.0.0.1.
Completed SYN Stealth Scan at 00:00, 0.02s elapsed (5 total ports)
Overall sending rates: 221.18 packets / s, 9731.93 bytes / s.
Nmap scan report for localhost (127.0.0.1)
Host is up, received localhost-response (0.000075s latency).
Scanned at 2024-02-05 00:00:57 UTC for 0s

PORT    STATE  SERVICE    REASON
22/tcp  open   ssh        syn-ack ttl 64
80/tcp  open   http       syn-ack ttl 64
443/tcp open   https      syn-ack ttl 64
465/tcp closed smtps      reset ttl 64
587/tcp closed submission reset ttl 64
Final times for host: srtt: 75 rttvar: 1633  to: 100000

Read from /usr/bin/../share/nmap: nmap-payloads nmap-services.
Nmap done: 1 IP address (1 host up) scanned in 0.13 seconds
           Raw packets sent: 5 (220B) | Rcvd: 13 (552B)

bingo… 465 and 587 closed.

Now, how to open? :sweat_smile:

No, they don’t have to be open. You need them open on the provider side.

But are we scanning local ports, aren’t that?

How can it be provider side if email is working properly out of Nextcloud?