All HashiCorp exams
Free Vault Associate practice test: 30 questions with answers
30 original questions for Vault Associate, drawn from every topic area. Answer each one to see whether you got it right and why. No sign-up.
- Free questions
- 30
- Full bank
- 112 questions
- Real exam
- 60 min
All 30 Vault Associate questions with answers
The same questions as the test above, grouped by exam topic. Open any question to see the answer and explanation.
Vault Concepts and Architecture (8 questions)
Question 1
Why does Vault use a seal mechanism?
- ATo encrypt each secret with a different user's password on every request that Vault receives from clients
- BTo lock the Vault user interface whenever no user is signed in, for display purposes only on the screen
- CTo prevent the storage backend from being backed up by the operations team as part of routine work
- DTo protect the master key that encrypts Vault's data at rest, so the data cannot be read until Vault is unsealed
Show answer and explanationHide answer
Correct answer: DThe seal protects the master key that encrypts data at rest, so storage cannot be read without unsealing. The UI lock, backup prevention and per-user request encryption are not what the seal does.
Question 2
Which storage option gives Vault built-in high availability without an external database?
- AA spreadsheet stored on each node, which the client synchronises by hand after every change
- BA local file on one server, which is shared with the other nodes through a network drive mount
- CAn in-memory cache only, which is lost on every restart of the cluster and is not replicated
- DIntegrated Raft storage, which replicates Vault data across the nodes of the cluster
Show answer and explanationHide answer
Correct answer: DIntegrated Raft storage replicates data across cluster nodes for high availability without an external database. A single file, memory-only storage and spreadsheets do not provide replicated HA.
Question 3
What is the role of the Vault server in a typical deployment?
- AIt replaces the operating system's file system on each host that runs the applications in the company
- BIt only provides a web page with documentation for the users of the company's internal applications
- CIt stores and serves secrets, and enforces access through authentication, policies and audit
- DIt acts as the DNS resolver for every application in the network, answering name lookups for all services
Show answer and explanationHide answer
Correct answer: CThe Vault server stores and serves secrets and enforces authentication, policy and audit. Documentation pages, file systems and DNS are not its role.
Question 4
Which unseal approach removes the need for operators to enter key shares after every restart?
- APrinting the unseal keys on paper and taping them to the server rack where the Vault node is installed
- BDisabling the seal entirely, which leaves the data unprotected at rest in the storage for convenience
- CAuto-unseal with a cloud KMS or HSM, which unseals Vault automatically when it starts
- DRestarting Vault only during business hours so that operators are always present to enter the key shares
Show answer and explanationHide answer
Correct answer: CAuto-unseal with a cloud KMS or HSM unseals Vault automatically on startup. Disabling the seal, taped keys and business-hours restarts are unsafe or do not remove the manual step.
Question 5
What does a dev-mode Vault server provide?
- AA backup copy of the production secrets, kept for disaster recovery purposes in a separate location
- BA fully hardened production cluster with high availability and audit enabled by default for production use
- CA quick, non-production Vault that starts unsealed with an in-memory store, for learning and testing
- DA load balancer for applications, which reads secrets from the nearest node in the cluster on each request
Show answer and explanationHide answer
Correct answer: CDev mode is an unsealed, in-memory, non-production server for learning. It is not hardened, HA or a backup, and it is not a load balancer.
Question 6
Which concept places each secrets engine and auth method at a path that identifies it?
- AMount paths, where each secrets engine or auth method is enabled at a path that identifies it
- BCertificates, which store the public keys of each user's device in the secret store for signing purposes
- CLeases, which define how many users are allowed to sign in to the Vault server at the same time
- DAudit devices, which decide which secrets engine a request is sent to by default when none is named
Show answer and explanationHide answer
Correct answer: AMount paths identify each secrets engine and auth method. Certificates, leases and audit devices serve different purposes.
Question 7
Which TWO statements about Vault's architecture are correct? (Choose two.)
- AVault clients communicate with Vault over its HTTP API, and the CLI and UI are clients of that API
- BVault stores secrets in plaintext on disk, so that backups can be read by any operator in the team
- CEach Vault node holds a different part of every secret, so that no single node can read the secret alone
- DAudit devices write a log of requests and responses, with sensitive values hashed in the log entries
- EVault must be connected to the internet to unseal itself on every restart of the server node
Show answer and explanationHide answer
Correct answer: A, DThe CLI and UI are clients of the HTTP API, and audit devices hash sensitive values. Plaintext storage, per-node secret splitting and internet-based unsealing are incorrect.
Question 8
What is the purpose of a Vault unseal key share threshold?
- AIt sets how many of the key shares are required to reconstruct the root key and unseal Vault
- BIt sets how many users may sign in to the Vault UI at the same time before the next user is refused access
- CIt sets how many secrets Vault may return in a single response before it paginates the results for the client
- DIt sets how many audit devices must be enabled before the cluster is allowed to accept any client requests
Show answer and explanationHide answer
Correct answer: AThe threshold sets how many shares are needed to reconstruct the root key. Sign-in limits, response paging and audit device counts are unrelated.
Policies and Operations (8 questions)
Question 9
Which policy capability allows a token to read a secret at a given path?
- AThe read capability on that path, granted through an HCL policy attached to the token
- BThe sudo capability on the root path, which grants reads on every path in the cluster by default
- CThe list capability on the audit path, which allows the token to read the secret values as they are logged
- DThe deny capability on the secret path, which grants read access when it is applied together with the root policy
Show answer and explanationHide answer
Correct answer: AThe read capability on the path, granted by an attached HCL policy, allows reading. Sudo, list on audit paths and deny do not grant reads in those ways.
Question 10
What does an explicit deny in a Vault policy do?
- AIt overrides any allow granted by another policy attached to the same token for that path
- BIt only logs the attempted access in the audit log and never blocks the request from being processed at all
- CIt deletes the secret at the path after the first denied request, to prevent any further access to it
- DIt applies only to the root token, so ordinary tokens are not affected by the deny rule in the policy
Show answer and explanationHide answer
Correct answer: AAn explicit deny overrides allows from any attached policy for that path. It does not merely log, delete secrets, or apply only to root.
Question 11
Which command shows the policies, TTL and other details attached to the current token?
- Avault status, which displays the policies attached to the token for each secrets engine in the cluster
- Bvault token lookup, which displays the token's policies, TTL and other details
- Cvault audit list, which displays the policies that each token used in each request in the audit log
- Dvault secrets list, which displays the policies that protect each secret stored in the cluster's engines
Show answer and explanationHide answer
Correct answer: Bvault token lookup displays the token's details, including policies and TTL. Status, audit list and secrets list show other information.
Question 12
Which Vault component records requests and responses to a configured destination, with sensitive values hashed?
- AAn audit device, which logs requests and responses to a configured destination with sensitive values hashed
- BA lease, which records the time at which each secret was issued and revoked by the cluster for its history
- CA namespace, which records the requests made by each application team to the Vault server for reporting
- DA mount path, which records the secrets engine used for each request that is made to the Vault server
Show answer and explanationHide answer
Correct answer: AAn audit device logs requests and responses with sensitive values hashed. Leases, namespaces and mount paths do not record audit logs.
Question 13
What does the sudo capability permit in a Vault policy?
- AUnlimited access to all secrets and all auth methods in the cluster, without any policy needed to grant it at all
- BAccess to paths that are marked as root-protected, granted explicitly in the policy attached to the token
- CThe ability to change the Vault server's operating system package versions on each node as the cluster owner
- DThe ability to sign in without any authentication method being configured on the cluster's auth paths
Show answer and explanationHide answer
Correct answer: BSudo grants access to root-protected paths when explicitly allowed in a policy. It does not grant unlimited access, OS changes or authentication bypass.
Question 14
Which TWO are valid policy practices? (Choose two.)
- AGranting the least privilege needed on specific paths, instead of wildcards that cover all paths
- BGiving every application the root policy so that it never fails authorisation during its routine operations
- CUsing broad wildcards so that new paths are covered automatically, without any review of their needs
- DReviewing policies periodically and removing paths that are no longer used by any token or application
- EAttaching the admin policy to every token issued by the cluster, for consistency across the environment
Show answer and explanationHide answer
Correct answer: A, DLeast privilege on specific paths and periodic removal of unused paths keep policies tight. Root for every application, broad wildcards and admin on every token all break least privilege.
Question 15
Which TWO are correct about Vault's operational tasks? (Choose two.)
- ATaking regular Raft snapshots so that the cluster's data can be recovered after a failure
- BRunning production Vault in dev mode, because it is faster and has no operational overhead at all
- CStoring the unseal keys in the same location as the Vault data, for convenience during each restart
- DRotating root tokens and revoking old ones after an incident, to limit the exposure of the credentials
- EDeleting audit logs regularly, to save disk space on the Vault nodes in the cluster that run the service
Show answer and explanationHide answer
Correct answer: A, DRaft snapshots enable recovery, and rotating and revoking root tokens after an incident limits exposure. Dev mode in production, unseal keys with data and deleting audit logs are unsafe.
Question 16
Which HCL policy path pattern matches every path under the secret/ mount in a policy?
- Asecret/ with no wildcard, which matches every nested path under the mount in the policy as well
- Bsecret/* with a wildcard, which matches all paths under the secret mount in the policy
- C*/secret, which matches the secret engine at every mount path name in the cluster for each token
- Dsecret:all, which is the policy syntax for granting access to every engine at every path in the cluster
Show answer and explanationHide answer
Correct answer: BThe wildcard secret/* matches paths under the mount. Without a wildcard the match is exact, and the other forms are not valid path patterns.
Secrets Engines and Leases (7 questions)
Question 17
Which secrets engine generates short-lived database credentials that expire automatically?
- AThe database secrets engine, which creates short-lived credentials for the database on request
- BThe KV secrets engine, which stores the database password as a static value that never changes over time
- CThe transit secrets engine, which encrypts the database rows with a key that is rotated on a monthly schedule
- DThe PKI secrets engine, which issues certificates for the database servers used by the application each day
Show answer and explanationHide answer
Correct answer: AThe database secrets engine creates short-lived dynamic credentials. KV stores static values, transit encrypts data and PKI issues certificates.
Question 18
What is a lease in Vault?
- AA reservation of disk space on the storage backend, which is released automatically when a user logs out
- BA rental agreement for the Vault server's hardware, which is recorded by the procurement team each year
- CA contract that grants a user permission to sign in to the Vault UI for a fixed number of days in a year
- DA time-bound claim on a dynamic secret, which Vault revokes when the lease expires or is revoked
Show answer and explanationHide answer
Correct answer: DA lease is a time-bound claim on a dynamic secret that Vault revokes at expiry. Hardware rental, UI contracts and disk reservations are not leases.
Question 19
Which KV version supports version history and the ability to undelete a secret?
- AKV version 1, which keeps the full history of every value and supports soft delete for every secret stored
- BKV version 2, which keeps version history and supports soft delete and undelete of secrets
- CKV version 1 with a plugin, which stores each secret in a separate file and allows undelete by copying the file
- DA transit key, which stores each version of a secret and allows undelete by re-encrypting the old value
Show answer and explanationHide answer
Correct answer: BKV version 2 keeps version history with soft delete and undelete. KV version 1 has no versioning, and transit keys encrypt data rather than store secret versions.
Question 20
Which secrets engine provides encryption as a service so that applications do not store their own encryption keys?
- AThe KV secrets engine, which stores the encryption keys as plaintext values that applications read on start
- BThe transit secrets engine, which encrypts and decrypts data without storing the data itself in Vault
- CThe database secrets engine, which creates a new key for every query that the application sends to the database
- DThe PKI secrets engine, which signs every message sent between the applications with its own private key
Show answer and explanationHide answer
Correct answer: BThe transit engine performs encryption and decryption without storing the data, so applications need not hold keys. The other engines store secrets, create database credentials or issue certificates.
Question 21
Which secrets engine issues X.509 certificates from a Vault-managed certificate authority?
- AThe database secrets engine, which creates a certificate for each database user account when it is created
- BThe KV secrets engine, which stores certificate files as plaintext values that applications copy at start
- CThe transit secrets engine, which signs certificates by encrypting their contents with an application key
- DThe PKI secrets engine, which issues and manages X.509 certificates from a CA that Vault manages
Show answer and explanationHide answer
Correct answer: DThe PKI secrets engine issues and manages X.509 certificates. KV, transit and database engines do not act as certificate authorities.
Question 22
What happens to the credentials issued by a dynamic secret when its lease is revoked?
- AVault removes or disables the credentials it issued, so they can no longer be used to access the system
- BNothing happens to the credentials, because revocation only affects the lease record in Vault's own database
- CThe credentials are copied to the lease holder's personal folder, so that the holder keeps access after revocation
- DThe credentials are renewed automatically for another full TTL, so that access is never interrupted by revocation
Show answer and explanationHide answer
Correct answer: ARevoking a lease removes or disables the credentials it issued. Leaving them active, copying them and auto-renewing all defeat revocation.
Question 23
Which TWO are benefits of dynamic secrets over static secrets? (Choose two.)
- ACredentials are unique per request and expire automatically, which limits the exposure of each one
- BCredentials never change, so applications never need to be updated when a secret is rotated in the system
- CAccess is only possible for root users, which keeps the dynamic secrets limited to the administrators
- DThe same password is shared across all clients, which simplifies the rotation of the shared credential
- EA leaked credential has a short lifetime, which reduces the blast radius of a leak to the system
Show answer and explanationHide answer
Correct answer: A, EUnique, automatically expiring credentials limit exposure, and short lifetimes reduce the blast radius of a leak. Static credentials, root-only access and shared passwords are the opposite of dynamic secret benefits.
Authentication and Tokens (7 questions)
Question 24
Which auth method suits applications on Kubernetes that need secrets without storing a static credential?
- AAn unauthenticated endpoint that returns secrets to any caller on the cluster network without any check
- BA shared username and password written into the container image, which every pod uses to sign in
- CA root token copied into each pod's configuration file during the deployment of the application
- DThe Kubernetes auth method, which validates the pod's service account token with the cluster
Show answer and explanationHide answer
Correct answer: DThe Kubernetes auth method validates the pod's service account token, avoiding static credentials. Shared passwords, root tokens and unauthenticated endpoints are unsafe.
Question 25
What does a token's TTL define?
- AThe number of characters in the token string, which determines how hard the token is to guess
- BThe number of secrets the token is allowed to read in a single session before it is locked out
- CHow long the token remains valid before it expires and must be renewed or replaced
- DThe number of Vault nodes the token may contact during one request before it is refused by the cluster
Show answer and explanationHide answer
Correct answer: CTTL defines how long a token remains valid before renewal or replacement. Secret counts, string length and node counts are not TTL.
Question 26
Which token type is lightweight, not persisted, and cannot be renewed?
- ARoot tokens, which are persisted forever and can be renewed indefinitely by any user on the cluster
- BBatch tokens, which are lightweight, are not persisted, and cannot be renewed
- CPeriodic tokens, which are persisted and renewed automatically on a schedule set by the administrator
- DService tokens with the longest TTL available, which are renewed automatically by the storage backend
Show answer and explanationHide answer
Correct answer: BBatch tokens are lightweight, non-persisted and non-renewable, suited to short workloads. Root, periodic and long-TTL service tokens are persisted and renewable.
Question 27
Which auth methods let people sign in with credentials from an existing corporate directory?
- AA static list of IP addresses, which are allowed to read secrets whether or not their users are authenticated
- BThe root token, which is shared by the whole company so that every employee can sign in with it
- CLDAP or OIDC auth methods, which delegate authentication to the directory's identity provider
- DThe token accessor, which is printed on each employee's badge so that the badge can be scanned at the door
Show answer and explanationHide answer
Correct answer: CLDAP and OIDC delegate authentication to a directory or identity provider. Shared root tokens, IP lists and badge accessors are not directory authentication.
Question 28
In AppRole authentication, which element should be kept secret from the application's code?
- AThe name of the secrets engine that the application reads, which is listed in its configuration file
- BThe role ID, which is embedded in the source code of the application for its routine sign-in each time
- CThe secret ID, which is delivered to the application through a trusted channel at deployment time
- DThe URL of the Vault server, which is published openly in the application's documentation for developers
Show answer and explanationHide answer
Correct answer: CThe secret ID is the sensitive part, delivered through a trusted channel. The role ID is not treated as the secret, and the engine name and server URL are not secret.
Question 29
What does a periodic token do?
- AIt expires once at a fixed time each day and cannot be renewed by any process under any circumstances
- BIt can be renewed repeatedly to stay valid, without a maximum lifetime, as long as it is renewed in time
- CIt is valid only for one request, after which the token is removed from every node in the cluster automatically
- DIt is shared between all users of the cluster so that the same token serves the whole team at the same time
Show answer and explanationHide answer
Correct answer: BA periodic token can be renewed repeatedly without a maximum lifetime if renewed in time. Fixed expiry, single-request use and shared tokens do not describe periodic tokens.
Question 30
Which TWO are good practices for token handling? (Choose two.)
- AUsing short TTLs and renewing tokens only while the application still needs access to the secrets
- BSharing the root token among the operations team, so that access is quick during emergencies at any hour
- CStoring tokens in source code so that they are available for every deployment without any extra steps
- DRevoking tokens when a workload no longer needs access, so that leaked tokens stop working promptly
- EUsing one token for every application in the environment, to keep the configuration simple to manage
Show answer and explanationHide answer
Correct answer: A, DShort TTLs with renewal only when needed, and prompt revocation, limit token exposure. Shared root tokens, tokens in code and one token for everything widen the risk.