Courseiva
Create Vault policies →mediumMultiple Choice

VA-003 Create Vault policies Practice Question

Exhibit

path "secret/data/team-a/*" {
  capabilities = ["read", "list"]
}
path "secret/data/team-a/admin" {
  capabilities = ["deny"]
}

Refer to the exhibit. A user with this policy attempts to read the secret at path "secret/data/team-a/admin". What will happen?

⚠ Common exam trap

Candidates often mistakenly think Vault uses a first-match or most-specific-path-wins model, similar to firewall rules, when in fact deny always overrides allow regardless of path specificity.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

The read is denied because the deny policy takes precedence.

The deny policy takes precedence over any allow policy in Vault, regardless of the path specificity. Even though the first path grants read access to 'secret/data/team-a/*', the second path explicitly denies all capabilities (including read) on 'secret/data/team-a/admin', which is a more specific path. Vault's policy evaluation uses a deny-overrides model, so the deny action blocks the read operation.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    The read fails because the path does not exist.

    Why it's wrong here

    The path exists in Vault's KV v2 mount; the request fails because a matching deny policy overrides the grant, not because the secret is absent. Path-existence errors return different responses, and this policy explicitly names the admin path.

  • ✗

    The read succeeds because the first path grants read.

    Why it's wrong here

    Vault evaluates all matching policies and any matching deny capability takes precedence, so a broader grant cannot override a more specific deny on the same path. The first path grants read only where no deny matches; here the deny rule wins, so the read is refused.

  • ✗

    The read succeeds because deny only applies to write operations.

    Why it's wrong here

    A deny capability in Vault blocks every listed capability on the matching path, including read, not just write. Deny is an explicit precedence rule evaluated after all grants, so any read request matching that path is rejected regardless of other policies.

  • ✓

    The read is denied because the deny policy takes precedence.

    Why this is correct

    Vault evaluates all matching policies together, and any matching deny rule overrides grants regardless of specificity or order. The deny on that path therefore blocks the read even if another policy grants it, so access is refused.

About these practice questions

Courseiva writes every VA-003 question from scratch — 366 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This VA-003 practice question is part of Courseiva's free HashiCorp certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the VA-003 exam.