Skip to content

protect small servers by rejecting new addresses under resource constraints / capping smtp/imap connection limits - #1019

Merged
hpk42 merged 1 commit into
mainfrom
autolimit_address_creation
Jul 28, 2026
Merged

protect small servers by rejecting new addresses under resource constraints / capping smtp/imap connection limits#1019
hpk42 merged 1 commit into
mainfrom
autolimit_address_creation

Conversation

@hpk42

@hpk42 hpk42 commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Mainly, this PR rejects new address creation when system is under load, has not much RAM or disk storage left.

It also makes postfix/dovecot max connection limit available in chatmail.ini and lowers the defaults which were geared for nine.testrun.org operations.

@missytake missytake left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for pushing this! Let's ask operators which limits they deem sufficient.

Comment thread chatmaild/src/chatmaild/doveauth.py Outdated
Comment thread chatmaild/src/chatmaild/ini/chatmail.ini.f Outdated
Comment thread chatmaild/src/chatmaild/doveauth.py Outdated

@j4n j4n left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, can't speak to the validity of the default limits; two robustness changes suggested.

Comment thread chatmaild/src/chatmaild/ini/chatmail.ini.f
Comment thread chatmaild/src/chatmaild/tests/test_doveauth.py Outdated
Comment thread chatmaild/src/chatmaild/doveauth.py Outdated
Comment thread chatmaild/src/chatmaild/newemail.py Outdated
@hpk42
hpk42 force-pushed the autolimit_address_creation branch from aafe6db to 6d51bc1 Compare July 27, 2026 14:59
@hpk42
hpk42 force-pushed the autolimit_address_creation branch from 6d51bc1 to 3be89d2 Compare July 27, 2026 15:40
@hpk42
hpk42 temporarily deployed to staging.chatmail.at/doc/relay/ July 27, 2026 15:40 — with GitHub Actions Inactive

@j4n j4n left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks great to me!

@hpk42
hpk42 force-pushed the autolimit_address_creation branch from 3be89d2 to 78704bc Compare July 27, 2026 15:55
@hpk42
hpk42 temporarily deployed to staging.chatmail.at/doc/relay/ July 27, 2026 15:55 — with GitHub Actions Inactive
…ation and limit imap/smtp connections.

The default values are geared towards minimal-requirements server.
If you have a big server, you will need to set chatmail.ini parameters.
@hpk42
hpk42 force-pushed the autolimit_address_creation branch from 78704bc to 0b22d9d Compare July 27, 2026 23:55
@hpk42
hpk42 merged commit fa5afad into main Jul 28, 2026
9 checks passed
@hpk42
hpk42 deleted the autolimit_address_creation branch July 28, 2026 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants