Skip to content

Commit 409c453

Browse files
committed
Update threat model with feedback from David Hadas
1 parent 2b7379b commit 409c453

File tree

1 file changed

+30
-25
lines changed

1 file changed

+30
-25
lines changed

docs/reference/security/threat-model.md

Lines changed: 30 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
11
# Knative Threat Model
22

3-
This document describes the Knative threat model. When vulnerabilities are
4-
reported to the project, we consult this document to determine whether the
5-
report describes a potential exploit, and if so to determine the severity of the
6-
exploit. As we develop new features, we consult this document to consider their
7-
impact on the threat model. Note that this threat model covers Serving,
8-
Eventing; some sections and threats may only apply to certain components of the
9-
project. As Knative Functions largely executes at build time on the application
10-
developer's infrastructure, it needs a different threat model more focused on
11-
supply chain security threats (which it largely inherits from
12-
[CNCF Buildpacks](https://buildpacks.io/)).
3+
Knative aims to support application teams from a single organization working in
4+
shared clusters under the
5+
[Namespace-as-a-Service multi-tenancy model](https://kubernetes.io/blog/2021/04/15/three-tenancy-models-for-kubernetes/),
6+
as well as the Cluster-as-a-Service model. The Namespace-as-a-Service model
7+
means that multiple teams (tenants) may each be operating Knative custom
8+
resources within a common cluster, sharing control plane and node resources.
9+
Each team (users in a namespace) should be isolated from affecting the
10+
configuration, availability, or integrity of applications in other namespaces.
11+
Knative is not specifically designed for use in a multi-cluster or cross-cluster
12+
scenario; there may be additional risks when attempting to span a _single_
13+
Knative installation across multiple clusters, but this threat model should be
14+
sufficient if each cluster in such a scenario is running an _independent_
15+
installation of Knative components (either some or all components).
1316

1417
Knative builds on the capabilities of the Kubernetes cluster, and exposes both
1518
Kubernetes control-plane resources (CRDs managed by Kubernetes RBAC) as well as
@@ -26,17 +29,7 @@ workloads. Cases where additional care is required in security workloads (for
2629
example, Knative Serving routes and Kubernetes NetworkPolicy) will be called
2730
out.
2831

29-
Knative aims to support application teams from a single organization working in
30-
shared clusters under the
31-
[Namespace-as-a-Service multi-tenancy model](https://kubernetes.io/blog/2021/04/15/three-tenancy-models-for-kubernetes/),
32-
as well as the Cluster-as-a-Service model. The Namespace-as-a-Service model
33-
means that multiple teams (tenants) may each be operating Knative custom
34-
resources within a common cluster, sharing control plane and node resources.
35-
Knative is not specifically designed for use in a multi-cluster or cross-cluster
36-
scenario; there may be additional risks when attempting to span a _single_
37-
Knative installation across multiple clusters, but this threat model should be
38-
sufficient if each cluster in such a scenario is running an _independent_
39-
installation of Knative components (either some or all components).
32+
4033

4134
## Terminology
4235

@@ -61,7 +54,7 @@ installation of Knative components (either some or all components).
6154
| External Event Source Admins | Users with the ability to configure and manage an external resource which is used as an event source, but without direct authenticated access to the cluster. |
6255
| Malicious Container / Supply Chain Attack | Users with the ability to tamper with a container image which is run by an internal user, but without authenticated access to the cluster. |
6356

64-
## Component Archicture
57+
## Component Architecture
6558

6659
### Eventing
6760

@@ -115,7 +108,7 @@ underlying software. The ingress gateway implementation is generally
115108
multi-tenant in nature and shared across the cluster, though the Knative
116109
architecture does not require this.
117110

118-
### Activator
111+
#### Activator
119112

120113
The activator component is a shared (multi-tenant) data-plane component used by
121114
Knative to handle HTTP requests when there is no current user pod available to
@@ -126,7 +119,7 @@ activator -- when a particular revision has sufficent replicas to handle bursty
126119
traffic, the ingress gateway is programmed with the direct backend addresses of
127120
the application pods.
128121

129-
### Autoscaler
122+
#### Autoscaler
130123

131124
The autoscaler is a control-plane component which tracks the current number of
132125
requests and requests / second for each Knative revision, and adjusts the
@@ -136,7 +129,7 @@ measurements from the activator and queue proxies, computes desired number of
136129
pods for each revision, and then updates the desired number of deployment
137130
replicas on the Kubernetes apiserver.
138131

139-
### Queue-Proxy
132+
#### Queue-Proxy
140133

141134
The queue-proxy runs as a sidecar alongside each user container (in the same
142135
Pod). The queue-proxy is responsible for measuring request load on the specific
@@ -371,3 +364,15 @@ validating the SLSA security guarantees with respect to ephemeral and
371364
reproducible builds.
372365

373366
**Mitigates**: system code execution
367+
368+
## Usage of this document
369+
370+
When vulnerabilities are reported to the project, we consult this document to
371+
determine whether the report describes a potential exploit, and if so to
372+
determine the severity of the exploit. As we develop new features, we consult
373+
this document to consider their impact on the threat model. Note that this
374+
threat model covers Serving andEventing; some sections and threats may only
375+
apply to certain components of the project. As Knative Functions largely
376+
executes at build time on the application developer's infrastructure, it
377+
needs a different threat model more focused on supply chain security threats
378+
(which it largely inherits from [CNCF Buildpacks](https://buildpacks.io/)).

0 commit comments

Comments
 (0)