mondoo_client_generate-token
mondoo client generate-token
Generates a registration token to register new clients for your space
Synopsis
Generates a registration token that you can use to register your client with Mondoo Platform. A registration token allows a new client to sign up with your Mondoo space. The new client will exchange the registration token with a private key for further communication.
The registration token is short lived and is valid for 60 seconds. The expired time can be extended if required. If a registration token expires then you can’t register more clients with Mondoo Platform by using that specific token. You simply create a new one.
NOTE: By default, clients do not have the permission to generate tokens for new clients. Elevate permissions to Gateway Agent under the SETTINGS/SERVICE ACCOUNTS page in Mondoo Platform.
Generates a new registration token that is valid for 60 seconds:
$ mondoo client generate-token
Generates a new registration token that is valid for 120 seconds:
$ mondoo client generate-token --expiresin 120
Pipe the token into a file:
$ mondoo client generate-token --expiresin 120 > registrationtoken.txt
mondoo client generate-token [flags]
Options
--description string optional description for the token
--expiresin int duration in seconds that the registration token is valid (default 60)
-h, --help help for generate-token
--label stringToString label for registration token and service account (default [])
--no-expiration flag to indicate that the token should not expire
Options inherited from parent commands
--config string config file (default is $HOME/.config/mondoo/mondoo.yml)
--log-level string set log-level: error, warn, info, debug, trace (default "info")
-v, --verbose verbose output
SEE ALSO
- mondoo client - Subcommand for managing service accounts