BT

InfoQ Homepage News Open Policy Agent Graduates at CNCF

Open Policy Agent Graduates at CNCF

Bookmarks

The CNCF announced the graduation of the Open Policy Agent (OPA) project. OPA is an open source policy management and enforcement engine that has declarative policies and integrates with various systems including Kubernetes.

Originally created at Styra, OPA joined the CNCF as a sandbox project in march 2018, and was accepted as an incubation project in April 2020. Current contributors include Google, Microsoft, VMware, and Styra. OPA went through the standard CNCF graduating process - it was certified for the CII Best Practices Badge, completed multiple security audits, addressed discovered vulnerabilities, defined its governance process and adopted the CNCF Code of Conduct. It also completed a SIG-Security assessment during its incubation period.

OPA's goals are to decouple policy from the code, unify policy enforcement, and enable policy-as-code. OPA uses a DSL called Rego to describe its policies. An OPA engine can run as a library, sidecar or daemon with the application. OPA policies can be updated dynamically by polling a Bundle service API to download "bundles" - a collection of policies and data.

OPA integrates with various systems including Kubernetes, Envoy, CoreDNS, Kafka and Helm. There is also first-class integration between OPA and Kubernetes now with the OPA Gatekeeper which provides Kubernetes-native CRDs for working with the policy library. This supports "Constraints" - a set of declarations "that wants a system to meet a given set of requirements".

Chris Aniszczyk, CTO of the Cloud Native Computing Foundation, noted:

Since joining CNCF, OPA has expanded to integrate closer with Kubernetes via the Gatekeeper project but also supports a wide variety of use cases outside of Kubernetes.

In the Kubernetes ecosystem, OPA can register as a custom admission controller. It can be used to deny certain configurations like restrict the service type, whitelist or blacklist containers registries, and perform domain validation in ingress declarations.

OPA is used in production at many organizations including Goldman-Sachs, Netflix, Pinterest, and T-Mobile. The most common use cases according to a survey conducted in 2020 across 150 organizations are configuration authorization and API authorization. The survey also found that 56% use it in production for Kubernetes Admission Control and 47% use OPA in production for API authorization in microservices. CNCF hosts another policy engine called Kyverno - which uses JSON/YAML instead of a custom DSL. Although the SIG-security assessment cited earlier noted that Rego has a "non-trivial" learning curve, there are tools that use Rego to perform compliance checks like Regula and Preflight. There is an interactive playground for trying out Rego code.

The source code for OPA is available on GitHub.

 

Rate this Article

Adoption
Style

Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Community comments

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

BT

Is your profile up-to-date? Please take a moment to review and update.

Note: If updating/changing your email, a validation request will be sent

Company name:
Company role:
Company size:
Country/Zone:
State/Province/Region:
You will be sent an email to validate the new email address. This pop-up will close itself in a few moments.