mirror of
https://github.com/lukaszraczylo/traefikoidc.git
synced 2026-10-18 04:47:28 +00:00
0.7.10 (#80)
* Add ability to disable replay protection. - This is useful for runs with multiple traefik replicas to avoid false positives and tokens re-creation. * Enhance the CI/CD pipelines * Increase test coverage. * Update vendored dependencies. * Update behaviour on forceHTTPS as per issue #82
This commit is contained in:
@@ -171,6 +171,7 @@ func NewWithContext(ctx context.Context, config *Config, next http.Handler, name
|
||||
strictAudienceValidation: config.StrictAudienceValidation,
|
||||
allowOpaqueTokens: config.AllowOpaqueTokens,
|
||||
requireTokenIntrospection: config.RequireTokenIntrospection,
|
||||
disableReplayDetection: config.DisableReplayDetection,
|
||||
scopes: func() []string {
|
||||
userProvidedScopes := deduplicateScopes(config.Scopes)
|
||||
|
||||
@@ -213,7 +214,7 @@ func NewWithContext(ctx context.Context, config *Config, next http.Handler, name
|
||||
t.logger.Debugf("No custom audience specified, using clientID as audience: %s", t.clientID)
|
||||
}
|
||||
|
||||
t.sessionManager, _ = NewSessionManager(config.SessionEncryptionKey, config.ForceHTTPS, config.CookieDomain, t.logger)
|
||||
t.sessionManager, _ = NewSessionManager(config.SessionEncryptionKey, config.ForceHTTPS, config.CookieDomain, t.logger) // Safe to ignore: session manager creation with fallback to defaults
|
||||
t.errorRecoveryManager = NewErrorRecoveryManager(t.logger)
|
||||
|
||||
// Initialize token resilience manager with default configuration
|
||||
@@ -303,11 +304,11 @@ func NewWithContext(ctx context.Context, config *Config, next http.Handler, name
|
||||
t.initializeMetadata(config.ProviderURL)
|
||||
}()
|
||||
|
||||
// Setup cleanup hook for when context is cancelled
|
||||
// Setup cleanup hook for when context is canceled
|
||||
if pluginCtx != nil {
|
||||
go func() {
|
||||
<-pluginCtx.Done()
|
||||
t.Close()
|
||||
_ = t.Close() // Safe to ignore: cleanup on context cancellation
|
||||
}()
|
||||
}
|
||||
|
||||
@@ -424,7 +425,7 @@ func (t *TraefikOidc) startMetadataRefresh(providerURL string) {
|
||||
|
||||
// Start the task if not already running
|
||||
if !rm.IsTaskRunning(taskName) {
|
||||
rm.StartBackgroundTask(taskName)
|
||||
_ = rm.StartBackgroundTask(taskName) // Safe to ignore: task registration succeeded, start is best-effort
|
||||
t.logger.Debug("Started singleton metadata refresh task")
|
||||
} else {
|
||||
t.logger.Debug("Metadata refresh task already running, skipping duplicate")
|
||||
|
||||
Reference in New Issue
Block a user