Skip to content

Commit

Permalink
admin: Require identity for remote (fix #4478)
Browse files Browse the repository at this point in the history
  • Loading branch information
mholt committed Jan 6, 2022
1 parent 6cadb60 commit b4bfa29
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions admin.go
Original file line number Diff line number Diff line change
Expand Up @@ -466,6 +466,9 @@ func replaceRemoteAdminServer(ctx Context, cfg *Config) error {
}

// create TLS config that will enforce mutual authentication
if identityCertCache == nil {
return fmt.Errorf("cannot enable remote admin without a certificate cache; configure identity management to initialize a certificate cache")
}
cmCfg := cfg.Admin.Identity.certmagicConfig(remoteLogger, false)
tlsConfig := cmCfg.TLSConfig()
tlsConfig.NextProtos = nil // this server does not solve ACME challenges
Expand Down

0 comments on commit b4bfa29

Please sign in to comment.