|
| 1 | +--- |
| 2 | +title: Layered Zero Trust |
| 3 | +date: 2025-06-11 |
| 4 | +tier: sandbox |
| 5 | +summary: Layered Zero Trust demonstrates how to operationalize Zero Trust security principles when using products in the Red Hat Portfolio. |
| 6 | +rh_products: |
| 7 | +- Red Hat OpenShift Container Platform |
| 8 | +industries: |
| 9 | +aliases: /layered-zero-trust/ |
| 10 | +links: |
| 11 | + github: https://github.com/validatedpatterns/layered-zero-trust/ |
| 12 | + install: https://github.com/validatedpatterns/layered-zero-trust/?tab=readme-ov-file#getting-started |
| 13 | + bugs: https://github.com/validatedpatterns/layered-zero-trust/issues |
| 14 | + feedback: https://docs.google.com/forms/d/e/1FAIpQLScI76b6tD1WyPu2-d_9CCVDr3Fu5jYERthqLKJDUGwqBg7Vcg/viewform |
| 15 | +ci: layeredzerotrust |
| 16 | +--- |
| 17 | + |
| 18 | + |
| 19 | +:toc: |
| 20 | +:imagesdir: /images |
| 21 | +:_mod-docs-content-type: ASSEMBLY |
| 22 | +include::modules/comm-attributes.adoc[] |
| 23 | + |
| 24 | +[id="about-lzt-pattern"] |
| 25 | += About the Layered Zero Trust pattern |
| 26 | + |
| 27 | +link:https://www.redhat.com/en/topics/security/what-is-zero-trust[Zero trust] is an approach to designing security architectures based on the premise that every interaction begins in an untrusted state. |
| 28 | +The Layered Zero Trust pattern describes how to implement a zero trust architecture in a {rh-ocp} environment. |
| 29 | +The pattern identifies specific transactions between an actor and a resource within the environment. |
| 30 | +For these transactions, you can identify the context and implement policy enforcement. |
| 31 | + |
| 32 | +Because of the breadth and diversity of possible interactions between components in {ocp}, this pattern is presented as a set of abstract, stackable layers. |
| 33 | +These layers provide the prerequisite capabilities that are needed to implement appropriate enforcement points. |
| 34 | +For each instance, this pattern describes the associated actors, transactions, and the zero trust policy that you can implement within the platform. To provide context for users, this pattern uses relevant business use cases and traces them to the associated implementation components. |
| 35 | + |
| 36 | +Use case:: |
| 37 | +The pattern addresses the shortcomings of traditional cybersecurity methods, such as defensive hardening and reactive detection. |
| 38 | +It is particularly effective for the following types of systems and environments: |
| 39 | + |
| 40 | +* Distributed systems, such as cloud and edge environments. |
| 41 | +* Autonomous and artificial intelligence (AI) or machine learning (ML) based systems, including robotic process automation. |
| 42 | +* Large, composite systems that integrate third-party or legacy components. |
| 43 | + |
| 44 | +This pattern provides specific implementations for each of these business use cases within its abstract, layered structure. |
| 45 | + |
| 46 | +Background:: |
| 47 | + |
| 48 | +Traditional security approaches are often incomplete, as they are susceptible to unknown exploits (zero-days) and rely on human-intensive processes that can be inconsistent and prone to error. |
| 49 | +Attackers continuously develop new methods to evade signature-based detection and exploit systems by targeting those already deemed trustworthy. |
| 50 | + |
| 51 | +In contrast, the Zero Trust architecture operates from the assumption that a breach will occur. |
| 52 | +It focuses on preventing further compromise by establishing well-defined security boundaries and enforcing a deny-all default access control stance. |
| 53 | +The pattern emphasizes significant automation and grants access dynamically, based on policies, with a least-privilege, as-needed approach. |
| 54 | +Instead of relying on signatures, it explicitly enumerates allowed actors and monitors their behavior, which is a more effective way to contain malicious activity. |
| 55 | +Zero Trust architectures incorporate contextual information and user behavior analytics to inform access decisions, proactively preventing lateral movement in case of a compromise. |
| 56 | + |
| 57 | +[id="about-solution"] |
| 58 | +== About the solution |
| 59 | + |
| 60 | +The Layered Zero Trust pattern implements a layered zero trust architecture that shows workload identity management, secure communication, and secret management capabilities. |
| 61 | + |
| 62 | +The solution integrates many Red{nbsp}Hat components to offer: |
| 63 | + |
| 64 | +* Workload identity using Secure Production Identity Framework for Everyone (SPIFFE) and SPIFFE Runtime Environment (SPIRE) standards. |
| 65 | +* Secure secret management through HashiCorp Vault. |
| 66 | +* Identity and access management by using the Red{nbsp}Hat build of Keycloak (RHBK). |
| 67 | +* Certificate management for secure communications. |
| 68 | +* External secret management integration. |
| 69 | + |
| 70 | +[id="architecture"] |
| 71 | +=== Architecture |
| 72 | + |
| 73 | +The Layered Zero Trust pattern architecture consists of many components that work together to offer a secure environment for applications and workloads. |
| 74 | + |
| 75 | +The pattern consists of the following key components: |
| 76 | + |
| 77 | +. Zero Trust Workload Identity Manager: Implements workload identity using SPIFFE/SPIRE. |
| 78 | +. HashiCorp Vault: Provides secure secret storage and management. |
| 79 | +. Red{nbsp}Hat build of Keycloak (RHBK): Manages identity and access for users and services. |
| 80 | +. OpenShift Cert Manager: Manages the lifecycle of certificates for secure communication. |
| 81 | +. External Secrets Operator: Synchronizes secrets from external systems into the cluster. |
| 82 | +. QTodo application: Serves as a Quarkus-based application to show zero trust principles. |
| 83 | +. PostgreSQL database: Provides the backend database for the demonstration application. |
| 84 | + |
| 85 | +[id="sidecar-pattern"] |
| 86 | +==== Sidecar pattern |
| 87 | + |
| 88 | +The sidecar pattern is a deployment model where a separate container or process, called a sidecar, runs alongside a main application to handle auxiliary tasks. |
| 89 | +In an {ocp} environment, this is simplified through the use of pods, which ensure the sidecar and main application share the same lifecycle. |
| 90 | +This approach is highly beneficial for Zero Trust architectures because it allows for the centralized enforcement of security policies, such as authentication, authorization, traffic encryption (mTLS), rate limiting, auditing, and logging, without requiring developers to build this logic into every microservice. |
| 91 | +It separates concerns, simplifies development, and allows security policies to be updated independently of the main application. |
| 92 | + |
| 93 | +While sidecars are often criticized for adding complexity and resource usage, the text argues these are often misconceptions: |
| 94 | + |
| 95 | +* *Complexity*: Sidecars simplify the main application by offloading tasks, and modern platforms, such as {ocp}, are designed to manage them efficiently. |
| 96 | +* *Resource Usage*: The resource cost of a sidecar is often minimal compared to the additional CPU and memory required to integrate security logic into every application. |
| 97 | +* *Debugging*: Sidecars can simplify debugging by isolating logs and metrics from the main application, making it easier to pinpoint the source of a policy failure. |
| 98 | + |
| 99 | +The Layered Zero Trust pattern makes extensive use of the sidecar approach to achieve its goals by offloading critical security functions from the main application. |
| 100 | +This provides significant benefits by centralizing policy enforcement, simplifying development, and separating security concerns. |
| 101 | +The specific sidecar patterns used in this approach handle tasks, such as, authentication and authorization, traffic encryption, rate limiting, and auditing and logging. |
| 102 | + |
| 103 | +[id="about-technology"] |
| 104 | +== About the technology |
| 105 | + |
| 106 | +The following technologies are used in this solution: |
| 107 | + |
| 108 | +* *Zero Trust Workload Identity Manager*: Implements workload identity using SPIFFE/SPIRE. |
| 109 | +* *HashiCorp Vault*: Provides secure secret storage and management. |
| 110 | +* *Red{nbsp}Hat build of Keycloak (RHBK)*: Manages identity and access for users and services. |
| 111 | +* *{rh-gitops}*: A GitOps continuous delivery (CD) solution based on ArgoCD |
| 112 | +* *OpenShift Cert Manager*: Manages the lifecycle of certificates for secure communication. |
| 113 | +* *External Secrets Operator*: Synchronizes secrets from external systems into the cluster. |
| 114 | +* *Compliance Operator*: Provides ability to scan and remediate cluster hardening based on profiles |
| 115 | +* *QTodo application*: Serves as a sample Quarkus-based application to show zero trust principles. |
| 116 | +* *PostgreSQL database*: Provides the backend database for the demonstration application. |
0 commit comments