VAULT-ASSOCIATE-002 · Question #52
Which endpoint can be used to list all tokens?
The correct answer is D. /auth/token/accessors. The Vault API endpoint /auth/token/accessors is used to list all token accessors, which allows for managing tokens without exposing their full sensitive values.
Question
Options
- A/kv/secrets
- B/auth/token/list
- C/secrets/kv
- D/auth/token/accessors
How the community answered
(37 responses)- A3% (1)
- C5% (2)
- D92% (34)
Why each option
The Vault API endpoint `/auth/token/accessors` is used to list all token accessors, which allows for managing tokens without exposing their full sensitive values.
`/kv/secrets` is a path typically associated with the Key-Value secrets engine for storing and retrieving secrets, not managing tokens.
`/auth/token/list` is not a standard or valid endpoint in Vault for listing all tokens; Vault uses accessors for listing and managing tokens safely.
`/secrets/kv` is another common path for the Key-Value secrets engine, similar to option A, and is unrelated to token management.
The `/auth/token/accessors` endpoint is specifically designed in Vault to list all known token accessors, which are used to represent tokens in a way that allows revocation and management without requiring the token's sensitive value. This endpoint helps in administrative tasks like auditing or bulk revocation of tokens.
Concept tested: Vault token accessor endpoint
Source: https://developer.hashicorp.com/vault/api-docs/system/auth/token#list-token-accessors
Topics
Community Discussion
No community discussion yet for this question.