-
-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a Module - goes wrong #49
Comments
How to fix your Caddyfile:
Revised Caddyfile (Example): home.mydomain.de {
import common-settings
handle {
authentication portal myportal {
crypto default token lifetime 3600
enable identity provider generic
cookie insecure off
transform user {
match realm generic
action add role user
}
oauth identity provider generic {
delay_start 3
realm generic
driver generic
client_id HEREISTHEIDFROMPOCKETID
client_secret HEREISTHESECRETFROMPOCKETID
scopes openid email profile
base_auth_url https://pi.MYDOMAIN.de
metadata_url https://pi.MYDOMAIN.de/.well-known/openid-configuration
}
}
authorize with mypolicy
reverse_proxy 192.168.XXX.XXX:3000
# Make sure that you set the following security header in the outer scope of the site block.
header {
Strict-Transport-Security "max-age=31536000; includeSubDomains; preload"
X-Content-Type-Options "nosniff"
X-Frame-Options "DENY"
Referrer-Policy "strict-origin-when-cross-origin"
}
}
authorization policy mypolicy {
set auth url /auth/oauth2/generic
allow roles user
inject headers with claims
}
log {
output file /var/log/caddy/home.access.log
format json
}
} Explanation of Changes:
let me know if this works for you ☕ |
Nope, doesn't work yet. I guess it's a problem to import the caddy-security modul. EDIT:
Sorry, I'm not that good with caddy. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello there,
I got issues to add another Module to the caddy-file.
Error: cannot auto-upgrade when Go module has been replaced: github.com/fabriziosalmi/caddy-waf => /opt/caddy-waf
I guess caddy-waf work but I try to install caddy-Security. It seems that the plugin is okay, but it doesn’t work probably. See better explained here:
https://www.reddit.com/r/caddyserver/comments/1ied7qp/help_with_securitymodul/
Thanks for helping
Daniel
The text was updated successfully, but these errors were encountered: