All HashiCorp exams

Free Vault Operations Advanced practice test: 30 questions with answers

30 original questions for Vault Operations Advanced, 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
240 min

Vault Operations Advanced exam guide: topics, cost and format

All 30 Vault Operations Advanced questions with answers

The same questions as the test above, grouped by exam topic. Open any question to see the answer and explanation.

Build a working Vault server configuration for a given scenario (4 questions)

  1. Question 1

    A team needs a Vault server for a proof of concept that will hold real customer data within a month. An engineer proposes starting it in dev mode now and moving the data later. Which statement best explains why this plan is wrong?

    1. ADev mode keeps data in memory, runs with TLS disabled, and must never hold production secrets
    2. BDev mode requires an Enterprise license, so the team would need to purchase one before starting
    3. CDev mode disables every auth method, so each one would need to be re-enabled by hand afterward
    4. DDev mode seals itself after every restart, so the team would need to script an unseal step before tests
    Show answer and explanation
    Correct answer: A

    Dev mode is meant only for local experiments: it stores data in memory, runs without TLS, and starts unsealed with a printed root token, so its data cannot be carried into a production cluster. The other options describe licensing, auth handling, and sealing behaviour that dev mode does not have.

  2. Question 2

    A regulated company runs a three-node Vault cluster in AWS. After a host reboot, operators must not have to type key shares, and the key that protects Vault's master key must be a customer-managed key. Which configuration meets both requirements?

    1. AKeep the default Shamir seal and have operators enter key shares after every restart
    2. BAdd a seal stanza for AWS KMS so the root key is wrapped by a customer-managed KMS key
    3. CRun each node in dev mode so it starts unsealed after reboots without any operator action
    4. DStore the unseal keys in a plain text file on each node so a startup script can read them
    Show answer and explanation
    Correct answer: B

    An AWS KMS seal stanza enables auto-unseal, so nodes unseal after a restart without key shares, and the wrapping key is a KMS key the company controls. The Shamir option needs people after each restart, dev mode is unsuitable for production, and plain text key files defeat the purpose of sealing.

  3. Question 3

    Which statement correctly distinguishes the rotate and rekey operations in Vault?

    1. ARotate creates a new encryption key for future writes, while rekey issues new unseal key shares
    2. BRotate issues new unseal key shares, while rekey creates a new encryption key for new writes
    3. CRekey changes the root token, and rotate changes which auth methods are enabled on the cluster
    4. DBoth operations delete existing secrets so that the cluster can start with a clean encryption state
    Show answer and explanation
    Correct answer: A

    vault operator rotate adds a new encryption key term that Vault uses for new data while older keys remain available to read existing data, and vault operator rekey replaces the unseal key shares. The first option swaps the two commands, and the last two options claim changes that neither command makes.

  4. Question 4

    A team wants Vault to issue short-lived database logins to an application. Which two steps are part of this setup? (Choose two.)

    1. AEnable the database secrets engine at a mount path and configure a connection to the database
    2. BCreate a role that defines the SQL statements Vault runs to create database users
    3. CPlace the database administrator password in the application's configuration file for reuse
    4. DDisable the key-value secrets engine so that its mount path can be used by the database engine
    Show answer and explanation
    Correct answer: A, B

    The database secrets engine must be mounted and given a connection, and a role defines how each dynamic user is created. Copying the administrator password into application files is a security risk, and disabling the KV engine is unrelated to dynamic database credentials.

Monitor a Vault environment (4 questions)

  1. Question 5

    A platform team wants to alert when Vault's request latency rises, and its Prometheus server scrapes the cluster. Which Vault endpoint returns metrics in a format Prometheus can scrape directly?

    1. AThe vault status command run on a schedule, with its text output parsed by a cron job
    2. BThe audit log device, which forwards every request record to the Prometheus server for graphing
    3. CThe sys/health endpoint, which returns the cluster's recent request latency values as numbers
    4. DThe sys/metrics endpoint with format set to prometheus, which returns metrics for scraping
    Show answer and explanation
    Correct answer: D

    Vault exposes runtime metrics through sys/metrics, and the format=prometheus parameter produces output Prometheus can scrape. Audit logs record requests rather than metrics, sys/health reports health status rather than latency, and parsing vault status output is not a supported metrics interface.

  2. Question 6

    What happens to client requests if every enabled audit device fails to write its log entry?

    1. AVault switches to dev mode for the affected requests until an audit device comes back online
    2. BVault keeps serving requests and holds the missed audit entries in memory until a device recovers
    3. CVault blocks the requests, because it cannot record them in any audit device
    4. DVault writes the entries to its operational log instead and continues handling requests normally
    Show answer and explanation
    Correct answer: C

    Vault fails closed on auditing: if no audit device can record a request, the request is refused, so audit coverage is never silently skipped. The other options assume buffering, a dev-mode fallback, or substitution of operational logs, none of which Vault does for the audit trail.

  3. Question 7

    An administrator is troubleshooting a Vault cluster and wants to know what the server itself logs about startup and internal events. Which two statements about operational logs are true? (Choose two.)

    1. AThey record server activity such as startup, seal status changes, and internal errors
    2. BThey list every secret value that clients read, with the values shown in clear text
    3. CThey go to the configured log destination, and the log level controls how much detail appears
    4. DThey are the only record that can prove which client accessed a particular secret
    Show answer and explanation
    Correct answer: A, C

    Operational logs describe the server's own behaviour, and their verbosity is set by the configured log level. Secret values are not written to operational logs in clear text, and the audit log, not the operational log, is the record that shows which client accessed a secret.

  4. Question 8

    A compliance team needs every audit entry streamed over TCP to a central log collector, with no audit file left on the Vault hosts. Which audit device type fits?

    1. AThe telemetry audit device, which exports request counters to the monitoring server over UDP
    2. BThe file audit device, pointed at a log directory that a shipping agent copies from hourly
    3. CThe database audit device, which writes entries into a SQL table through the database secrets engine
    4. DThe socket audit device, configured to send entries over TCP to the collector's address
    Show answer and explanation
    Correct answer: D

    The socket audit device can send audit entries over TCP to a remote collector without writing a local file. The file device leaves files on the hosts, and the other two options name device types that do not exist for audit logging.

Apply the Vault security model (4 questions)

  1. Question 9

    A deployment pipeline runs on self-hosted runners outside Kubernetes and needs to read one secret path. The security team wants each runner to get only the policy it needs, and wants credentials that can be rotated without editing that policy. Which auth method fits best?

    1. AThe root token, copied into the pipeline and replaced whenever a runner is rebuilt
    2. BUserpass, with one shared username and password stored in the pipeline's variables
    3. CAppRole, with a role_id stored in the pipeline and a secret_id issued for each run
    4. DThe Kubernetes auth method, with each runner presenting the service account token from its own cluster
    Show answer and explanation
    Correct answer: C

    AppRole is designed for machines: the role_id identifies the role, and a secret_id can be issued and rotated separately without changing the policy. Userpass shares one login across runners, the root token gives unlimited access, and runners outside Kubernetes have no service account token to present.

  2. Question 10

    An operator must hand a newly generated AppRole secret_id to an automation job over a channel that others could observe. The value should be usable only once and expire quickly. Which Vault feature supports this?

    1. ADev mode, which generates the secret_id with an unlimited lifetime so quick tests never need renewal
    2. BResponse wrapping, which places the secret in a single-use token that expires after a short TTL
    3. CRoot policy inheritance, which attaches the secret_id to the default policy for every new token
    4. DAudit log HMAC, which hides the secret_id inside the audit entries that the automation job reads
    Show answer and explanation
    Correct answer: B

    Response wrapping returns the secret inside a single-use wrapping token with a short TTL, so the value can be unwrapped once before the token expires. Dev mode is not for production, root policy inheritance does not transport secrets, and HMAC only protects values inside audit entries.

  3. Question 11

    A cluster operator configured the Kubernetes auth method so pods can log in. Logins fail with a permission error when Vault tries to validate a pod's service account token. Which change most likely fixes this?

    1. AGive each application pod the cluster-admin role so it can read its own token
    2. BGrant the Vault service account permission to call the Kubernetes TokenReview API
    3. CSwitch the auth method to userpass so pods can present a username and password
    4. DMount the Kubernetes API certificate into every pod so clients can skip token validation
    Show answer and explanation
    Correct answer: B

    Vault validates pod tokens by calling the Kubernetes TokenReview API, so its own service account needs permission to make that call, typically through a cluster role binding. Granting pods cluster-admin is excessive, and the other two options either weaken validation or abandon the Kubernetes method.

  4. Question 12

    Which practice best reduces risk after a new Vault cluster is initialized?

    1. AAttach the root policy to the default policy so every new token inherits administrator rights
    2. BStore the initial root token in a shared team note so anyone can reach the cluster in an emergency
    3. CGive the root token a one-year TTL and renew it from an automation job each month
    4. DRevoke the initial root token once setup is finished and use scoped tokens for daily work
    Show answer and explanation
    Correct answer: D

    Root tokens do not expire, so the initial one should be revoked after setup and generated again only when genuinely needed. Scoped tokens limit what each person or workload can do. The other options keep or spread root-level access in ways that increase exposure.

Build fault-tolerant Vault environments (4 questions)

  1. Question 13

    An operator is building an HA Vault cluster with integrated storage. The team wants the cluster to keep its quorum after losing any single node, using the fewest voting members possible. Which design fits?

    1. ATwo voting nodes, which keeps one standby ready for each active node
    2. BOne voting node, which avoids quorum calculations and still provides high availability
    3. CFour voting nodes, which is the smallest count that tolerates a single node failure
    4. DThree voting nodes, which keeps a quorum of two after the loss of any single node
    Show answer and explanation
    Correct answer: D

    Raft needs a majority of voting members, so three voters keep a quorum of two when one fails. Two voters cannot survive a failure, four voters tolerate one failure too but are not the smallest option, and a single voter offers no high availability.

  2. Question 14

    A company runs its primary Vault cluster in one region. It wants a warm copy in another region that can take over the whole service if the primary region is lost. Which replication mode fits this requirement?

    1. APerformance replication, which lets the secondary serve all reads and writes locally at all times
    2. BDR replication, which keeps a full copy of the primary that stays inactive until it is promoted
    3. CSnapshot restore, which copies the data once per night into a file the team restores by hand
    4. DShared dev-mode nodes, which keep an in-memory copy of the data in both regions for failover
    Show answer and explanation
    Correct answer: B

    DR replication maintains a full secondary that does not serve client traffic until an operator promotes it, which is the purpose of a disaster recovery site. Performance replication is designed to scale reads and still forwards writes upstream, snapshots are periodic backups rather than live failover, and dev-mode nodes are not for production.

  3. Question 15

    A DR secondary has been running in standby during a regional outage, and the team now decides to make it the active primary. Which action is required before the secondary can take over as primary?

    1. ARun vault operator init again on the secondary to create a fresh set of unseal keys
    2. BGenerate a DR operation token and use it to promote the secondary to primary
    3. CEnable performance replication from the secondary back to the failed primary first
    4. DReplay the audit log from the failed primary into the secondary's storage backend
    Show answer and explanation
    Correct answer: B

    Promotion of a DR secondary is authorized with a DR operation token, which is created using key material held by operators. Re-initializing does not promote a replica, and replication or audit replay does not make a secondary the active primary.

  4. Question 16

    A five-voter Vault cluster on integrated storage loses two nodes, and one of the lost nodes was the active node. What is the expected state of the cluster?

    1. AIt becomes sealed, because every write requires all five voters to acknowledge the change
    2. BIt stays available, because three of five voters still form a majority and elect a new leader
    3. CIt switches to performance replication until the two lost nodes are rebuilt from a snapshot
    4. DIt keeps the old active node in charge, because standby nodes are not allowed to take over leadership
    Show answer and explanation
    Correct answer: B

    With five voters a majority is three, so the remaining three can elect a new active node and keep serving requests. Requiring all five voters is wrong for Raft, performance replication is not a failover mechanism for lost voters, and standby nodes can take over leadership.

Understand HSM integration (4 questions)

  1. Question 17

    A bank requires that Vault's master key protection come from a hardware security module in its own data center, with no key material held by a public cloud provider. Which Vault feature provides this?

    1. AThe pkcs11 seal stanza, which uses the on-premises HSM for automatic unsealing
    2. BThe awskms seal stanza, which uses AWS-managed keys for automatic unsealing
    3. CA Shamir seal with key shares generated inside the HSM and typed in by operators
    4. DDev mode with an HSM simulator, which keeps the master key in memory on the host
    Show answer and explanation
    Correct answer: A

    The pkcs11 seal integrates Vault with a PKCS#11-capable HSM, which holds the wrapping key and unseals the cluster automatically. The awskms seal depends on a cloud provider, a Shamir seal still needs operators after each restart, and dev mode is not a production configuration.

  2. Question 18

    What does seal wrap add when an HSM-backed seal is in use?

    1. AAll audit logs are written to the HSM so that no log file is left on the Vault host
    2. BEvery client request is routed through the HSM so the device can authenticate each user and each request
    3. CSome sensitive values, such as certain keys, are wrapped with the seal's HSM key before storage
    4. DEach secret is encrypted with a key held by the client rather than by the cluster itself
    Show answer and explanation
    Correct answer: C

    Seal wrap uses the seal mechanism to protect critical security parameters that would otherwise rely only on Vault's own barrier encryption. The other options describe request routing, audit storage, and client-side encryption, none of which seal wrap provides.

  3. Question 19

    A cluster using the default Shamir seal moves to HSM-based auto-unseal so operators no longer enter key shares. The existing data must be kept. Which step is required during the migration?

    1. AProvide the existing Shamir unseal keys during the migration unseal so Vault can move to the new seal
    2. BRun vault operator init again so the HSM can generate a fresh master key for the existing data
    3. CDelete the Shamir key shares and let the HSM generate new shares for every node in the cluster
    4. DExport every secret into a KV engine on a separate cluster, then restore them after re-initialization
    Show answer and explanation
    Correct answer: A

    Seal migration requires the current unseal keys, because Vault must decrypt its master key with the old seal before re-protecting it with the new one. Running init again does not migrate existing data, and deleting shares or exporting secrets does not perform a seal migration.

  4. Question 20

    Which statement about recovery keys under auto-unseal is correct?

    1. ARecovery keys become unnecessary once the HSM is connected, so Vault discards them at init
    2. BRecovery keys are the HSM's private key, which must be exported to every node for unsealing
    3. CRecovery keys replace unseal keys and authorize operations such as generating root tokens
    4. DRecovery keys decrypt the audit log, so they are needed only when an auditor requests access
    Show answer and explanation
    Correct answer: C

    With auto-unseal, vault operator init returns recovery keys instead of unseal keys, and those keys authorize sensitive operations such as root token generation. They are not used for routine unsealing, which the seal handles, and they do not decrypt the audit log.

Scale Vault for performance (4 questions)

  1. Question 21

    Which statement describes a limitation of batch tokens compared with service tokens?

    1. AThey cannot be renewed and cannot be used to create child tokens
    2. BThey cannot be used with any auth method that supports token_type
    3. CThey cannot carry policies, so they always inherit only the default policy
    4. DThey are valid only on the active node and are rejected by performance standby nodes
    Show answer and explanation
    Correct answer: A

    Batch tokens are lightweight, encrypted blobs that are not stored in Vault's storage, so they cannot be renewed, cannot have child tokens, and have no accessor. They do carry policies, can be issued by auth methods through token_type, and work on performance standby nodes.

  2. Question 22

    A Vault Enterprise cluster serves heavy read traffic from many applications, and the active node is overloaded. The team wants more read capacity without changing how writes are handled. Which node type should it add?

    1. AAdditional audit devices, which spread request handling across more file writers on the cluster
    2. BDisaster recovery secondary nodes, which accept client reads only after the primary cluster fails
    3. CDev-mode nodes that keep a separate in-memory copy of every secret so reads never reach the active node
    4. DPerformance standby nodes, which serve most reads locally and forward writes to the active node
    Show answer and explanation
    Correct answer: D

    Performance standby nodes handle most read requests locally and forward write requests to the active node, so read capacity grows without changing write handling. DR secondaries do not serve client traffic until promotion, dev-mode nodes are not production components, and audit devices record requests rather than handle them.

  3. Question 23

    A company has a primary Vault cluster in one region and wants applications in another region to read secrets with low latency, while every write still goes through the primary. Which replication mode is the best match?

    1. APerformance replication, where the secondary serves local reads and forwards writes upstream
    2. BDR replication, where the secondary accepts writes directly from clients and forwards them later
    3. CScheduled manual exports, where operators copy secrets between the clusters once every week
    4. DSnapshot copies, which the secondary restores each time a read request arrives from a client
    Show answer and explanation
    Correct answer: A

    Performance replication lets a secondary cluster serve reads locally while forwarding writes to the primary, which keeps a single write path. DR replication is for failover and does not accept client writes, while manual exports and snapshot restores do not provide live replication.

  4. Question 24

    A performance primary serves three regions, and the EU secondary must not receive secrets mounted for the US team. Which performance replication feature limits which mounts reach that secondary?

    1. ABatch tokens, which keep each region's requests on a separate token type
    2. BPaths filter, which controls the mount paths a given secondary is allowed to receive
    3. CDR replication, which copies every mount to the EU cluster and blocks reads from it
    4. DPerformance standby nodes, which hold a separate copy of each region's mounts in memory
    Show answer and explanation
    Correct answer: B

    A paths filter configured on the primary limits which mount paths are replicated to a particular secondary. Batch tokens and performance standbys do not decide which mounts a secondary receives, and DR replication copies everything rather than filtering.

Configure access control (3 questions)

  1. Question 25

    One ACL policy grants read on secret/data/app/* to a group. A second policy attached to the same token sets deny on secret/data/app/prod. What is the outcome for a read of secret/data/app/prod?

    1. AThe read is allowed, because a group's policies always take precedence over the policies on the token
    2. BThe read is allowed, because a wildcard path that is more general than the deny path takes priority over it
    3. CThe read succeeds once and then fails, because policies are evaluated in alphabetical order by name
    4. DThe read is denied, because a deny capability overrides any allow from other policies
    Show answer and explanation
    Correct answer: D

    In Vault ACL evaluation, deny takes precedence over every other capability from any attached policy, regardless of path specificity. The other options assume wildcard priority, alphabetical ordering, or group precedence, none of which override an explicit deny.

  2. Question 26

    The security team wants everyone in the payments LDAP group to receive the same Vault policies, without configuring each user one at a time. Which Vault feature provides this?

    1. ABatch tokens issued to each member, which carry the policies of the payments group automatically
    2. BA separate token for each user, created by the root token and copied into each user's account
    3. CAn external identity group linked to the LDAP group alias, so members inherit its policies
    4. DAn audit device filter that copies the LDAP group's permissions into every audit log entry
    Show answer and explanation
    Correct answer: C

    An external group in the identity system is mapped to the directory group through an alias, so each member's entity inherits the policies attached to the Vault group. Per-user tokens need manual management, batch tokens do not carry group policies, and audit filters do not grant permissions.

  3. Question 27

    Which statement about Sentinel policies in Vault Enterprise is correct?

    1. AThey encrypt secret values before the backend stores them, using keys issued by a sentinel node in the cluster
    2. BThey replace ACL policies entirely, so path-based capabilities are no longer evaluated for requests
    3. CThey run only in dev mode and are ignored by any cluster that uses integrated storage
    4. DThey add policy-as-code rules on top of ACL policies, with levels such as advisory or hard-mandatory
    Show answer and explanation
    Correct answer: D

    Sentinel is Vault Enterprise's policy-as-code framework: its rules run in addition to ACL policies, and each policy has an enforcement level such as advisory, soft-mandatory, or hard-mandatory. The other options misdescribe Sentinel as a replacement for ACLs, a dev-only feature, or an encryption mechanism.

Configure Vault Agent (3 questions)

  1. Question 28

    A batch job runs on a host where Vault Agent handles authentication. The job needs a valid token in a file that only its user can read, and the agent should refresh that token automatically. Which Vault Agent setting handles this?

    1. AA template that writes the root token into the job's environment file at the start of every run
    2. BAn auto-auth method with a file sink that writes the token to a path the job can read
    3. CA listener that serves the token on an open HTTP port so the job can query it whenever it runs
    4. DA cache section that stores each secret in the audit log so the job can read it there later
    Show answer and explanation
    Correct answer: B

    Auto-auth lets Vault Agent authenticate and keep the token renewed, and a file sink writes that token to disk with file permissions the job's user can control. Writing the root token into an environment file is poor practice, an open HTTP listener exposes the token, and the audit log is not a cache.

  2. Question 29

    A web application reads its database password from a local file. Vault rotates that password daily. The team wants the file kept current without the application calling Vault itself. Which Vault Agent feature fits?

    1. AA listener that proxies each application request and returns the password from Vault on every query
    2. BA static token file that the application reads once at startup and never refreshes during its lifetime
    3. CA template stanza that renders the secret into the file and re-renders it when the secret changes
    4. DA response-wrapped token that the application unwraps before opening every new database connection
    Show answer and explanation
    Correct answer: C

    Vault Agent templating reads the secret from Vault, writes it into a destination file, and re-renders the file when the underlying secret changes. The other options leave a stale value in place or require the application to call Vault itself.

  3. Question 30

    Which two statements about Vault Agent templating are correct? (Choose two.)

    1. ATemplates use consul-template syntax to read secrets and render them into a destination file
    2. BTemplates can only render static text, so secrets must be copied into the template by hand
    3. CThe agent re-renders a template when the secret it reads changes, such as after a rotation
    4. DTemplates send their rendered output to the audit device so that the output is HMAC-protected
    Show answer and explanation
    Correct answer: A, C

    Vault Agent templates use the consul-template language to render Vault secrets into files, and the agent re-renders them when the source secret changes. Templates are not limited to static text, and rendered output is written to a file rather than sent to the audit device.