-
Notifications
You must be signed in to change notification settings - Fork 97
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #38124 - Invalidate tokens for specific user/users (#636)
- Loading branch information
1 parent
fd288fe
commit fcea924
Showing
2 changed files
with
29 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
module HammerCLIForeman | ||
class RegistrationTokens < HammerCLIForeman::Command | ||
resource :registration_tokens | ||
command_name 'registration-tokens' | ||
desc _('Manage registration tokens') | ||
|
||
class InvalidateMultipleCommand < HammerCLIForeman::DeleteCommand | ||
action :invalidate_jwt_tokens | ||
command_name 'invalidate-multiple' | ||
success_message _('Successfully invalidated registration tokens for %{users}.') | ||
failure_message _('Could not invalidate registration tokens') | ||
|
||
build_options | ||
end | ||
|
||
class InvalidateCommand < HammerCLIForeman::DeleteCommand | ||
action :invalidate_jwt | ||
command_name 'invalidate' | ||
success_message _('Successfully invalidated registration tokens for %{user}.') | ||
failure_message _('Could not invalidate registration tokens') | ||
|
||
build_options | ||
end | ||
|
||
autoload_subcommands | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters