CKA RBAC and Security 1 — Questions and Answers
Question 1: What does RBAC stand for in Kubernetes?
- Role-Based Access Control (Correct answer)
- Resource-Based Allocation Configuration
- Runtime Binary Access Control
- Replica-Based Auto Configuration
Correct answer: Role-Based Access Control
RBAC (Role-Based Access Control) regulates access to Kubernetes resources based on the roles assigned to users or service accounts.
Question 2: What is a Kubernetes Secret?
- An object that stores sensitive data like passwords and tokens (Correct answer)
- A hidden Pod
- An encrypted node
- A private namespace
Correct answer: An object that stores sensitive data like passwords and tokens
Secrets store sensitive information like passwords, API keys, and certificates, keeping them separate from Pod specs and container images.
Question 3: What is a ServiceAccount in Kubernetes?
- An identity for processes running in Pods to interact with the API server (Correct answer)
- A user login account
- A billing account
- A monitoring agent
Correct answer: An identity for processes running in Pods to interact with the API server
ServiceAccounts provide an identity for Pods to authenticate with the Kubernetes API server, controlling what resources processes can access.
Question 4: What is the principle of least privilege?
- Granting only the minimum permissions needed to perform a task (Correct answer)
- Giving all users admin access
- Removing all security restrictions
- Using the same account for everything
Correct answer: Granting only the minimum permissions needed to perform a task
The principle of least privilege means granting users and processes only the minimum level of access needed to perform their specific functions, reducing security risk.
Question 5: What is a NetworkPolicy in Kubernetes?
- A resource that controls network traffic flow between Pods (Correct answer)
- A firewall appliance
- A DNS configuration
- A load balancer rule
Correct answer: A resource that controls network traffic flow between Pods
NetworkPolicies define rules for which Pods can communicate with each other and with external endpoints, implementing network-level security.
Question 6: What is Pod Security context used for?
- Defining privilege and access control settings for Pods and containers (Correct answer)
- Monitoring Pod performance
- Logging Pod events
- Scheduling Pod placement
Correct answer: Defining privilege and access control settings for Pods and containers
Security context defines security settings like user IDs, group IDs, capabilities, and read-only filesystems for Pods and their containers.
What does RBAC stand for in Kubernetes?