I see a lot of people here uses some form of remote access tool (VPN/Tailscale) to access their home network when not at home. I can’t really do this because my phone (iOS) can only activate one VPN profile at a time, and I often need this for other stuff.

So I chose to expose most web based services on the public internet, behind Authelia. But I don’t know how safe this is.

What I’m really unsure are things like Vaultwarden: while the web interface is protected by Authelia (even use 2FA), its API address needs to be bypassed for direct access, otherwise the mobile APP won’t work. It feels like this is negative everything I’ve done so far.

13 points

It all just depends on how much you trust the app, and how you’ve set up things when it does go wrong. Not every container needs to be able to access other containers on the system, lan, have access to whatever folder, read/write permissions, etc

A good practice for things like vaultwarden would be to only whitelist the country/state you’re in to minimize your attack profile

fail2ban or crowdsec can also help with all the rats sniffing around

permalink
report
reply
3 points

Limited container access is a good point. Noted.

I think the APP itself is fine, but would an API access give attackers a mean to brute force into it? Sorry no expert here.

The official wiki talks about securing password login with fail2ban. I guess this is not needed in my case, as it’s handled at the Authelia level.

permalink
report
parent
reply
51 points
*
Deleted by creator
permalink
report
reply
10 points
*

I have my nextcloud server exposed, I keep it up to date, patched, etc. but I’d love to use the extra protection of a VPN. Just … I don’t think mobile apps work very well with that, unless I keep my phone constantly connected to the VPN, right? Or is there a smart way to do that?

permalink
report
parent
reply
9 points
*

I believe you can configure your phone to only route traffic to your server though the VPN.

permalink
report
parent
reply
3 points

Nice! … how exactly, I wanna know :)

permalink
report
parent
reply
4 points

Yea that’s basically the reason why I can’t use a VPN.

In fact there isn’t really a problem to leave your phone connected to the selfhosted VPN all the time. If split tunneling works properly, only traffic that access your home network would actually go through the VPN, all others will just get bypassed.

But in my case, I already need to be connected to another VPN most of my day, so can’t really go this route.

permalink
report
parent
reply
1 point

Is the existing one wireguard? Because on android you can use the same interface and add another peer. You’d also have to use the same ip range and key on your VPN.

permalink
report
parent
reply
6 points

this thread mentions an OVPN client that can do split tunneling so all you’d do is whitelist your server in the android phone and turn it on.

ProtonVPN has tunneling too, for instance, but no self hosting option.

permalink
report
parent
reply
1 point

Not sure of your setup but I use OpenVPN on my Android and have set it to whitelist apps so only the apps that need to use the VPN do so. You can also go the opposite and blacklist so all apps except those you specify use the VPN.

permalink
report
parent
reply
12 points

It’s only bad practice if you don’t keep up on vulnerabilities/patching, don’t have any type of monitoring or ability to detect a potential breach, etc.

The nice thing about tucking everything behind a VPN is you only have one attack surface to really worry about.

permalink
report
reply
12 points
*
Deleted by creator
permalink
report
reply
10 points

Well I’m trying to discuss when unable to use a VPN so….

permalink
report
parent
reply
3 points

Does a vpn endpoint redirect a user to a reverse proxy or something? I’ve considered running an authenticated onion service to access some less resource intensive services (gitea, etc)

permalink
report
parent
reply
15 points

I use a reverse proxy and client certificate authentication for anything I expose. That requires me to pre install the client certificate on all of my devices first, but afterwards they can connect freely via a web browser with no further prompting to authenticate. Anybody without the client certificate gets a 403 before they even get past the proxy.

There are limitations to this and overhead of managing a CA and the client certificates for your devices.

permalink
report
reply

Selfhosted

!selfhosted@lemmy.world

Create post

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!

Community stats

  • 3.5K

    Monthly active users

  • 3.4K

    Posts

  • 77K

    Comments