mirror of
https://github.com/netbirdio/netbird.git
synced 2026-03-31 06:34:14 -04:00
[client] Remove duplicate audiences check (#5117)
This commit is contained in:
@@ -440,12 +440,8 @@ func (s *Server) ensureJWTValidator() error {
|
||||
)
|
||||
|
||||
// Use custom userIDClaim from authorizer if available
|
||||
audience := ""
|
||||
if len(config.Audiences) != 0 {
|
||||
audience = config.Audiences[0]
|
||||
}
|
||||
extractorOptions := []jwt.ClaimsExtractorOption{
|
||||
jwt.WithAudience(audience),
|
||||
jwt.WithAudience(config.Audiences[0]),
|
||||
}
|
||||
if authorizer.GetUserIDClaim() != "" {
|
||||
extractorOptions = append(extractorOptions, jwt.WithUserIDClaim(authorizer.GetUserIDClaim()))
|
||||
|
||||
Reference in New Issue
Block a user