32
submitted 11 months ago* (last edited 11 months ago) by memmi@lemm.ee to c/selfhosted@lemmy.world

Hey everyone,

I'm looking for some insights to confirm if my home server's security is up to par against common cyber threats. Here's a brief rundown of my setup:

  1. External Ports: I've limited external access to only three ports:

    • Port 80 and 443 for Nginx-Proxy-Manager
    • Port 51829 for Wireguard VPN
  2. Hardware:

    • I'm running a Raspberry Pi 4 and a Mini PC.
    • Both are connected to the router via Ethernet.
  3. Network:

    • NPM is set up for reverse proxy.
    • SSL is enabled for local DNS - to avoid memorizing IP addresses.
  4. Docker:

    • All applications are containerized and use network_mode: bridge.
  5. Internet-Facing Services:

    • Only two services are exposed to the internet:
      • A media server
      • The Wireguard VPN
    • I'm using free DuckDNS domains, configured with NPM.
  6. Firewall:

    • Currently, I'm relying on the default settings of Debian 12 and the Docker engine.
    • I haven't set up any specific firewall rules.

Given this setup, do you think my security measures are sufficient? I'm particularly curious about the risks associated with my Docker containers and the exposed ports. Any recommendations or best practices you could share would be greatly appreciated!

Thanks in advance for your help!

top 10 comments
sorted by: hot top controversial new old
[-] bookworm@feddit.de 13 points 11 months ago

Put your external facing services behind the VPN, or at least put them in a separate VLAN that's firewalled in such a way that they can't reach the rest of the network if they become compromised.

[-] memmi@lemm.ee 8 points 11 months ago

Can you give me some pointers on how to get started on accomplishing this? Maybe some app names or tutorials?

[-] BaroqueInMind@kbin.social 0 points 11 months ago
[-] tlf@feddit.de 10 points 11 months ago

Setup automatic security updates with unattended-upgrades. I don't know alot about your security expect for the fact that outdated applications are more vulnerable.

[-] poVoq@slrpnk.net 8 points 11 months ago

Fail2ban is useful to set up.

[-] geekworking@lemmy.world 6 points 11 months ago

Seems like your edge server is acting as a proxy for a media server on some other host on your LAN.

You want to make sure that the media server software is setup securely, patched, and properly isolated from anything else in LAN should that become compromised. Proxy closes off a lot of attack vectors but not application vulnerabilities. The Lastpass hack happened because of some vulnerability in an employees home plex server.

[-] MigratingtoLemmy@lemmy.world 3 points 11 months ago

Exposed parts can be messy if you're not used to them.

Easiest option would be to have a VPS set up as a VPN server with the ports you need forwarded to it, and your applications connecting to it. If you don't want the extra maintenance, Cloudflare tunnels for you. Racknerd boxes are $1/month.

Docker containers run as root by default. Either change the flag or switch to podman if you don't need root access for your containers.

Time to get a router compatible with OpenWRT/OPNsense.

There probably are better ways, but I'm totoo at the moment to recollect.

[-] Decronym@lemmy.decronym.xyz 2 points 11 months ago

Acronyms, initialisms, abbreviations, contractions, and other phrases which expand to something larger, that I've seen in this thread:

Fewer Letters More Letters
HTTP Hypertext Transfer Protocol, the Web
VPN Virtual Private Network
VPS Virtual Private Server (opposed to shared hosting)
nginx Popular HTTP server

[Thread #316 for this sub, first seen 30th Nov 2023, 20:35] [FAQ] [Full list] [Contact] [Source code]

[-] Gooey0210@sh.itjust.works 1 points 11 months ago

Just in case, if you have jellyfin facing the web, jellyfin is not very secure, it has some vunurabilities unpatched for like forever I personally would recommend hiding it behind the VPN, and making it available to everyone at home Or as minimum or a good practice create locations in nginx to block for example logins outside of the VPN or house So to login you need to be at home.or connected to the VPN (useful if you have other people using your services, so they they they can login at home, but continue using everything outside)

[-] Guadin@k.fe.derate.me 1 points 11 months ago

What does the NGINX proxy manager do? Is that to access the mediaserver?

this post was submitted on 29 Nov 2023
32 points (92.1% liked)

Selfhosted

39677 readers
814 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS