this post was submitted on 16 Mar 2024
93 points (97.0% liked)

Selfhosted

39905 readers
291 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
 

What's everyones recommendations for a self-hosted authentication system?

My requirements are basically something lightweight that can handle logins for both regular users and google. I only have 4-5 total users.

So far, I've looked at and tested:

  • Authentik - Seems okay, but also really slow for some reason. I'm also not a fan of the username on one page, password on the next screen flow
  • Keycloak - Looks like it might be lighter in resources these days, but definitely complicated to use
  • LLDAP - I'd be happy to use it for the ldap backend, but it doesn't solve the whole problem
  • Authelia - No web ui, which is fine, but also doesn't support social logins as far as I can tell. I think it would be my choice if it did support oidc
  • Zitadel - Sounds promising, but I spent a couple hours troubleshooting it just to get it working. I might go back to it, but I've had the most trouble with it so far and can't even compare the actual config yet
top 50 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 1 month ago

I use nforwardauth . It is simple, but only supports username/password

https://github.com/nosduco/nforwardauth

[–] [email protected] 0 points 7 months ago

Been happy with Zitadel so far.

I usually worry about getting bit later with apps that depend on a relational database.

This is my first cockroach db app and it's not nearly as obtuse as the MySQL container image. Hopefully it continues to work smoothly.

[–] [email protected] 5 points 7 months ago (1 children)

I've been using Authelia for almost 2 years and I really like it. Never had any issues.

[–] [email protected] 2 points 7 months ago

The latest update to authelia 4.38 was a little bit cumbersome, because you hat to manually adjust the configuration. But all in all I like authelia, too.

[–] [email protected] 4 points 7 months ago (1 children)

Why not keep everything in your LAN and setup a wire guard bastion ?

[–] [email protected] 3 points 7 months ago

That's essentially what I am doing. Everything is on the LAN by default. I have two instances of Traefik. One that runs only on internal VPN ips, and another on remote servers using public ips. So I can choose which services are accessible over lan/vpn or public (routed through a vpn to lan).

That doesn't solve the authentication problem if I want to expose something to the internet though, or even sso inside the lan.

[–] [email protected] 1 points 7 months ago

I use oauth2proxy+nginx ingress gateway where needed (apps that don't support OIDC themselves), with dex their OIDC provider, and github is dex's upstream IDP+OIDC.

[–] [email protected] 7 points 7 months ago* (last edited 7 months ago) (2 children)

Authentik works very well and has the most flexibility if you have the resources to run it (not an rpi)

You can change the logon flow to make the username and password on the same page

Another user mention issues with password managers auto filling. There is a comparability button as well on the login flow that allows bitwarden and other to auto fill correctly.

Authentik has LDAP built in along with every SSO method that exists. Makes it super nice to integrate into as many services as possible.

I use it with oAuth, LDAP and reverse proxy authentication.

[–] [email protected] 1 points 7 months ago
[–] [email protected] 1 points 7 months ago (2 children)

You can change the logon flow to make the username and password on the same page There is a comparability button as well on the login flow that allows bitwarden and other to auto fill correctly.

Thanks for the tips, I found the compatibility button and will try it out. I'm not sure I see how to change the username/password to be on the same page though. Do you have to create a whole new login flow?

[–] [email protected] 5 points 7 months ago (2 children)

https://www.youtube.com/@cooptonian His Authentik videos are top notch and they (Authentik) have also had him make some for them. One of those videos, I can't recall shows you how to do this, I think it may be the 2FA/MFA one. I use Authentik and can login with fingerprint login without using my UN/PW first. It's pretty slick.

[–] [email protected] 1 points 7 months ago

Thanks for the recommendation, I'll take a look at some of his videos. I managed to get the un/pw on one page, but haven't done much with webauthn/passwordless stuff yet so that might be useful too.

[–] [email protected] 2 points 7 months ago

Here is an alternative Piped link(s):

https://www.piped.video/@cooptonian

Piped is a privacy-respecting open-source alternative frontend to YouTube.

I'm open-source; check me out at GitHub.

[–] [email protected] 2 points 7 months ago* (last edited 7 months ago) (1 children)

I think I saw a tutorial on YouTube for how to do it but this page describes it as well. I edited the default login flow to include the password box

https://docs.goauthentik.io/docs/flow/stages/identification/

[–] [email protected] 2 points 7 months ago

Thanks! I managed to get user/pass on the same page and it works great with the compatibility mode

[–] [email protected] 3 points 7 months ago (1 children)

Authelia does support oidc and its amazing.

[–] [email protected] 2 points 7 months ago

Authelia is a oidc provider, but does not support oidc as a provider, only local file and ldap. So it really depends on your use case

[–] [email protected] 3 points 7 months ago (1 children)
  • Authentik is pretty resource intensive. Needs something like 3 servers/instances. A database, a server and a worker. Uses something like 800+ MB ram just for this service. Since I run my services on raspberry Pi 3s, I ended up moving away from this
  • Keycloak works great but is a bit difficult to set up and doesn’t support all the authentication protocols that Authentik does
[–] [email protected] 2 points 7 months ago (1 children)

Did you move to Keycloak, or something else?

[–] [email protected] 5 points 7 months ago

Honestly I just moved back to local accounts. I’m interested in the other comments on this post for a good solution to move to.

load more comments
view more: next ›