VAULT-ASSOCIATE-002 · Question #31
Which of the following statements are true about Vault policies? (Choose two.)
The correct answer is C. Policies provide a declarative way to grant or forbid access to certain paths and operations in Vault E. Policies deny by default (empty policy grants no permission). Vault policies use a declarative HCL or JSON syntax to define granular permissions for paths and operations, inherently denying access by default.
Question
Options
- AThe default policy can not be modified
- BYou must use YAML to define policies
- CPolicies provide a declarative way to grant or forbid access to certain paths and operations in Vault
- DVault must be restarted in order for a policy change to take an effect
- EPolicies deny by default (empty policy grants no permission)
How the community answered
(35 responses)- B3% (1)
- C91% (32)
- D6% (2)
Why each option
Vault policies use a declarative HCL or JSON syntax to define granular permissions for paths and operations, inherently denying access by default.
The "default" policy, while automatically assigned to new tokens, can be modified by a root token or a token with sufficient privileges.
Vault policies are typically defined using HCL (HashiCorp Configuration Language), although JSON is also supported, not exclusively YAML.
Vault policies are written in HCL (Hashicorp Configuration Language) or JSON and declaratively specify which paths a client can access and what operations (read, create, update, delete, list, sudo) are allowed or forbidden on those paths.
Policy changes in Vault are dynamic; they take effect immediately upon being written or updated, without requiring a restart of the Vault server.
Vault's policy system operates on a "deny by default" principle. If a permission is not explicitly granted in a policy attached to a token, access to that path or operation is denied. An empty policy, therefore, grants no permissions.
Concept tested: Vault policy definition and default behavior
Source: https://developer.hashicorp.com/vault/docs/concepts/policies
Topics
Community Discussion
No community discussion yet for this question.