opnsense / plugins

OPNsense plugin collection
https://opnsense.org/
BSD 2-Clause "Simplified" License
849 stars 644 forks source link

Can we include Keycloak as Auth in the Caddy Plugin? #4303

Open UNRA1DUser opened 1 month ago

UNRA1DUser commented 1 month ago

Important notices Before you add a new report, we ask you kindly to acknowledge the following:

Is your feature request related to a problem? Please describe. No

Describe the solution you'd like Can we include Keycloak as Auth in the Caddy Plugin?

Describe alternatives you've considered

Additional context

Monviech commented 1 month ago

Somebody has to contribute that just like here:

https://github.com/opnsense/plugins/pull/4104

Its probably easier to set up Authelia and use that with caddy.

UNRA1DUser commented 1 month ago

Or maybe is it possible to add "oauth2-proxy" to it? So a lot of other Auth. could be configured than.

Monviech commented 1 month ago

Do you mean this?

https://github.com/oauth2-proxy/oauth2-proxy/issues/2485#issuecomment-1931230207

Please provide more information I don't wanne google things here. If you want something you have to be a bit more verbose in your request, please.

It doesnt look like there's much documentation or anything. So I rather not add it without having something available like this:

https://caddyserver.com/docs/caddyfile/directives/forward_auth#authelia

Why not use authelia as your intermediate and let it authenticate to your keycloak server?

UNRA1DUser commented 1 month ago

Yes, I meant that one. Sorry for not providing so much information.

Oh is that also working with authelia? I didn't know that. So I could use authelia or authentik to authenticate with keycloak?

Sounds interesting. I will google it.

Monviech commented 1 month ago

You can probably do something like OIDC but its not my expertise.

Both Keycloak and Authelia should support OIDC, so one could be the client of the other.