Skip to content

Commit 96cade7

Browse files
authored
Brush over verification documentation (#560)
* Clarify verification workflow and `--era-config` flag description. * Remove section on ERA
1 parent 301d462 commit 96cade7

File tree

2 files changed

+18
-33
lines changed

2 files changed

+18
-33
lines changed

cli/cmd/root.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ To install and configure MarbleRun, run:
6363
rootCmd.AddCommand(cmd.NewVersionCmd())
6464

6565
rootCmd.PersistentFlags().String("coordinator-cert", defaultCoordinatorCertCache, "Path to MarbleRun Coordinator's root certificate to use for TLS connections")
66-
rootCmd.PersistentFlags().String("era-config", "", "Path to remote attestation config file in json format, if none provided the newest configuration will be loaded from github")
66+
rootCmd.PersistentFlags().String("era-config", "", "Path to a remote-attestation config file in JSON format. If none is provided, the command attempts to use './coordinator-era.json'. If that does not exist, the command will attempt to load a matching config file from the MarbleRun GitHub repository")
6767
rootCmd.PersistentFlags().BoolP("insecure", "i", false, "Set to skip quote verification, needed when running in simulation mode")
6868
rootCmd.PersistentFlags().StringSlice("accepted-tcb-statuses", []string{"UpToDate"}, "Comma-separated list of user accepted TCB statuses (e.g. ConfigurationNeeded,ConfigurationAndSWHardeningNeeded)")
6969
rootCmd.PersistentFlags().StringP("namespace", "n", helm.Namespace, "Kubernetes namespace of the MarbleRun installation")

docs/docs/workflows/verification.md

+17-32
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,40 @@
11
# Verifying a deployment
22

3-
MarbleRun provides a simple HTTP REST API for clients to verify the confidentiality and integrity of the Coordinator and the deployed Marbles.
3+
The Coordinator provides an API for clients to verify the identity and integrity of the Coordinator itself and the deployed Marbles.
44

5-
## Requirements
5+
Specifically, the Coordinator exposes the `/quote` endpoint that returns a quote and a certificate chain consisting of a root CA and an intermediate CA. The root CA is fixed for the lifetime of your deployment, while the intermediate CA changes in case you [update](../workflows/update-manifest.md) the packages specified in your manifest. The Coordinator also makes the effective manifest available via the `/manifest` endpoint. In TLS connections with this endpoint, the Coordinator uses its root CA and intermediate CA. Learn more about this concept in the [Attestation](../features/attestation.md) section.
66

7-
You need to [install and configure a quote provider](../getting-started/installation.md#install-the-marblerun-cli).
7+
## Verifying the quote and the manifest using the CLI
88

9-
## Establishing trust in the Coordinator
9+
The `marblerun manifest verify` command uses the two endpoints described above. It first verifies the Coordinator's quote according to a given policy and then checks that the expected `manifest.json` is in effect.
1010

11-
MarbleRun exposes the `/quote` endpoint that returns a quote and a certificate chain consisting of a root and intermediate CA. The root CA is fixed for the lifetime of your deployment, while the intermediate CA changes in case you [update](../workflows/update-manifest.md) the packages specified in your manifest.
12-
13-
The simplest way to verify the quote is via the Edgeless Remote Attestation ([era](https://github.com/edgelesssys/era)) tool.
14-
15-
To verify the coordinator, `era` requires the Coordinator's UniqueID (or MRENCLAVE in SGX terms) or the tuple ProductID, SecurityVersion, SignerID (MRSIGNER) to verify the quote. `era` contacts the Coordinator, and receives an SGX quote from it which contains the actual UniqueID or ProductID/SecurityVersion/SignerID tuple of the running instance. The tool verifies it against the expected values defined in `coordinator-era.json` and can therefore determine if an authentic copy of the Coordinator is running, or if an unknown version is contacted.
16-
17-
In production, the expected values in `coordinator-era.json` would be generated when building the Coordinator and distributed to your clients. When you build MarbleRun from source, you can find the file in your build directory.
18-
For testing with a pre-built release, there's a Coordinator image at `ghcr.io/edgelesssys/marblerun/coordinator`.
19-
You can pull the corresponding `coordinator-era.json` file from the release page:
20-
21-
```bash
22-
wget https://github.com/edgelesssys/marblerun/releases/latest/download/coordinator-era.json
23-
```
24-
25-
After installing `era`, you can verify the quote with the following command:
26-
27-
```bash
28-
era -c coordinator-era.json -h $MARBLERUN -output-chain marblerun-chain.pem -output-root marblerun-root.pem -output-intermediate marblerun-intermedite.pem
29-
```
11+
:::info
3012

31-
After successful verification, you'll have `marblerun-chain.pem`, `marblerun-root.pem`, and `marblerun-intermediate.pem` in your directory. In case you want to pin against specific versions of your application, using the intermediate CA as a trust anchor is a good choice. Else you can pin against the root CA in which case different versions of your application can talk with each other. However, you may not be able to launch them if they don't meet the minimum `SecurityVersion` specified in your original or updated manifest.
13+
You need to [install and configure a quote provider](../getting-started/installation.md#install-the-marblerun-cli) before you can use the command.
3214

33-
## Verifying the manifest
15+
:::
3416

35-
Establishing trust with the service mesh allows you to verify the deployed manifest in the second step.
36-
To that end, MarbleRun exposes the endpoint `/manifest`.
37-
Using the CLI, you can get the manifest's signature and compare it against your local version of the manifest which should have been provided to you by the operator.
17+
The policy includes the Coordinator's `UniqueID` or the tuple `ProductID`, `SecurityVersion`, and `SignerID`. `UniqueID` and `SignerID` are also known as `MRENCLAVE` and `MRSIGNER` in SGX terminology. The policy for a given Coordinator is generated at build time and written to a file named `coordinator-era.json`. This file ships with every release of MarbleRun. You can find the policy file for the latest MarbleRun release at `https://github.com/edgelesssys/marblerun/releases/latest/download/coordinator-era.json`
3818

39-
You can verify your local `manifest.json` against the Coordinator's version with the following command:
19+
The command is used as follows:
4020

4121
```bash
4222
marblerun manifest verify manifest.json $MARBLERUN
4323
```
4424

45-
If successful, the TLS root certificate of the Coordinator is saved for future connections with the MarbleRun instance.
46-
This ensures you are always talking to the same instance that you verified the manifest against.
25+
If successful, the certificates of the root CA and the intermediate CA are saved for future connections. This ensures you are always talking to the same verified instance.
4726

4827
:::info
4928

50-
By default `marblerun manifest verify` will save the Coordinators certificate chain to `$XDG_CONFIG_HOME/marblerun/coordinator-cert.pem`,
29+
By default, the command will save the Coordinators certificate chain to `$XDG_CONFIG_HOME/marblerun/coordinator-cert.pem`,
5130
or `$HOME/.config/marblerun/coordinator-cert.pem` if `$XDG_CONFIG_HOME` is not set.
5231
Subsequent CLI commands will try loading the certificate from that location.
5332
Use the `--coordinator-cert` flag to choose your own location to save or load the certificate.
5433

5534
:::
35+
36+
:::info
37+
38+
The flag `--era-config` lets you optionally specify a custom policy for the verification of the quote. See the [documentation of the command](../reference/cli.md#marblerun-manifest-verify) for details.
39+
40+
:::

0 commit comments

Comments
 (0)