diff --git a/TODO.md b/TODO.md index 6f904d9..d7640ae 100644 --- a/TODO.md +++ b/TODO.md @@ -1,8 +1,8 @@ TODO: * Design/Styling -* drawio/svg cleanup +* ~~drawio/svg cleanup~~ * use cases -* math in SVGs +* ~~math in SVGs~~ (Needed an update of local drawio) * social card * review * deployment flow @@ -11,7 +11,7 @@ TODO: * README * Matomo tracking: https://github.com/karser/docusaurus-plugin-matomo/tree/main ? * check links -* dark/light theme diagrams +* ~~dark/light theme diagrams~~ * rename repo landing-page -> website * archive old documentation website * What to do with drafts etc? \ No newline at end of file diff --git a/diagrams/client-state-diagram.drawio b/diagrams/client-state-diagram.drawio new file mode 100644 index 0000000..79194e3 --- /dev/null +++ b/diagrams/client-state-diagram.drawio @@ -0,0 +1 @@ +7Vxbd5s4EP41fmyOuQjDY+q4zW67m54kp00fCcg2W4wcIcf2/voVRtxxInvBAz04D0EjCcsz+uYijTTSpqvdZ2qvl38RF/sjdezuRtrNSOUfZPF/EWUfUxR1YsaUBfVcQcsID96/WBDHgrrxXBwWGjJCfOati0SHBAF2WIFmU0q2xWZz4he/dW0vcIXw4Nh+lfrDc9lSUCfjcVZxi73FMvlqJalZ2UlrQQiXtku2OZI2G2lTSgiLn1a7KfYj9iWMift9OlKbjozigMl0+LJEn9HDt/CH+efLbGuZ1tP94wdFE4Nj++QnY5dzQBQJZUuyIIHtzzLqR2dDX3H0VoUXKNkE7qE05qWsw1dC1qLJP5ixvZCtvWGEk5Zs5YtavPPYU+75Z/SqKyRKNzvx5kNhnxQCRvdP+UKuV1TMuh1KSb/4x0a/8CgTBSkkG+rgtzgnZqNNF5i90Q6louYowWSF+Xh4P4p9m3mvxXHYYrYu0naZPPmDEOkp4tUH8bYrXh1UvPF7X21/I77pj8Bjnu1zYbgVyWeijGSxXXoMP6ztAxe2XH0XxTb3fH9KfEIPfbU5iv4iOglYjh5/OD1klPzCuRrj8EmF8oopw7u3xVJlo+igCxUqrAhKdOw2U8mmIC1zyjihNc93pcLcAVZSsNIl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diDx+jYVVIn4uc7pt5830P4lANSeJMlf4qmlbWyi3DdMktc14G5blTtyBtsHb/PVtc+rNBUeRxEu/XNHJkvrTcqkyoTJ3oNF1NuN8/G6gJ779iIanITFdW6LB/VGj4K+CfoTwjRdVAFDhsvG5JUfAgPNvKaN1DV9S7uJupTNfL1QbnSktfx8cZvLH4LJ+e+uSRSznxWlFtRewhh1cjP9r1FwIsOFxbm9I+RKLmN8a9Fxcpz3YOHUDdRilOpMFea8KzK+Kq58kqpxVdr06JqrVueFuowLSq2qzQtzBq129S04MXsevX4consmnpt9h8= \ No newline at end of file diff --git a/diagrams/convert_all.sh b/diagrams/convert_all.sh new file mode 100755 index 0000000..c68ce71 --- /dev/null +++ b/diagrams/convert_all.sh @@ -0,0 +1,35 @@ +#!/bin/bash + +FORMAT="svg" + +# Convert all diagrams in the diagrams folder to pngs in the mdbook src/png-diagrams folder +SOURCE_DIR=$(dirname "$0") +TARGET_DIR=$(realpath "$(dirname "$0")/") + +OS=$(uname) +case "$OS" in +"Darwin") # Mac + DRAW_IO="/Applications/draw.io.app/Contents/MacOS/draw.io" + ;; +"Linux") # Linux + DRAW_IO="drawio" + ;; +esac + +if ! command -v "$DRAW_IO" &>/dev/null; then + echo "Error: draw.io executable not found. Please install draw.io and make sure it's in your PATH." + exit 1 +fi + +pushd "$SOURCE_DIR" >/dev/null +for file in *.drawio; do + for theme in "dark" "light"; do + SOURCE="$file" + TARGET="${TARGET_DIR}/${theme}/${file%.drawio}.${FORMAT}" + # Only convert if the source is more recent than the target + if [[ "$SOURCE" -nt "${TARGET}" ]]; then + "$DRAW_IO" --export --format ${FORMAT} --scale 2.5 --svg-theme "${theme}" -o "${TARGET}" "$SOURCE" + fi + done +done +popd >/dev/null diff --git a/diagrams/crate_structure.drawio b/diagrams/crate_structure.drawio new file mode 100644 index 0000000..16c244e --- /dev/null +++ b/diagrams/crate_structure.drawio @@ -0,0 +1 @@ +5VrbcpswEP0aP6YDAmL7Mc2lmbaZtpN0EvelI4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Mkbzaya3Mz6prfgrYMuJbPqulFWk0nlE+8+/32ZuDlzd87EjZAXlNwnHP/NsJS8etovX8m3v4x0/9DbN2rVneU5UatXRznfSHrcJR6qcw3F2xl0rlOwUhb8z0V66/Cd5qh4R/yaTmNN7MYTAu0OZPfvLXo5kd2SrBrgW1fx5z2RbcQ6U/wjkQa9n333i/TpTiJrkOam/P93SX2T/79Ru/0L \ No newline at end of file diff --git a/diagrams/dark/client-state-diagram.svg b/diagrams/dark/client-state-diagram.svg new file mode 100644 index 0000000..b8ab3b8 --- /dev/null +++ b/diagrams/dark/client-state-diagram.svg @@ -0,0 +1,3 @@ + + +
Initialized
ExpectServer
Hello
ExpectServer
HelloOrHello
RetryRequest
Complete
ServerHello
Handling
Expect
Encrypted
Extensions
Expect
Certificate
Expect
ServerKx
Expect
Certificate
StatusOr
ServerKx
Expect
Certificate
Status
Expect
ServerDone
OrCertReq
Expect
Certificate
Request
ExpectServer
Done
ExpectNew
Ticket
ExpectCcs
Expect
Finished
Expect
Traffic
Expect
Finished
Expect
Certificate
OrCertReq
Expect
Certificate
Expect
Certificate
Request
Expect
Certificate
Verify
Expect
Traffic
TLS1.3
TLS1.2
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/crate_structure.svg b/diagrams/dark/crate_structure.svg new file mode 100644 index 0000000..7fe8a0c --- /dev/null +++ b/diagrams/dark/crate_structure.svg @@ -0,0 +1,3 @@ + + +
mpc-core
mpc-aio
tls-aiotls-aio
tls-aio
mpc-circuits
utils-aio
prover
notary
core
tls-aiotls-aio
tls-client
tls-aiotls-aio
tls-core
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/data_provenance_none.svg b/diagrams/dark/data_provenance_none.svg new file mode 100644 index 0000000..0668256 --- /dev/null +++ b/diagrams/dark/data_provenance_none.svg @@ -0,0 +1,3 @@ + + +
No Data Provenance
Server
Alice
Bob
TLS

signed
data
⁉️
  • Origin ⁉️
  • Integrity ⁉️
  • Too much info ⁉️
🔐
signed
data
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/data_provenance_oauth.svg b/diagrams/dark/data_provenance_oauth.svg new file mode 100644 index 0000000..bcaf608 --- /dev/null +++ b/diagrams/dark/data_provenance_oauth.svg @@ -0,0 +1,3 @@ + + +
Status Quo 
  • Origin ✅
  • Integrity ✅
  • Too much info ⁉️
Server
TLS
Alice
Bob
grant access
to Bob
delegate
access control
OAuth
Server
  • censoring possible ⁉️
  • sees all requests ⁉️
🔐
signed
data
access token
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/data_provenance_tlsn.svg b/diagrams/dark/data_provenance_tlsn.svg new file mode 100644 index 0000000..63277f8 --- /dev/null +++ b/diagrams/dark/data_provenance_tlsn.svg @@ -0,0 +1,3 @@ + + +
TLSNotary
Server
Prover
Alice
Verifier
Bob
Selective disclosure
🔐
signed
data
🔐redacted
signed
data
  • Origin ✅
  • Integrity ✅
  • Only required info ✅
MPC-TLS
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/data_provenance_ultimate.svg b/diagrams/dark/data_provenance_ultimate.svg new file mode 100644 index 0000000..e51fe31 --- /dev/null +++ b/diagrams/dark/data_provenance_ultimate.svg @@ -0,0 +1,3 @@ + + +
Ultimate solution
Server
Alice
Bob
ZKP
Improved TLS
🔐
signed
data
🔐redacted
signed
data
  • Authenticity ✅
  • Integrity ✅
  • Only required info ✅
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/encoding_commitment.svg b/diagrams/dark/encoding_commitment.svg new file mode 100644 index 0000000..ce5c26f --- /dev/null +++ b/diagrams/dark/encoding_commitment.svg @@ -0,0 +1,3 @@ + + +
0
1
1
0
1
0
0
0
0
1
1
0
1
0
1
0
Full
Encoding
1
0
Data
Active
Encoding
Full
Encoding
Purported
Data
Active
Encoding
Notary generates full encoding using a PRG
Prover only knows the active encoding during commitment
Prover hashes the active encoding and commits to it in the merkle tree
H(
)
H(
)
Prover sends purported data to the Verifier
Verifier checks Notary signature of PRG seed, and regenerates full encodings
Verifier selects active encoding for the purported data
Verifier computes hash of the active encoding
UTF-8: 'h' -> 01101000
Commits
UTF-8: 'j' -> 01101010
☢️ Flipped bit
Prover can not create a merkle proof with this hash in the tree, because he did not know
when committing. He only knew the authentic encoding
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/gc-types.svg b/diagrams/dark/gc-types.svg new file mode 100644 index 0000000..afb4d90 --- /dev/null +++ b/diagrams/dark/gc-types.svg @@ -0,0 +1,3 @@ + + +
Input A
Input B
WireGroup
0
1
1
0
1
1
0
0
Value
WireLabel
Labels<Input, Active>
Labels<Input, Full>
LabelsSet<Input, Full>
LabelsSet<Input, Active>
WireLabelPair
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/intro-diagram.svg b/diagrams/dark/intro-diagram.svg new file mode 100644 index 0000000..98afb19 --- /dev/null +++ b/diagrams/dark/intro-diagram.svg @@ -0,0 +1,3 @@ + + +
TLSNotary Protocol Overview
Web Server
User
Notary
Notary Public Key Share
Combined PK =
User Public Key Share +
Notary Public Key Share
Web Server Public Key
Web Server Public Key
Key Exchange
Point Addition
PMSLabel
Computation
Session Key Derivation
Master Key
Session Key
Encrypt Request
Encrypt
Compute MAC
PMS EC Additive Share
Decrypt Response
Decrypt
Verify MAC
PMS EC Additive Share
Encoded PMS
Encoded PMS
Encoded PMS
Encoded PMS
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encrypted Request
Request
Encrypted Request
Encoded Session Keys
Response
Encrypted Response
Encrypted Response
Encoded Session Keys
Encrypted Request
Encrypted Response
Sign Transcript
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/key_exchange.svg b/diagrams/dark/key_exchange.svg new file mode 100644 index 0000000..6ab3cae --- /dev/null +++ b/diagrams/dark/key_exchange.svg @@ -0,0 +1,3 @@ + + +
Prover
Server
Verifier
(Notary)
Server
Public Key
Server
Public Key
Verifier
Public Key
Verifier
Public Key
Prover Public
Key
Secure 2PC
PMS Key Share
PMS Key Share
Prover
Private Key
Verifier
Private Key
PMS Key
+
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/mpc-decryption.svg b/diagrams/dark/mpc-decryption.svg new file mode 100644 index 0000000..84a36b0 --- /dev/null +++ b/diagrams/dark/mpc-decryption.svg @@ -0,0 +1,3 @@ + + +
Key share
Plaintext
Prover
Decrypt
Key share
Verifier
Ciphertext
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/mpc-encryption.svg b/diagrams/dark/mpc-encryption.svg new file mode 100644 index 0000000..f012a6f --- /dev/null +++ b/diagrams/dark/mpc-encryption.svg @@ -0,0 +1,3 @@ + + +
Key share
Plaintext
Prover
Encrypt
Key share
Verifier
Ciphertext
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/overview.svg b/diagrams/dark/overview.svg new file mode 100644 index 0000000..c53969e --- /dev/null +++ b/diagrams/dark/overview.svg @@ -0,0 +1,3 @@ + + +
Selective Disclosure Phase
ZK Proof
Verifier
User
Notarized Transcript
Transcript
1010101010101
0101
010101010
1010101110101
Encrypted Data
Signature
Metadata
0
Server
User
Notary
Notarization Phase
Notarized Transcript
Transcript
1010101010101
0101010101010
1010101110101
Encrypted Data
Signature
Metadata
Transcript
1010101010101
0101010101010
1010101110101
Encrypted Data
Notarize
Multi-party request
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/overview2.svg b/diagrams/dark/overview2.svg new file mode 100644 index 0000000..1c5a46e --- /dev/null +++ b/diagrams/dark/overview2.svg @@ -0,0 +1,3 @@ + + +
Server
encrypted data
Notary
User
signed data
Verifier
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/overview_notarization.svg b/diagrams/dark/overview_notarization.svg new file mode 100644 index 0000000..e52cc89 --- /dev/null +++ b/diagrams/dark/overview_notarization.svg @@ -0,0 +1,3 @@ + + +
User
Server
Notary
public key
public key
public key
Multi-party
request
Multi-party
key exchange
encrypted request
encrypted response
Notarize

combined public key

Session Key
Session Key Share
Session Key Share
encrypted
response
notarized
transcript
request
Request
Notarize
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/overview_notary.svg b/diagrams/dark/overview_notary.svg new file mode 100644 index 0000000..eceb5a6 --- /dev/null +++ b/diagrams/dark/overview_notary.svg @@ -0,0 +1,3 @@ + + +
Prover
Server
Notary
blindly
signed
data
Verifier
TLS
notarize
redacted signed
data
selective disclosure
Multi party computation
1
2
3
4
verify
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/overview_prover_verifier.svg b/diagrams/dark/overview_prover_verifier.svg new file mode 100644 index 0000000..7ca4363 --- /dev/null +++ b/diagrams/dark/overview_prover_verifier.svg @@ -0,0 +1,3 @@ + + +
Prover
Server
Verifier
TLS
MPC-TLS
1
3
2
Verify
Selective disclosure
1
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/protocol.svg b/diagrams/dark/protocol.svg new file mode 100644 index 0000000..9892481 --- /dev/null +++ b/diagrams/dark/protocol.svg @@ -0,0 +1,3 @@ + + +
Server
Prover
Verifier
Private Key
Private Key
PMS Share
PMS Share
Secret Share PMS
ClientHello
ServerHello
CF verify_data
TLS 1.2 - Single-round
ClientFinished
ServerFinished
ServerCertificate
ServerKeyExchange
ServerHelloDone
Notary Public Key
Server Public Key
ClientKeyExchange
PMS Share
PMS Share
Key Shares
Key Shares
Secret Share
Session Keys
(PRF)
Handshake Hash
Key Shares
CF verify_data
Key Shares
Compute
ClientFinished
verify_data
Key Shares
Key Shares
ClientFinished
Encrypt
ClientFinished
ClientCCS
ServerCCS
Key Shares
EncryptedRequest
Requ
Request
Key Shares
EncryptedRequest
Encrypt
EncryptedRequest
Response
Commitment
Generate
Commitment
EncryptedResponse
EncryptedResponse
MAC Key share
Verify
MACs
Key Shares
Decrypt
Encrypted
Response
Commitment
ClientCloseNotify
Verify
ServerFinished
Key Shares
Key Shares
SF verify_data
Handshake Hash
Compute
ServerFinished
verify_data
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/transcript.svg b/diagrams/dark/transcript.svg new file mode 100644 index 0000000..a1b5dfb --- /dev/null +++ b/diagrams/dark/transcript.svg @@ -0,0 +1,3 @@ + + +
Transcript
Commitments
0
1
2
3
ServerRandom
HandshakeData
ProtocolVersion
CipherSuite
CommitmentScheme
Header
Timestamp
SessionSecrets
ServerCertificate
ApplicationData
Email
Password
Request: Login
AccessToken
RefreshToken
Response: Success
UserId
Request: Get Profile
AccessToken
UserId
LegalName
Address
Response: Profile
UserId
ClientRandom
ServerEphemeralKey
NotarizedTranscript
NotarySignature
NotaryId
NotaryCertificate
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/dark/verification_example.svg b/diagrams/dark/verification_example.svg new file mode 100644 index 0000000..e099c35 --- /dev/null +++ b/diagrams/dark/verification_example.svg @@ -0,0 +1,3 @@ + + +
--- Request
GET /profile HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64)
Host: www.example.com
Accept-Language: en-us
Cookie: user_session=███████████████████████████████████████
Connection: Keep-Alive

--- Response
HTTP/1.1 200 OK
Date: Wed, 14 Jun 2023 16:10:53 GMT
Server: Apache/2.2.14 (Win32)
Last-Modified: Sat, 03 Jan 2009 19:15:56 GMT
Content-Length: 74
Content-Type: application/json
Connection: Closed

{"username":"john123","address":"█████████████████████████","birthday":"█████████████"}
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/data_provenance_none.drawio b/diagrams/data_provenance_none.drawio new file mode 100644 index 0000000..bb1428b --- /dev/null +++ b/diagrams/data_provenance_none.drawio @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/data_provenance_oauth.drawio b/diagrams/data_provenance_oauth.drawio new file mode 100644 index 0000000..24b6e22 --- /dev/null +++ b/diagrams/data_provenance_oauth.drawio @@ -0,0 +1,72 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/data_provenance_tlsn.drawio b/diagrams/data_provenance_tlsn.drawio new file mode 100644 index 0000000..2b00e26 --- /dev/null +++ b/diagrams/data_provenance_tlsn.drawio @@ -0,0 +1,49 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/data_provenance_ultimate.drawio b/diagrams/data_provenance_ultimate.drawio new file mode 100644 index 0000000..5711871 --- /dev/null +++ b/diagrams/data_provenance_ultimate.drawio @@ -0,0 +1,50 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/encoding_commitment.drawio b/diagrams/encoding_commitment.drawio new file mode 100644 index 0000000..bb8460d --- /dev/null +++ b/diagrams/encoding_commitment.drawio @@ -0,0 +1,351 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diagrams/gc-types.drawio b/diagrams/gc-types.drawio new file mode 100644 index 0000000..13219a7 --- /dev/null +++ b/diagrams/gc-types.drawio @@ -0,0 +1 @@ +7V1bc9o4FP41PDZjWb4+5tJ2d6edyUxmd5unjotVcGsQY0Qh++tXxrL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DLQPweaBB9sw0j4EnQoPtmGofQh7NjjYdTjzEvwI4N7k0NBpM4g9GxxsQ6fAIPZscLCPHDrRkPZsaLAjdc+uMnYe+EnsLWnH3fsjzUbNauIpXqcyUwlyXGaXlcysSC3Q/f1Lt1IzKMl4YYFf7bpBV46DW86bK4zDIw4c7ZNA6prB+v3jaFc/ePaKwcjUKVr9dSpUChnC8hMtX1sSgbD0B1NBKM105iSySE1saooL75OsGO4GEcnZIdDPEooMSuGGlYoZH1KsLy/R9SVZet2ySOc+uyzRvfohanVSVD1RiLoVnc4/9HtKWaNBnWc1aEuNh2017jnua9T4KZWyafJW9b/bYErZlVSp/9qCf0W9+/Kef+Y1Wd9Iv/PQ4rC9KYeRetKNu1Swsc5h1jtYEcKd4cqbBaVsf3WXf/L5maakHPE/ \ No newline at end of file diff --git a/diagrams/intro-diagram.drawio b/diagrams/intro-diagram.drawio new file mode 100644 index 0000000..58558be --- /dev/null +++ b/diagrams/intro-diagram.drawio @@ -0,0 +1,286 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diagrams/key_exchange.drawio b/diagrams/key_exchange.drawio new file mode 100644 index 0000000..e021416 --- /dev/null +++ b/diagrams/key_exchange.drawio @@ -0,0 +1,141 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diagrams/light/client-state-diagram.svg b/diagrams/light/client-state-diagram.svg new file mode 100644 index 0000000..d39fe2d --- /dev/null +++ b/diagrams/light/client-state-diagram.svg @@ -0,0 +1,3 @@ + + +
Initialized
ExpectServer
Hello
ExpectServer
HelloOrHello
RetryRequest
Complete
ServerHello
Handling
Expect
Encrypted
Extensions
Expect
Certificate
Expect
ServerKx
Expect
Certificate
StatusOr
ServerKx
Expect
Certificate
Status
Expect
ServerDone
OrCertReq
Expect
Certificate
Request
ExpectServer
Done
ExpectNew
Ticket
ExpectCcs
Expect
Finished
Expect
Traffic
Expect
Finished
Expect
Certificate
OrCertReq
Expect
Certificate
Expect
Certificate
Request
Expect
Certificate
Verify
Expect
Traffic
TLS1.3
TLS1.2
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/crate_structure.svg b/diagrams/light/crate_structure.svg new file mode 100644 index 0000000..ace0373 --- /dev/null +++ b/diagrams/light/crate_structure.svg @@ -0,0 +1,3 @@ + + +
mpc-core
mpc-aio
tls-aiotls-aio
tls-aio
mpc-circuits
utils-aio
prover
notary
core
tls-aiotls-aio
tls-client
tls-aiotls-aio
tls-core
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/data_provenance_none.svg b/diagrams/light/data_provenance_none.svg new file mode 100644 index 0000000..ce71eae --- /dev/null +++ b/diagrams/light/data_provenance_none.svg @@ -0,0 +1,3 @@ + + +
No Data Provenance
Server
Alice
Bob
TLS

signed
data
⁉️
  • Origin ⁉️
  • Integrity ⁉️
  • Too much info ⁉️
🔐
signed
data
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/data_provenance_oauth.svg b/diagrams/light/data_provenance_oauth.svg new file mode 100644 index 0000000..d833038 --- /dev/null +++ b/diagrams/light/data_provenance_oauth.svg @@ -0,0 +1,3 @@ + + +
Status Quo 
  • Origin ✅
  • Integrity ✅
  • Too much info ⁉️
Server
TLS
Alice
Bob
grant access
to Bob
delegate
access control
OAuth
Server
  • censoring possible ⁉️
  • sees all requests ⁉️
🔐
signed
data
access token
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/data_provenance_tlsn.svg b/diagrams/light/data_provenance_tlsn.svg new file mode 100644 index 0000000..b663b70 --- /dev/null +++ b/diagrams/light/data_provenance_tlsn.svg @@ -0,0 +1,3 @@ + + +
TLSNotary
Server
Prover
Alice
Verifier
Bob
Selective disclosure
🔐
signed
data
🔐redacted
signed
data
  • Origin ✅
  • Integrity ✅
  • Only required info ✅
MPC-TLS
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/data_provenance_ultimate.svg b/diagrams/light/data_provenance_ultimate.svg new file mode 100644 index 0000000..1d1d192 --- /dev/null +++ b/diagrams/light/data_provenance_ultimate.svg @@ -0,0 +1,3 @@ + + +
Ultimate solution
Server
Alice
Bob
ZKP
Improved TLS
🔐
signed
data
🔐redacted
signed
data
  • Authenticity ✅
  • Integrity ✅
  • Only required info ✅
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/encoding_commitment.svg b/diagrams/light/encoding_commitment.svg new file mode 100644 index 0000000..5d1b142 --- /dev/null +++ b/diagrams/light/encoding_commitment.svg @@ -0,0 +1,3 @@ + + +
0
1
1
0
1
0
0
0
0
1
1
0
1
0
1
0
Full
Encoding
1
0
Data
Active
Encoding
Full
Encoding
Purported
Data
Active
Encoding
Notary generates full encoding using a PRG
Prover only knows the active encoding during commitment
Prover hashes the active encoding and commits to it in the merkle tree
H(
)
H(
)
Prover sends purported data to the Verifier
Verifier checks Notary signature of PRG seed, and regenerates full encodings
Verifier selects active encoding for the purported data
Verifier computes hash of the active encoding
UTF-8: 'h' -> 01101000
Commits
UTF-8: 'j' -> 01101010
☢️ Flipped bit
Prover can not create a merkle proof with this hash in the tree, because he did not know
when committing. He only knew the authentic encoding
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/gc-types.svg b/diagrams/light/gc-types.svg new file mode 100644 index 0000000..e3776cc --- /dev/null +++ b/diagrams/light/gc-types.svg @@ -0,0 +1,3 @@ + + +
Input A
Input B
WireGroup
0
1
1
0
1
1
0
0
Value
WireLabel
Labels<Input, Active>
Labels<Input, Full>
LabelsSet<Input, Full>
LabelsSet<Input, Active>
WireLabelPair
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/intro-diagram.svg b/diagrams/light/intro-diagram.svg new file mode 100644 index 0000000..d131593 --- /dev/null +++ b/diagrams/light/intro-diagram.svg @@ -0,0 +1,3 @@ + + +
TLSNotary Protocol Overview
Web Server
User
Notary
Notary Public Key Share
Combined PK =
User Public Key Share +
Notary Public Key Share
Web Server Public Key
Web Server Public Key
Key Exchange
Point Addition
PMSLabel
Computation
Session Key Derivation
Master Key
Session Key
Encrypt Request
Encrypt
Compute MAC
PMS EC Additive Share
Decrypt Response
Decrypt
Verify MAC
PMS EC Additive Share
Encoded PMS
Encoded PMS
Encoded PMS
Encoded PMS
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encrypted Request
Request
Encrypted Request
Encoded Session Keys
Response
Encrypted Response
Encrypted Response
Encoded Session Keys
Encrypted Request
Encrypted Response
Sign Transcript
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/key_exchange.svg b/diagrams/light/key_exchange.svg new file mode 100644 index 0000000..efccd0a --- /dev/null +++ b/diagrams/light/key_exchange.svg @@ -0,0 +1,3 @@ + + +
Prover
Server
Verifier
(Notary)
Server
Public Key
Server
Public Key
Verifier
Public Key
Verifier
Public Key
Prover Public
Key
Secure 2PC
PMS Key Share
PMS Key Share
Prover
Private Key
Verifier
Private Key
PMS Key
+
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/mpc-decryption.svg b/diagrams/light/mpc-decryption.svg new file mode 100644 index 0000000..e2e45e7 --- /dev/null +++ b/diagrams/light/mpc-decryption.svg @@ -0,0 +1,3 @@ + + +
Key share
Plaintext
Prover
Decrypt
Key share
Verifier
Ciphertext
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/mpc-encryption.svg b/diagrams/light/mpc-encryption.svg new file mode 100644 index 0000000..309684c --- /dev/null +++ b/diagrams/light/mpc-encryption.svg @@ -0,0 +1,3 @@ + + +
Key share
Plaintext
Prover
Encrypt
Key share
Verifier
Ciphertext
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/overview.svg b/diagrams/light/overview.svg new file mode 100644 index 0000000..2078bca --- /dev/null +++ b/diagrams/light/overview.svg @@ -0,0 +1,3 @@ + + +
Selective Disclosure Phase
ZK Proof
Verifier
User
Notarized Transcript
Transcript
1010101010101
0101
010101010
1010101110101
Encrypted Data
Signature
Metadata
0
Server
User
Notary
Notarization Phase
Notarized Transcript
Transcript
1010101010101
0101010101010
1010101110101
Encrypted Data
Signature
Metadata
Transcript
1010101010101
0101010101010
1010101110101
Encrypted Data
Notarize
Multi-party request
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/overview2.svg b/diagrams/light/overview2.svg new file mode 100644 index 0000000..1895edb --- /dev/null +++ b/diagrams/light/overview2.svg @@ -0,0 +1,3 @@ + + +
Server
encrypted data
Notary
User
signed data
Verifier
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/overview_notarization.svg b/diagrams/light/overview_notarization.svg new file mode 100644 index 0000000..e56bebe --- /dev/null +++ b/diagrams/light/overview_notarization.svg @@ -0,0 +1,3 @@ + + +
User
Server
Notary
public key
public key
public key
Multi-party
request
Multi-party
key exchange
encrypted request
encrypted response
Notarize

combined public key

Session Key
Session Key Share
Session Key Share
encrypted
response
notarized
transcript
request
Request
Notarize
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/overview_notary.svg b/diagrams/light/overview_notary.svg new file mode 100644 index 0000000..a4d5a9e --- /dev/null +++ b/diagrams/light/overview_notary.svg @@ -0,0 +1,3 @@ + + +
Prover
Server
Notary
blindly
signed
data
Verifier
TLS
notarize
redacted signed
data
selective disclosure
Multi party computation
1
2
3
4
verify
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/overview_prover_verifier.svg b/diagrams/light/overview_prover_verifier.svg new file mode 100644 index 0000000..768f503 --- /dev/null +++ b/diagrams/light/overview_prover_verifier.svg @@ -0,0 +1,3 @@ + + +
Prover
Server
Verifier
TLS
MPC-TLS
1
3
2
Verify
Selective disclosure
1
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/protocol.svg b/diagrams/light/protocol.svg new file mode 100644 index 0000000..08326a0 --- /dev/null +++ b/diagrams/light/protocol.svg @@ -0,0 +1,3 @@ + + +
Server
Prover
Verifier
Private Key
Private Key
PMS Share
PMS Share
Secret Share PMS
ClientHello
ServerHello
CF verify_data
TLS 1.2 - Single-round
ClientFinished
ServerFinished
ServerCertificate
ServerKeyExchange
ServerHelloDone
Notary Public Key
Server Public Key
ClientKeyExchange
PMS Share
PMS Share
Key Shares
Key Shares
Secret Share
Session Keys
(PRF)
Handshake Hash
Key Shares
CF verify_data
Key Shares
Compute
ClientFinished
verify_data
Key Shares
Key Shares
ClientFinished
Encrypt
ClientFinished
ClientCCS
ServerCCS
Key Shares
EncryptedRequest
Requ
Request
Key Shares
EncryptedRequest
Encrypt
EncryptedRequest
Response
Commitment
Generate
Commitment
EncryptedResponse
EncryptedResponse
MAC Key share
Verify
MACs
Key Shares
Decrypt
Encrypted
Response
Commitment
ClientCloseNotify
Verify
ServerFinished
Key Shares
Key Shares
SF verify_data
Handshake Hash
Compute
ServerFinished
verify_data
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/transcript.svg b/diagrams/light/transcript.svg new file mode 100644 index 0000000..bbb3f6a --- /dev/null +++ b/diagrams/light/transcript.svg @@ -0,0 +1,3 @@ + + +
Transcript
Commitments
0
1
2
3
ServerRandom
HandshakeData
ProtocolVersion
CipherSuite
CommitmentScheme
Header
Timestamp
SessionSecrets
ServerCertificate
ApplicationData
Email
Password
Request: Login
AccessToken
RefreshToken
Response: Success
UserId
Request: Get Profile
AccessToken
UserId
LegalName
Address
Response: Profile
UserId
ClientRandom
ServerEphemeralKey
NotarizedTranscript
NotarySignature
NotaryId
NotaryCertificate
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/light/verification_example.svg b/diagrams/light/verification_example.svg new file mode 100644 index 0000000..2ccffc7 --- /dev/null +++ b/diagrams/light/verification_example.svg @@ -0,0 +1,3 @@ + + +
--- Request
GET /profile HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64)
Host: www.example.com
Accept-Language: en-us
Cookie: user_session=███████████████████████████████████████
Connection: Keep-Alive

--- Response
HTTP/1.1 200 OK
Date: Wed, 14 Jun 2023 16:10:53 GMT
Server: Apache/2.2.14 (Win32)
Last-Modified: Sat, 03 Jan 2009 19:15:56 GMT
Content-Length: 74
Content-Type: application/json
Connection: Closed

{"username":"john123","address":"█████████████████████████","birthday":"█████████████"}
Text is not SVG - cannot display
\ No newline at end of file diff --git a/diagrams/mpc-decryption.drawio b/diagrams/mpc-decryption.drawio new file mode 100644 index 0000000..630f8ac --- /dev/null +++ b/diagrams/mpc-decryption.drawio @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/mpc-encryption.drawio b/diagrams/mpc-encryption.drawio new file mode 100644 index 0000000..9302c6a --- /dev/null +++ b/diagrams/mpc-encryption.drawio @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/overview.drawio b/diagrams/overview.drawio new file mode 100644 index 0000000..3a1d097 --- /dev/null +++ b/diagrams/overview.drawio @@ -0,0 +1,203 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diagrams/overview2.drawio b/diagrams/overview2.drawio new file mode 100644 index 0000000..fb4597f --- /dev/null +++ b/diagrams/overview2.drawio @@ -0,0 +1,76 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diagrams/overview_notarization.drawio b/diagrams/overview_notarization.drawio new file mode 100644 index 0000000..ed0dbbc --- /dev/null +++ b/diagrams/overview_notarization.drawio @@ -0,0 +1,213 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diagrams/overview_notary.drawio b/diagrams/overview_notary.drawio new file mode 100644 index 0000000..30de856 --- /dev/null +++ b/diagrams/overview_notary.drawio @@ -0,0 +1,87 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/overview_prover_verifier.drawio b/diagrams/overview_prover_verifier.drawio new file mode 100644 index 0000000..d04f2f8 --- /dev/null +++ b/diagrams/overview_prover_verifier.drawio @@ -0,0 +1,65 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/protocol.drawio b/diagrams/protocol.drawio new file mode 100644 index 0000000..0932690 --- /dev/null +++ b/diagrams/protocol.drawio @@ -0,0 +1,1952 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/diagrams/transcript.drawio b/diagrams/transcript.drawio new file mode 100644 index 0000000..d8b4452 --- /dev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eRciKdLPUxEaAgDZaGzFA9eorSucksJBx8drz+qJSGvri0qS1AxrDlvJGeOfQ5frM4zIlPOH3vqvs3Oc21TlT0evfu2uk86TDmbu0YzGNzAQzesG7BDu/OUw1TkaJ5H1+Fx38DqPNswVflZMbPYrOS9XLJrIbz0P5SdZw2mnAP2dNmxOs8aTDnDGgeYT6ev505VJ3haPXdq7jqpexGnZ6AoDL6iVe9ws1Q7jTXhxpvbH5PJ9ne3v8kDLv4D \ No newline at end of file diff --git a/diagrams/verification_example.drawio b/diagrams/verification_example.drawio new file mode 100644 index 0000000..0e1a780 --- /dev/null +++ b/diagrams/verification_example.drawio @@ -0,0 +1,13 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/MPC/commitments.md b/docs/MPC/commitments.md index da885ce..eb7b6cb 100644 --- a/docs/MPC/commitments.md +++ b/docs/MPC/commitments.md @@ -11,5 +11,5 @@ The high-level idea is that the `Prover` creates a commitment to the active plai We also hide the amount of commitments (to preserve `Prover` privacy) by having the `Prover` commit to the Merkle tree of commitments. - -![Commitment](../diagrams/encoding_commitment.svg) \ No newline at end of file +![Commitment](../../diagrams/light/encoding_commitment.svg#gh-light-mode-only) +![Commitment](../../diagrams/dark/encoding_commitment.svg#gh-dark-mode-only) diff --git a/docs/Protocol/mpc-tls/encryption.md b/docs/Protocol/mpc-tls/encryption.md index 5b33d3f..5d9f712 100644 --- a/docs/Protocol/mpc-tls/encryption.md +++ b/docs/Protocol/mpc-tls/encryption.md @@ -11,7 +11,8 @@ This section explains how the `Prover` and `Verifier` use MPC to encrypt data se To encrypt the plaintext, both parties input their TLS key shares as private inputs to the [MPC](../../mpc/deap.md) protocol, along with some other public data. Additionally, the `Prover` inputs her plaintext as a private input. -![Encryption](../../diagrams/mpc-encryption.svg) +![Encryption](../../../diagrams/light/mpc-encryption.svg#gh-light-mode-only) +![Encryption](../../../diagrams/dark/mpc-encryption.svg#gh-dark-mode-only) Both parties see the resulting ciphertext and execute the [2PC MAC](../../mpc/mac.md) protocol to compute the MAC for the ciphertext. @@ -23,7 +24,8 @@ Once the `Prover` receives the ciphertext and its associated MAC from the server Next, the parties decrypt the ciphertext by providing their key shares as private inputs to the [MPC](../../mpc/deap.md) protocol, along with the ciphertext and some other public data. -![Decryption](../../diagrams/mpc-decryption.svg) +![Decryption](../../../diagrams/light/mpc-decryption.svg#gh-light-mode-only) +![Decryption](../../../diagrams/dark/mpc-decryption.svg#gh-dark-mode-only) The resulting plaintext is revealed ONLY to the `Prover`. diff --git a/docs/Protocol/mpc-tls/handshake.md b/docs/Protocol/mpc-tls/handshake.md index 92309d7..573b74d 100644 --- a/docs/Protocol/mpc-tls/handshake.md +++ b/docs/Protocol/mpc-tls/handshake.md @@ -4,7 +4,8 @@ sidebar_position: 1 # Handshake -![](../../diagrams/key_exchange.svg) +![Encryption](../../../diagrams/light/key_exchange.svg#gh-light-mode-only) +![Encryption](../../../diagrams/dark/key_exchange.svg#gh-dark-mode-only) A TLS handshake is the first step in establishing a TLS connection between a `Prover` and a `Server`. In TLSNotary the `Prover` is the one who starts the TLS handshake and physically communicates with the `Server`, but all cryptographic TLS operations are performed together with the `Verifier` using MPC. diff --git a/docs/Protocol/verification.md b/docs/Protocol/verification.md index bf6c4c7..da3b699 100644 --- a/docs/Protocol/verification.md +++ b/docs/Protocol/verification.md @@ -18,4 +18,4 @@ Next, the `Verifier` parses the `opening` with an application-specific parser (e Below is an example of a verification output for an HTTP 1.1 request and response. Note that since the `Prover` chose not to disclose some sensitive information like their HTTP session token and address, that information will be withheld from the `Verifier` and will appear to him as redacted (in red). -![Verification example](../diagrams/verification_example.svg) +![Verification example](../../diagrams/light/verification_example.svg) \ No newline at end of file diff --git a/docs/_spec/verification_steps.md b/docs/_spec/verification_steps.md index 5b3eaa1..e477a33 100644 --- a/docs/_spec/verification_steps.md +++ b/docs/_spec/verification_steps.md @@ -30,4 +30,4 @@ To summarize: the `Verifier` will only learn those portions of the TLS session t -![Verification example](../diagrams/verification_example.svg) +![](../../diagrams/light/verification_example.svg) \ No newline at end of file diff --git a/docs/diagrams/client-state-diagram.svg b/docs/diagrams/client-state-diagram.svg deleted file mode 100644 index 5716ba9..0000000 --- a/docs/diagrams/client-state-diagram.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Initialized
Initialized
ExpectServer
Hello
ExpectServer...
ExpectServer
HelloOrHello
RetryRequest
ExpectServer...
Complete
ServerHello
Handling
Complete...
Expect
Encrypted
Extensions
Expect...
Expect
Certificate
Expect...
Expect
ServerKx
Expect...
Expect
Certificate
StatusOr
ServerKx
Expect...
Expect
Certificate
Status
Expect...
Expect
ServerDone
OrCertReq
Expect...
Expect
Certificate
Request
Expect...
ExpectServer
Done
ExpectServer...
ExpectNew
Ticket
ExpectNew...
ExpectCcs
ExpectCcs
Expect
Finished
Expect...
Expect
Traffic
Expect...
Expect
Finished
Expect...
Expect
Certificate
OrCertReq
Expect...
Expect
Certificate
Expect...
Expect
Certificate
Request
Expect...
Expect
Certificate
Verify
Expect...
Expect
Traffic
Expect...
TLS1.3
TLS1.3
TLS1.2
TLS1.2
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/crate_structure.svg b/docs/diagrams/crate_structure.svg deleted file mode 100644 index 19883f7..0000000 --- a/docs/diagrams/crate_structure.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
mpc-core
mpc-core
mpc-aio
mpc-aio
tls-aiotls-aio
tls-aio
tls-aio
mpc-circuits
mpc-circuits
utils-aio
utils-aio
prover
prover
notary
notary
core
core
tls-aiotls-aio
tls-client
tls-client
tls-aiotls-aio
tls-core
tls-core
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/data_provenance_none.svg b/docs/diagrams/data_provenance_none.svg deleted file mode 100644 index d16e19d..0000000 --- a/docs/diagrams/data_provenance_none.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
No Data Provenance
No Data Provenance
Server
Server
Alice
Alice
Bob
Bob
TLS
TLS

signed
data
⁉️
signed...
  • Origin ⁉️
  • Integrity ⁉️
  • Too much info ⁉️
Origin ⁉️Integrity ⁉️Too m...
🔐
signed
data
🔐signed...
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/data_provenance_oauth.svg b/docs/diagrams/data_provenance_oauth.svg deleted file mode 100644 index 47008a8..0000000 --- a/docs/diagrams/data_provenance_oauth.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Status Quo 
Status Quo 
  • Origin ✅
  • Integrity ✅
  • Too much info ⁉️
Origin ✅Integrity ✅Too m...
Server
Server
TLS
TLS
Alice
Alice
Bob
Bob
grant access
to Bob
grant access...
delegate
access control
delegate...
OAuth
Server
OAuth...
  • censoring possible ⁉️
  • sees all requests ⁉️
censoring possible ⁉️sees...
🔐
signed
data
🔐signed...
access token
access token
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/data_provenance_tlsn.svg b/docs/diagrams/data_provenance_tlsn.svg deleted file mode 100644 index 29e7617..0000000 --- a/docs/diagrams/data_provenance_tlsn.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
TLSNotary
TLSNotary
Server
Server
Prover
Alice
Prover...
Verifier
Bob
Verifier...
Selective disclosure
Selective disclosure
🔐
signed
data
🔐signed...
🔐redacted
signed
data
🔐redacted...
  • Origin ✅
  • Integrity ✅
  • Only required info ✅
Origin ✅Integrity ✅Only requi...
MPC-TLS
MPC-TLS
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/data_provenance_ultimate.svg b/docs/diagrams/data_provenance_ultimate.svg deleted file mode 100644 index 3152cfa..0000000 --- a/docs/diagrams/data_provenance_ultimate.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Ultimate solution
Ultimate solution
Server
Server
Alice
Alice
Bob
Bob
ZKP
ZKP
Improved TLS
Improved TLS
🔐
signed
data
🔐signed...
🔐redacted
signed
data
🔐redacted...
  • Authenticity ✅
  • Integrity ✅
  • Only required info ✅
Authenticity ✅Integrity ✅Only...
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/encoding_commitment.svg b/docs/diagrams/encoding_commitment.svg deleted file mode 100644 index 09cb0b8..0000000 --- a/docs/diagrams/encoding_commitment.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
0
0
1
1
1
1
0
0
1
1
0
0
0
0
0
0
$$w_0^1$$
$$w_0^...
$$w_1^1$$
$$w_1^...
$$w_2^1$$
$$w_2^...
$$w_3^1$$
$$w_3^...
$$w_4^1$$
$$w_4^...
$$w_5^1$$
$$w_5^...
$$w_6^1$$
$$w_6^...
$$w_7^1$$
$$w_7^...
$$w_0^0$$
$$w_0^...
$$w_1^0$$
$$w_1^...
$$w_2^0$$
$$w_2^...
$$w_3^0$$
$$w_3^...
$$w_4^0$$
$$w_4^...
$$w_5^0$$
$$w_5^...
$$w_6^0$$
$$w_6^...
$$w_7^0$$
$$w_7^...
$$w_1^1$$
$$w_1^...
$$w_2^1$$
$$w_2^...
$$w_4^1$$
$$w_4^...
$$w_0^0$$
$$w_0^...
$$w_3^0$$
$$w_3^...
$$w_5^0$$
$$w_5^...
$$w_6^0$$
$$w_6^...
$$w_7^0$$
$$w_7^...
$$w_1^1$$
$$w_1^...
$$w_2^1$$
$$w_2^...
$$w_4^1$$
$$w_4^...
$$w_0^0$$
$$w_0^...
$$w_3^0$$
$$w_3^...
$$w_5^0$$
$$w_5^...
$$w_6^0$$
$$w_6^...
$$w_7^0$$
$$w_7^...
0
0
1
1
1
1
0
0
1
1
0
0
1
1
0
0
$$w_0^1$$
$$w_0^...
$$w_1^1$$
$$w_1^...
$$w_2^1$$
$$w_2^...
$$w_3^1$$
$$w_3^...
$$w_4^1$$
$$w_4^...
$$w_5^1$$
$$w_5^...
$$w_6^1$$
$$w_6^...
$$w_7^1$$
$$w_7^...
$$w_0^0$$
$$w_0^...
$$w_1^0$$
$$w_1^...
$$w_2^0$$
$$w_2^...
$$w_3^0$$
$$w_3^...
$$w_4^0$$
$$w_4^...
$$w_5^0$$
$$w_5^...
$$w_6^0$$
$$w_6^...
$$w_7^0$$
$$w_7^...
$$w_1^1$$
$$w_1^...
$$w_2^1$$
$$w_2^...
$$w_4^1$$
$$w_4^...
$$w_0^0$$
$$w_0^...
$$w_3^0$$
$$w_3^...
$$w_5^0$$
$$w_5^...
$$w_7^0$$
$$w_7^...
$$w_1^1$$
$$w_1^...
$$w_2^1$$
$$w_2^...
$$w_4^1$$
$$w_4^...
$$w_0^0$$
$$w_0^...
$$w_3^0$$
$$w_3^...
$$w_5^0$$
$$w_5^...
$$w_7^0$$
$$w_7^...
$$w_6^1$$
$$w_6^...
$$w_6^1$$
$$w_6^...
Full
Encoding
Full...
1
1
0
0
Data
Data
Active
Encoding
Active...
Full
Encoding
Full...
Purported
Data
Purported...
Active
Encoding
Active...
Notary generates full encoding using a PRG
Notary generates full e...
Prover only knows the active encoding during commitment
Prover only knows the a...
Prover hashes the active encoding and commits to it in the merkle tree
Prover hashes the activ...
H(
H(
)
)
H(
H(
)
)
Prover sends purported data to the Verifier
Prover sends purported...
Verifier checks Notary signature of PRG seed, and regenerates full encodings
Verifier checks Notary...
Verifier selects active encoding for the purported data
Verifier selects active...
Verifier computes hash of the active encoding
Verifier computes hash...
UTF-8: 'h' -> 01101000
UTF-8: 'h' -> 01101000
Commits
Commits
UTF-8: 'j' -> 01101010
UTF-8: 'j' -> 01101010
☢️ Flipped bit
☢️ Flipped bit
Prover can not create a merkle proof with this hash in the tree, because he did not know
Prover can not create a...
when committing. He only knew the authentic encoding
when committing. He onl...
$$w_6^1$$
$$w_6^...
$$w_6^0$$
$$w_6^...
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/gc-types.svg b/docs/diagrams/gc-types.svg deleted file mode 100644 index 455dbc9..0000000 --- a/docs/diagrams/gc-types.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Input A
Input A
Input B
Input B
WireGroup
WireGroup
0
0
1
1
1
1
0
0
1
1
1
1
0
0
0
0
Value
Value
$$w^{0}_{0}$$
$$w^{...
$$w^{1}_{1}$$
$$w^{...
$$w^{1}_{2}$$
$$w^{...
$$w^{0}_{3}$$
$$w^{...
WireLabel
WireLabel
Labels<Input, Active>
Labels<Input, Active>
$$w^{0}_{0}$$
$$w^{...
$$w^{0}_{1}$$
$$w^{...
$$w^{0}_{2}$$
$$w^{...
$$w^{0}_{3}$$
$$w^{...
Labels<Input, Full>
Labels<Input, Full>
$$w^{1}_{0}$$
$$w^{...
$$w^{1}_{1}$$
$$w^{...
$$w^{1}_{2}$$
$$w^{...
$$w^{1}_{3}$$
$$w^{...
$$w^{1}_{4}$$
$$w^{...
$$w^{1}_{5}$$
$$w^{...
$$w^{0}_{6}$$
$$w^{...
$$w^{0}_{7}$$
$$w^{...
$$w^{0}_{4}$$
$$w^{...
$$w^{0}_{5}$$
$$w^{...
$$w^{0}_{6}$$
$$w^{...
$$w^{0}_{7}$$
$$w^{...
$$w^{1}_{4}$$
$$w^{...
$$w^{1}_{5}$$
$$w^{...
$$w^{1}_{6}$$
$$w^{...
$$w^{1}_{7}$$
$$w^{...
LabelsSet<Input, Full>
LabelsSet<Input, Full>
LabelsSet<Input, Active>
LabelsSet<Input, Active>
WireLabelPair
WireLabelP...
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/intro-diagram.svg b/docs/diagrams/intro-diagram.svg deleted file mode 100644 index 0a02e8a..0000000 --- a/docs/diagrams/intro-diagram.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
TLSNotary Protocol Overview
TLSNotary Protocol Overview
Web Server
Web Server
User
User
Notary
Notary
Notary Public Key Share
Notary Public Key Sha...
Combined PK =
User Public Key Share +
Notary Public Key Share
Combined PK =...
Web Server Public Key
Web Server Public Key
Web Server Public Key
Web Server Public Key
Key Exchange
Key Exchange
Point Addition
Point Addition
PMSLabel
Computation
PMSLabel...
Session Key Derivation
Session Key Derivation
Master Key
Master Key
Session Key
Session Key
Encrypt Request
Encrypt Request
Encrypt
Encrypt
Compute MAC
Compute MAC
PMS EC Additive Share
PMS EC Additive Share
Decrypt Response
Decrypt Response
Decrypt
Decrypt
Verify MAC
Verify MAC
PMS EC Additive Share
PMS EC Additive Share
Encoded PMS
Encoded PMS
Encoded PMS
Encoded PMS
Encoded PMS
Encoded PMS
Encoded PMS
Encoded PMS
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encoded Session Keys
Encrypted Request
Encrypted Request
Request
Request
Encrypted Request
Encrypted Request
Encoded Session Keys
Encoded Session Keys
Response
Response
Encrypted Response
Encrypted Response
Encrypted Response
Encrypted Response
Encoded Session Keys
Encoded Session Keys
Encrypted Request
Encrypted Request
Encrypted Response
Encrypted Response
Sign Transcript
Sign Transcript
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/key_exchange.svg b/docs/diagrams/key_exchange.svg deleted file mode 100644 index 2fac245..0000000 --- a/docs/diagrams/key_exchange.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Prover
Prover
Server
Server
Verifier
(Notary)
Verifier...
Server
Public Key
Serv...
Server
Public Key
Serv...
Verifier
Public Key
Veri...
Verifier
Public Key
Veri...
Prover Public
Key
Prov...
Secure 2PC
Secure 2PC
PMS Key Share
PMS...
PMS Key Share
PMS...
Prover
Private Key
Prov...
Verifier
Private Key
Veri...
PMS Key
PMS...
+
+
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/mpc-decryption.svg b/docs/diagrams/mpc-decryption.svg deleted file mode 100644 index 25e82fe..0000000 --- a/docs/diagrams/mpc-decryption.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Key share
Key share
Plaintext
Plaintext
Prover
Prover
Decrypt
Decrypt
Key share
Key share
Verifier
Verifier
Ciphertext
Ciphertext
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/mpc-encryption.svg b/docs/diagrams/mpc-encryption.svg deleted file mode 100644 index df8698d..0000000 --- a/docs/diagrams/mpc-encryption.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Key share
Key share
Plaintext
Plaintext
Prover
Prover
Encrypt
Encrypt
Key share
Key share
Verifier
Verifier
Ciphertext
Ciphertext
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/overview.svg b/docs/diagrams/overview.svg deleted file mode 100644 index a7378c4..0000000 --- a/docs/diagrams/overview.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Selective Disclosure Phase
Selective Disclosure Phase
ZK Proof
ZK Proof
Verifier
Verifier
User
User
Notarized Transcript
Notarized Transcript
Transcript
Transcript
1010101010101
0101
010101010
1010101110101
1010101010101...
Encrypted Data
Encrypted Data
Signature
Signature
Metadata
Metadata
0
0
Server
Server
User
User
Notary
Notary
Notarization Phase
Notarization Phase
Notarized Transcript
Notarized Transcript
Transcript
Transcript
1010101010101
0101010101010
1010101110101
1010101010101...
Encrypted Data
Encrypted Data
Signature
Signature
Metadata
Metadata
Transcript
Transcript
1010101010101
0101010101010
1010101110101
1010101010101...
Encrypted Data
Encrypted Data
Notarize
Notarize
Multi-party request
Multi-party r...
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/overview2.svg b/docs/diagrams/overview2.svg deleted file mode 100644 index b42271f..0000000 --- a/docs/diagrams/overview2.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Server
Server
encrypted data
encrypted...
Notary
Notary
User
User
signed data
signed data
Verifier
Verifier
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/overview_notarization.svg b/docs/diagrams/overview_notarization.svg deleted file mode 100644 index 38390d8..0000000 --- a/docs/diagrams/overview_notarization.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
User
User
Server
Server
Notary
Notary
public key
public key
public key
public key
public key
public key
Multi-party
request
Multi-party...
Multi-party
key exchange
Multi-party...
encrypted request
encrypted request
encrypted response
encrypted response
Notarize
Notarize

combined public key

combined public key
Session Key
Se...
Session Key Share
Se...
Session Key Share
Se...
encrypted
response
encrypted...
notarized
transcript
notarized...
request
request
Request
Reque...
Notarize
Notar...
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/overview_notary.svg b/docs/diagrams/overview_notary.svg deleted file mode 100644 index 9bba6c9..0000000 --- a/docs/diagrams/overview_notary.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Prover
Prover
Server
Server
Notary
Notary
blindly
signed
data
blindly...
Verifier
Verifier
TLS
TLS
notarize
notarize
redacted signed
data
redacted...
selective disclosure
selectiv...
Multi party computation
Multi party computati...
1
1
2
2
3
3
4
4
verify
verify
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/overview_prover_verifier.svg b/docs/diagrams/overview_prover_verifier.svg deleted file mode 100644 index 91bc6df..0000000 --- a/docs/diagrams/overview_prover_verifier.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Prover
Prover
Server
Server
Verifier
Verifier
TLS
TLS
MPC-TLS
MPC-TLS
1
1
3
3
2
2
Verify
Verify
Selective disclosure
Selective disclosure
1
1
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/protocol.svg b/docs/diagrams/protocol.svg deleted file mode 100644 index 91ba1a6..0000000 --- a/docs/diagrams/protocol.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Server
Server
Prover
Prover
Verifier
Verifier
Private Key
Private Key
Private Key
Private Key
PMS Share
PMS Share
PMS Share
PMS Share
Secret Share PMS
Secret Share PMS
ClientHello
ClientHello
ServerHello
ServerHello
CF verify_data
CF verify_data
TLS 1.2 - Single-round
TLS 1.2 - Single-round
ClientFinished
ClientFinished
ServerFinished
ServerFinished
ServerCertificate
ServerCertificate
ServerKeyExchange
ServerKeyExchange
ServerHelloDone
ServerHelloDone
Notary Public Key
Notary Public Key
Server Public Key
Server Public Key
ClientKeyExchange
ClientKeyExchange
PMS Share
PMS Share
PMS Share
PMS Share
Key Shares
Key Shares
Key Shares
Key Shares
Secret Share
Session Keys
(PRF)
Secret Share...
Handshake Hash
Handshake Hash
Key Shares
Key Shares
CF verify_data
CF verify_data
Key Shares
Key Shares
Compute
ClientFinished
verify_data
Compute...
Key Shares
Key Shares
Key Shares
Key Shares
ClientFinished
ClientFinished
Encrypt
ClientFinished
Encrypt...
ClientCCS
ClientCCS
ServerCCS
ServerCCS
Key Shares
Key Shares
EncryptedRequest
EncryptedRequest
Requ
Requ
Request
Request
Key Shares
Key Shares
EncryptedRequest
EncryptedRequest
Encrypt
Encrypt
EncryptedRequest
EncryptedRequest
Response
Response
Commitment
Commitment
Generate
Commitment
Generate...
EncryptedResponse
EncryptedResponse
EncryptedResponse
EncryptedResponse
MAC Key share
MAC Key share
Verify
MACs
Verify...
Key Shares
Key Shares
Decrypt
Encrypted
Response
Decrypt...
Commitment
Commitment
ClientCloseNotify
ClientCloseNotify
Verify
ServerFinished
Verify...
Key Shares
Key Shares
Key Shares
Key Shares
SF verify_data
SF verify_data
Handshake Hash
Handshake Hash
Compute
ServerFinished
verify_data
Compute...
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/transcript.svg b/docs/diagrams/transcript.svg deleted file mode 100644 index 2135ff8..0000000 --- a/docs/diagrams/transcript.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
Transcript
Transc...
Commitments
Commitments
0
0
1
1
2
2
3
3
ServerRandom
ServerRandom
HandshakeData
HandshakeData
ProtocolVersion
ProtocolVersion
CipherSuite
CipherSuite
CommitmentScheme
CommitmentScheme
Header
Header
Timestamp
Timestamp
SessionSecrets
Sessio...
ServerCertificate
ServerCertificate
ApplicationData
ApplicationData
Email
Email
Password
Password
Request: Login
Request: Login
AccessToken
AccessToken
RefreshToken
RefreshToken
Response: Success
Response: Success
UserId
UserId
Request: Get Profile
Request: Get Profile
AccessToken
AccessToken
UserId
UserId
LegalName
LegalName
Address
Address
Response: Profile
Response: Profile
UserId
UserId
ClientRandom
ClientRandom
ServerEphemeralKey
ServerEphemeralKey
NotarizedTranscript
NotarizedTranscript
NotarySignature
NotarySignature
NotaryId
NotaryId
NotaryCertificate
NotaryCertificate
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/diagrams/verification_example.svg b/docs/diagrams/verification_example.svg deleted file mode 100644 index f8d30f0..0000000 --- a/docs/diagrams/verification_example.svg +++ /dev/null @@ -1,3 +0,0 @@ - - -
--- Request
GET /profile HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64)
Host: www.example.com
Accept-Language: en-us
Cookie: user_session=███████████████████████████████████████
Connection: Keep-Alive

--- Response
HTTP/1.1 200 OK
Date: Wed, 14 Jun 2023 16:10:53 GMT
Server: Apache/2.2.14 (Win32)
Last-Modified: Sat, 03 Jan 2009 19:15:56 GMT
Content-Length: 74
Content-Type: application/json
Connection: Closed

{"username":"john123","address":"█████████████████████████","birthday":"█████████████"}
--- Request...
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/intro.md b/docs/intro.md index fedc704..9d50a12 100644 --- a/docs/intro.md +++ b/docs/intro.md @@ -19,7 +19,8 @@ The TLSNotary protocol consists of 3 steps: 2. The `Prover` **selectively discloses** the data to the `Verifier`. 3. The `Verifier` **verifies** the data. -![](./diagrams/overview_prover_verifier.svg) +![](../diagrams/light/overview_prover_verifier.svg#gh-light-mode-only) +![](../diagrams/dark/overview_prover_verifier.svg#gh-dark-mode-only) ### ① Multi-party TLS Request @@ -41,7 +42,8 @@ The `Verifier` now validates the proof received from the `Prover`. The data orig Since the validation of the TLS traffic neither reveals anything about the plaintext of the TLS session nor about the `Server`, it is possible to outsource the MPC-TLS verification ① to a general-purpose TLS verifier, which we term a `Notary`. This `Notary` can sign (aka *notarize*) ② the data, making it portable. The `Prover` can then take this signed data and selectively disclose ③ sections to an application-specific `Verifier`, who then verifies the data ④. -![](./diagrams/overview_notary.svg) +![](../diagrams/light/overview_notary.svg#gh-light-mode-only) +![](../diagrams/dark/overview_notary.svg#gh-dark-mode-only) In this setup, the `Notary` cryptographically signs commitments to the data and the server's identity. The `Prover` can store this signed data, redact it, and share it with any `Verifier` as they see fit, making the signed data both reusable and portable. diff --git a/docs/motivation.md b/docs/motivation.md index 2d7b672..4575a5c 100644 --- a/docs/motivation.md +++ b/docs/motivation.md @@ -12,7 +12,8 @@ Data provenance will make data truly portable, empowering users to share it with ## Non-repudiation: TLS is not enough -![](diagrams/data_provenance_none.svg) +![](../diagrams/light/data_provenance_none.svg#gh-light-mode-only) +![](../diagrams/dark/data_provenance_none.svg#gh-dark-mode-only) Transport Layer Security (TLS) plays a crucial role in digital security. TLS protects communication against eavesdropping and tampering. It ensures that the data received by a user (_"Alice"_) indeed originated from the `Server` and was not changed. The `Server`'s identity is verified by Alice through trusted Certificate Authorities (CAs). Data integrity is maintained by transmitting a cryptographic hash (called Message Authentication Code or MAC in TLS) alongside the data, which safeguards against deliberate alterations. @@ -24,7 +25,8 @@ While the concept seems straightforward, enabling servers to sign data is not a ## Status Quo: delegate access -![](diagrams/data_provenance_oauth.svg) +![](../diagrams/light/data_provenance_oauth.svg#gh-light-mode-only) +![](../diagrams/dark/data_provenance_oauth.svg#gh-dark-mode-only) Currently, when Alice wants to share data from a `Server` with another party, OAuth can be used to facilitate this if the application supports it. In this way, the other party receives the data directly from the `Server`, ensuring authentic and unchanged data. However, applications often do not provide fine-grained control over which data to share, leading to the other party gaining access to more information than strictly necessary. @@ -34,7 +36,8 @@ It's worth noting that in many instances, OAuth is not even presented as an opti ## TLSNotary: data provenance and privacy with secure multi-party computation -![](diagrams/data_provenance_tlsn.svg) +![](../diagrams/light/data_provenance_tlsn.svg#gh-light-mode-only) +![](../diagrams/dark/data_provenance_tlsn.svg#gh-dark-mode-only) TLSNotary operates by executing the TLS communication using **multi-party computation** (MPC). MPC allows Alice and Bob to jointly manage the TLS connection. With TLSNotary, Alice can selectively prove the authenticity of arbitrary portions of the data to Bob. Since Bob participated in the MPC-TLS communication, he is guaranteed that the data is authentic. diff --git a/docs/mpc/key_exchange.md b/docs/mpc/key_exchange.md index 8b54009..92c327b 100644 --- a/docs/mpc/key_exchange.md +++ b/docs/mpc/key_exchange.md @@ -7,7 +7,8 @@ In TLS, the first step towards obtaining TLS session keys is to compute a shared With TLSNotary, at the end of the key exchange, the `Server` gets the `PMS` as usual. The `Prover` and the `Verifier`, jointly operating as the TLS client, compute additive shares of the `PMS`. This prevents either party from unilaterally sending or receiving messages with the `Server`. Subsequently, the authenticity and integrity of the messages are guaranteed to both the `Prover` and `Verifier`, while also keeping the plaintext hidden from the `Verifier`. -![](../diagrams/key_exchange.svg) +![](../../diagrams/light/key_exchange.svg#gh-light-mode-only) +![](../../diagrams/dark/key_exchange.svg#gh-dark-mode-only) The 3-party ECDH protocol between the `Server` the `Prover` and the `Verifier` works as follows: diff --git a/docs/quick_start/rust.md b/docs/quick_start/rust.md index b60c025..e0cf5f9 100644 --- a/docs/quick_start/rust.md +++ b/docs/quick_start/rust.md @@ -18,7 +18,8 @@ Before we start, make sure you have cloned the `tlsn` repository and have a rece ## Simple Interactive Verifier: Verifying Data from an API in Rust -![](../diagrams/overview_prover_verifier.svg) +![](../../diagrams/light/overview_prover_verifier.svg#gh-light-mode-only) +![](../../diagrams/dark/overview_prover_verifier.svg#gh-dark-mode-only) This example demonstrates how to use TLSNotary in a simple interactive session between a Prover and a Verifier. It involves the Verifier first verifying the MPC-TLS session and then confirming the correctness of the data. @@ -27,7 +28,8 @@ https://github.com/tlsnotary/tlsn/tree/main/crates/examples/interactive#readme ## Simple Attestation Example: Verifying Data from an API in Rust with a Notary -![](../diagrams/overview_notary.svg) +![](../../diagrams/light/overview_notary.svg#gh-light-mode-only) +![](../../diagrams/dark/overview_notary.svg#gh-dark-mode-only) TLSNotary can also be used in a setup where MPC-TLS verification is delegated to a notary server. In this example, the notary attests to the data served to the prover. Next, the prover can share this attestation with a Verifier who can verify the data. diff --git a/docs/quick_start/tlsn-js.md b/docs/quick_start/tlsn-js.md index a653657..7cfb1db 100644 --- a/docs/quick_start/tlsn-js.md +++ b/docs/quick_start/tlsn-js.md @@ -60,7 +60,8 @@ In this demo, we will request JSON data from the Star Wars API at https://swapi. ## Interactive verification with `tlsn-js` -![](../diagrams/overview_prover_verifier.svg) +![](../../diagrams/light/overview_prover_verifier.svg#gh-light-mode-only) +![](../../diagrams/dark/overview_prover_verifier.svg#gh-dark-mode-only) Follow the instructions from: https://github.com/tlsnotary/tlsn-js/blob/main/demo/interactive-demo/README.md diff --git a/src/css/custom.css b/src/css/custom.css index 2bc6a4c..2e1daa7 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -28,3 +28,8 @@ --ifm-color-primary-lightest: #4fddbf; --docusaurus-highlighted-code-line-bg: rgba(0, 0, 0, 0.3); } + +[data-theme='light'] img[src$='#gh-dark-mode-only'], +[data-theme='dark'] img[src$='#gh-light-mode-only'] { + display: none; +} \ No newline at end of file