This document describes how to configure Knative serving and its major
components following security best practices.

## Securing Knative serving

Knative serving is based on the open source
[Knative](https://knative.dev/) project, and inherits its
security posture.

Workloads running on Knative serving share the same network and compute nodes.
You should create separate clusters for workloads that don't have mutual trust.
Knative serving clusters should not run unrelated workloads like CI/CD
infrastructure or databases.

Reasons to create multiple clusters for Knative serving workloads include:

- Separating development from production environments.
- Isolating applications owned by different teams.
- Isolating highly privileged workloads.

Once you've designed your clusters, take the following actions to help secure them:

- [Restrict access to your cluster](https://docs.cloud.google.com/kubernetes-engine/enterprise/knative-serving/docs/securing/managing-access.md.txt).
- [Understand the Knative threat model](https://github.com/knative/community/blob/main/working-groups/security/threat-model.md).
- [Read the Knative security reference if you plan to use community supported tooling](https://knative.dev/docs/reference/security/).

## Securing components

You are responsible for securing components that aren't [part of Knative serving](https://docs.cloud.google.com/kubernetes-engine/enterprise/knative-serving/docs/architecture-overview.md.txt#components_in_the_default_installation).

### Cloud Service Mesh

Knative serving relies on
[Cloud Service Mesh for routing traffic](https://docs.cloud.google.com/kubernetes-engine/enterprise/knative-serving/docs/architecture-overview.md.txt#components_in_the_default_installation).

Use the following guides to help you secure Cloud Service Mesh:

- [Cloud Service Mesh security overview and features](https://docs.cloud.google.com/service-mesh/docs/security/security-overview.md.txt).
- [Cloud Service Mesh security best practices](https://docs.cloud.google.com/service-mesh/docs/security/best-practices.md.txt).

### Google Kubernetes Engine

Knative serving uses Google Kubernetes Engine (GKE) to schedule workloads.
Take the following actions to help you secure your clusters:

- [Follow the GKE Enterprise security tutorial](https://docs.cloud.google.com/anthos/docs/tutorials/security).
- [Understand the Google Kubernetes Engine multi-tenancy model](https://docs.cloud.google.com/kubernetes-engine/docs/concepts/multitenancy-overview.md.txt).
- [Follow the Google Kubernetes Engine cluster hardening guide](https://docs.cloud.google.com/kubernetes-engine/docs/how-to/hardening-your-cluster.md.txt).
- [Understand the Google Kubernetes Engine shared responsibility model](https://docs.cloud.google.com/kubernetes-engine/docs/concepts/shared-responsibility.md.txt).

## Known vulnerabilities

You should subscribe to the security bulletins for Knative serving dependencies
so you can keep up-to-date with known vulnerabilities:

- [Cloud Service Mesh security bulletins](https://docs.cloud.google.com/service-mesh/docs/security-bulletins.md.txt).
- [GKE Enterprise security bulletins](https://docs.cloud.google.com/kubernetes-engine/security-bulletins.md.txt).