For the complete documentation index, see llms.txt. Markdown versions of documentation pages are available by appending .md to page URLs.
Skip to content

vhsm token

Learn about managing authentication tokens in vHSM server.

The vhsm token command manages authentication tokens in vHSM. Users can create, lookup, renew, and revoke tokens.

Usage

vhsm token <subcommand> [options] [arguments]

Subcommands

Command
Description

Print the capabilities of a token for a given path.

Create a new authentication token.

Retrieve information about a token.

Extend the lease of a token.

Revoke a token and its children.

token capabilities

Fetches the capabilities of a token for a specified path.

Example

List capabilities for the current token on the secret/foo path:

vhsm token capabilities secret/foo

Output

read

List capabilities for a specific token on the database/creds/readonly path:

Output

token create

Creates a new authentication token. This token will inherit policies from the currently authenticated token unless explicitly specified.

Examples

Create a token with specific policies:

Create a periodic token:

Options

Option
Description

-policy

Attach a policy to the token. Multiple policies can be added.

-ttl

Set an initial TTL for the token.

-renewable

Allow token renewal (default: true).

-explicit-max-ttl

Set a hard maximum lifetime for the token.

token lookup

Retrieves information about a token. If no token is provided, the currently authenticated token is used.

Examples

Get information about the current token:

Get information about a specific token:

Get information via a token's accessor:

token renew

Extends the lease of a token. If no token is provided, the currently authenticated token is used.

Examples

Renew a specific token:

Renew the currently authenticated token:

Renew a token with a specific increment:

Options

Option

Description

-increment

Request a specific renewal increment.

token revoke

Revokes authentication tokens and their children.

Examples

Revoke a specific token and its children:

Revoke a token but leave its children:

Revoke a token using an accessor:

Options

Option
Description

-accessor

Treat argument as an accessor instead of a token.

-mode

Specify revocation mode (orphan to leave children intact).

Last updated