Update notary server related info. (#63)

This commit is contained in:
Christopher Chong
2024-02-15 11:28:57 +03:00
committed by GitHub
parent b2c7047ed4
commit c62299175f
2 changed files with 20 additions and 12 deletions

View File

@@ -7,14 +7,14 @@ All the following settings can be configured in the [config file](https://github
1. Before running a notary server you need the following files. The default dummy fixtures are for testing only and should never be used in production.
| File | Purpose | File Type | Compulsory to change |
----- | ------- | ------------------ | -------------------- |
| TLS private key | The private key used for the notary server's TLS certificate to establish TLS connections with provers | TLS private key in PEM format | Yes unless TLS is turned off |
| TLS certificate | The notary server's TLS certificate to establish TLS connections with provers | TLS certificate in PEM format | Yes unless TLS is turned off |
| Notary signature private key | The private key used for the notary server's signature on the generated transcript of the TLS sessions with provers | A P256 elliptic curve private key in PEM format | Yes |
| Notary signature public key | The public key used for the notary server's signature on the generated transcript of the TLS sessions with provers | A matching public key in PEM format | Yes |
| File | Purpose | File Type | Compulsory to change | Sample Command |
----- | ------- | ------------------ | -------------------- | ------------- |
| TLS private key | The private key used for the notary server's TLS certificate to establish TLS connections with provers | TLS private key in PEM format | Yes unless TLS is turned off | <Generated when creating CSR for your Certificate Authority, e.g. using [Certbot](https://certbot.eff.org/)> |
| TLS certificate | The notary server's TLS certificate to establish TLS connections with provers | TLS certificate in PEM format | Yes unless TLS is turned off | <Obtained from your Certificate Authority, e.g. [Let's Encrypt](https://letsencrypt.org/)> |
| Notary signature private key | The private key used for the notary server's signature on the generated transcript of the TLS sessions with provers | A P256 elliptic curve private key in PKCS#8 PEM format | Yes | `openssl genpkey -algorithm EC -out eckey.pem -pkeyopt ec_paramgen_curve:P-256 -pkeyopt ec_param_enc:named_curve` |
| Notary signature public key | The public key used for the notary server's signature on the generated transcript of the TLS sessions with provers | A matching public key in PEM format | Yes | `openssl ec -in eckey.pem -pubout -out eckey.pub` |
2. Expose the notary server port (specified in the config file) on your server networking setting
3. Optionally one can turn on [authorization](https://github.com/tlsnotary/tlsn/tree/dev/notary-server#authorization), or turn off [TLS](https://github.com/tlsnotary/tlsn/tree/dev/notary-server#optional-tls) if TLS is handled by an external setup
3. Optionally one can turn on [authorization](https://github.com/tlsnotary/tlsn/tree/dev/notary-server#authorization), or turn off [TLS](https://github.com/tlsnotary/tlsn/tree/dev/notary-server#optional-tls) if TLS is handled by an external setup, e.g. reverse proxy, cloud setup
## Using Cargo
@@ -34,7 +34,7 @@ source ~/.cargo/env
mkdir ~/src; cd ~/src
git clone https://github.com/tlsnotary/tlsn.git
```
4. Switch to your desired [released version](https://github.com/tlsnotary/tlsn/releases), or stay in the `dev` branch to use the latest code, e.g.
4. Switch to your desired [released version](https://github.com/tlsnotary/tlsn/releases), or stay in the `dev` branch to use the latest code (⚠️ only prover of the same version is supported for now)
```bash
git checkout tags/<version>
```
@@ -49,7 +49,10 @@ cargo run --release
1. Install docker following your preferred method [here](https://docs.docker.com/engine/install/ubuntu/)
2. To configure the [server setting](#configure-server-setting), please refer to the `Using Docker` section in the repo's [readme](https://github.com/tlsnotary/tlsn/blob/dev/notary-server/README.md#using-docker)
3. Run the notary server docker image of your desired version
3. Run the notary server docker image of your desired version (⚠️ only prover of the same version is supported for now)
```bash
docker run --init -p 127.0.0.1:7047:7047 ghcr.io/tlsnotary/tlsn/notary-server:<version>
```
## API Endpoints
Please refer to the list of all API endpoints [here](https://github.com/tlsnotary/tlsn/tree/dev/notary-server#api).

View File

@@ -67,10 +67,15 @@ If you plan to run a local notary server:
```
2. Edit the notary server config file (`notary-server/config/config.yaml`) to turn off TLS so that the browser extension can connect to the local notary server without requiring extra steps to accept self-signed certificates in the browser.
```yaml
tls-signature:
enabled: false
tls:
enabled: false
...
```
3. Run the notary server:
3. Switch to version `v0.1.0-alpha.3`
```bash
git checkout tags/v0.1.0-alpha.3
```
4. Run the notary server:
```shell
cd notary-server
cargo run --release