nauta.cu MX servers don't support STARTTLS
and we have maintained this exception to allow delivery to nauta.cu.
Since nauta.cu has blocked largest chatmail relay instances,
we can remove this exception.
Even if it works today for some chatmail servers,
they will likely be blocked once the number of users grows.
Even now users from nauta.cu cannot practically participate
in groups.
We already require that outgoing connections
use STARTTLS so other servers need a valid TLS
certificate to accept messages from us.
It is then very unlikely that they cannot use TLS
to send messages to us.
Conversely, if they only can send messages to use without TLS,
it likely does not have STARTLS on its port 25
and then we don't want to accept messages from them
because we will likely not be able to reply.
- This is a counterpart to pull request #607. Revised
test_deployed_state() to perform the same error-handling on Git
commands that cmdeploy does. If 'git rev-parse' returns an error,
the value "unknown" is used. If 'git diff' returns an error, the
null string is used.
- This fixes failures in environments where Git is not installed or
where the .git subdirectory is not present (as long as the server
was deployed in the same way).
- test_rewrite_subject() is prone to failure when it checks for the
delivered message, because fetch_all_messages() raises "ValueError:
no messages in imap folder". The check has the potential to happen
before the server has had a chance to deliver the message to the
user's inbox.
- Added a function try_n_times() that attempts to call a function the
specified number of times, with a 1-second sleep between calls. The
call is retried until it doesn't raise an exception. The last call
is made without a 'try' block, so that the final exception passes
through to the caller if it does not return.
- Wrapped call to fetch_all_messages() in try_n_times(), with 5
attempts specified. This should usually allow enough time for the
message to get moved from the postfix queue to the user's inbox.
- test_timezone_env() is producing the warning,
"PytestReturnNotNoneWarning: Test functions should return None, but
src/cmdeploy/tests/online/test_1_basic.py::test_timezone_env
returned <class 'bool'>".
- Revised test_timezone_env() to return None for success instead of
True.
- On a fresh install, if cmdeploy is run the first time with the
--disable-mail option, the echobot invite-link.txt file will not
exist yet.
- Only print the echobot invite link if --disable-mail was not
specified. This fixes the fresh-install error case, and also makes
sense when disabling mail in general, because the echo bot will not
be available at that time.
Stalwart sends `NOTIFY=DELAY,FAILURE`
to request Delivery Status Notifications.
aiosmtpd does not support any parameters,
not just ORCPT, so we have to ignore all of them.
- username_min_length and username_max_length are both set to a
default value of 9 in the chatmail.ini.f template. When they have
the same value, it doesn't matter which one we use in newemail.py
(which handles the /new URL). However, if they are configured to
different values by the admin, then the current implementation using
username_min_length chooses from a smaller set of possible
usernames.
- Revised create_newemail_dict() in newemail.py to use
username_max_length as the length of the random username it offers
via the /new URL. This randomizes within a much larger set of
possible usernames.