mirror of
https://github.com/empayre/fleet.git
synced 2024-11-06 08:55:24 +00:00
Fleet CTL: Surface password requirements to console for FleetCTL use, update API only password example (#14171)
This commit is contained in:
parent
0f4e24a40a
commit
86daf97425
@ -202,7 +202,7 @@ An API-only user does not have access to the Fleet UI. Instead, it's only purpos
|
||||
To create your new API-only user, run `fleetctl user create` and pass values for `--name`, `--email`, and `--password`, and include the `--api-only` flag:
|
||||
|
||||
```sh
|
||||
fleetctl user create --name "API User" --email api@example.com --password temp!pass --api-only
|
||||
fleetctl user create --name "API User" --email api@example.com --password temp@pass123 --api-only
|
||||
```
|
||||
|
||||
### Creating an API-only user
|
||||
|
@ -353,7 +353,7 @@ func ValidatePasswordRequirements(password string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
return errors.New("Password does not meet required criteria")
|
||||
return errors.New("Password does not meet required criteria: Must include 12 characters, at least 1 number (e.g. 0 - 9), and at least 1 symbol (e.g. &*#).")
|
||||
}
|
||||
|
||||
// ValidateEmail checks that the provided email address is valid, this function
|
||||
|
@ -863,7 +863,7 @@ func (svc *Service) PerformRequiredPasswordReset(ctx context.Context, password s
|
||||
}
|
||||
|
||||
if err := fleet.ValidatePasswordRequirements(password); err != nil {
|
||||
return nil, fleet.NewInvalidArgumentError("new_password", "Password does not meet required criteria")
|
||||
return nil, fleet.NewInvalidArgumentError("new_password", "Password does not meet required criteria: Must include 12 characters, at least 1 number (e.g. 0 - 9), and at least 1 symbol (e.g. &*#).")
|
||||
}
|
||||
|
||||
user.AdminForcedPasswordReset = false
|
||||
|
Loading…
Reference in New Issue
Block a user