Skip to content

Commit

Permalink
Let allowed_users template mix templated and non-templated parts (#10388
Browse files Browse the repository at this point in the history
)
  • Loading branch information
phihos committed Feb 10, 2021
1 parent e7868e7 commit e9c8622
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion builtin/logical/ssh/path_sign.go
Expand Up @@ -221,7 +221,7 @@ func (b *backend) calculateValidPrincipals(data *framework.FieldData, req *logic
for _, principal := range strutil.RemoveDuplicates(strutil.ParseStringSlice(principalsAllowedByRole, ","), false) {
if role.AllowedUsersTemplate {
// Look for templating markers {{ .* }}
matched, _ := regexp.MatchString(`^{{.+?}}$`, principal)
matched, _ := regexp.MatchString(`{{.+?}}`, principal)
if matched {
if req.EntityID != "" {
// Retrieve principal based on template + entityID from request.
Expand Down

0 comments on commit e9c8622

Please sign in to comment.