Repository navigation
Conversation
Several optional services are only meant to be used inside the local network, but their ufw rules allowed any source address. These helpers let scripts restrict such rules to private address ranges. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
Port 3389 was allowed from any source, exposing the xrdp login to the internet whenever the port is reachable. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
The wg-easy admin interface is documented as local-network only, but neither Apache nor ufw restricted the source address. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
Port 53 was published on all interfaces. Docker publishes ports in the nat table before ufw, so it could not be restricted and Pi-hole could end up as an open resolver usable for amplification attacks. Publish it only on the server's private address and refuse to install otherwise. The admin web interface is also limited to private networks now. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
Until the admin user is created, anyone reaching the public vhost could complete the startup wizard and take over the server. The LAN-only ports (unencrypted http, https, discovery) are restricted to private networks as well. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
Samba was allowed from any source, which exposes file shares to the internet whenever the ports are reachable. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
Webmin, AdminNeo, Netdata, RDP, Samba and the Pi-hole, WireGuard and Jellyfin LAN ports were allowed from any source, and all UDP ports were open for 192.168.0.0/16 although only UPnP (1900/udp) needs it. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
Binding port 53 to the server's address breaks DNS for the whole network as soon as that address changes. Pi-hole is only meant for trusted home networks where the router doesn't forward port 53, so not restricting it is acceptable. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
Member
|
Not approving this yet. The restrictions work, but two things need to change:
Tested on a fresh Nextcloud 35.0.3 on Ubuntu 26.04, from a public and a LAN client. Everything else works:
|
netdata.sh tells users to open port 19999 to reach Netdata from their domain, which a private-only rule would block. Also drop the pi-hole.sh comment changes left over from the reverted port 53 binding. Assisted-by: Claude Code:claude-opus-5-5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Simon L. <szaimen@e.mail.de>
Collaborator
Author
Should be addressed now 👍 |
Collaborator
Author
|
@enoch85 can you please have another look? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Several optional services are only meant to be used inside the local
network, but their ufw rules allowed any source address.
🤖 AI (if applicable)