(Discussion) Can we auto-detect open relays?
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
- Issue type
- Feature
- Clarity
- Needs clarification
- Activity status
- Stale
- Tech stack
- helm, kubernetes
- Domain
- infrastructure, security
Research direction
No files, tests, or entry points are named. Start by reviewing the Mailu Helm chart and the related open-relay issues mentioned in the discussion. Define how an external probe, observed source IP, internal IP configuration, and an administrative safeguard would work before implementation.
Written by the indexing model from the issue text.
Description
In the mailu helm chart, I found several ways how people create an open relay. Some are just bad setups, others happens completely unexpected (e.g. one user had a broken CNI configuration in kubernetes). Others might come from a change to the environment even when mailu itself is untouched. In the mailu main repository, also some issues exists which discuss open relays.
I think, creating open relays is one of the bigges issues when running an MTA - even bigger than other security issues like outdated software since it affects way more people. So I'm thinking about how we could auto-detect if a running mailu application is an open relay or not.
I have read through many open relay issues. While it's possible to create open relays by bad postfix configuration, the most common situation is that mailu does not see the real IP where mail traffic is coming from so that external traffic is handled like local traffic.
So what is needed for a mailu installation to detect, that it's running as an open relay?
1st, mailu needs to know what internal IPs are. This is the case by default since it's part of the setup.
2nd, mailu would need an incoming request that comes from a known-to-be-external IP address. This could be achieved by an external service.
3rd, the request needs to be recorded and it's source IP as it is seen by the "front" service must be checked.
And finally, some action must be taken when an open relay is detected. This could be a flag in mailu admin that prevents any mail to be received unless an admin verifies and fixes the setup.
What do you think about such a feature?
Kind regards,
Michael.
- Dominant language
- Python
- Stars
- 7.6k
- Forks
- 1k
- Avg merge
- 15h 38m
- Merged PRs (30d)
- 59
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Mailu/Mailu
-
Difficulty 1/5 Under an hour Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
type/feature
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
Mailu/Mailu#3924 · 8 comments ·
Maintainers usually reply within 1 day
-
Dependency DashboardOpen
Difficulty 3/5 Half a day Newbie friendliness 35/100
Maintainers usually reply within 1 day
-
API: /api/v1/alias/me endpoints return 500 for the API-token caller (flask.g.user never set)Possibly taken @maximilize claimed this 125 days ago. Opentype/bug
Difficulty 3/5 1-2 days Newbie friendliness 68/100
Mailu/Mailu#4061 · 3 comments ·
Maintainers usually reply within 1 day
-
type/enhancement
Difficulty 3/5 1-2 days Newbie friendliness 25/100
Mailu/Mailu#4001 · 1 comment ·
Maintainers usually reply within 1 day
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 69/100
daniel-ospina/tortoise#15308 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
Maintainers usually reply within 1 day
-
difficulty:easy prio:low type:bug
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
NatronGitHub/Natron#2405 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Jstar269/nakagawa-recomp#3746 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day