Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ End-to-end encrypted communication and file synchronization for SyftBox using th
This crate provides cryptographic primitives for secure messaging and file synchronization in SyftBox, built on top of [libsignal's implementation](https://github.com/signalapp/libsignal) of the Signal protocol. It includes support for the PQXDH key agreement protocol for post-quantum security via Kyber.

## Status

This software is considered Beta so use at your own risk.

## Project Structure
Expand Down
1 change: 1 addition & 0 deletions docs/cli/tutorial-keys.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ syc \
A successful import prints the bundle identity and fingerprint, then writes a
canonical copy to `sandbox/bob/.syc/bundles/alice@example.org.json`. Repeat the
steps in reverse so Alice caches Bob’s bundle.

```
mkdir -p sandbox/alice/datasites/bob@example.org/public/crypto
cp \
Expand Down
4 changes: 3 additions & 1 deletion docs/cli/tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,11 @@ All shell commands are relative to the repository root (`syft-crypto-core`). Adj
> Quick start: `just init-sandbox` will create the directory skeletons, write the datasite configs, and generate the Alice/Bob key material automatically. The steps below show the same process manually in case you need to customise the layout.

## 0. Compile / Run syc

The `syc` command can be run direcly from the repo root by invoking it as a binary syc (this is a wrapper shell script).

Alternatively you can build and install with:

```
cargo install --path cli
which -a syc
Expand Down Expand Up @@ -193,4 +195,4 @@ The decrypted plaintext resides at `sandbox/bob/unencrypted/bob@example.org/shar
- Decrypted plaintext:
`sandbox/bob/unencrypted/bob@example.org/shared/alice@example.org/files/message.txt`

Repeat the same steps for other identities or add additional plaintext files under the corresponding `unencrypted/<identity>/shared/...` folders.***
Repeat the same steps for other identities or add additional plaintext files under the corresponding `unencrypted/<identity>/shared/...` folders.\*\*\*
73 changes: 36 additions & 37 deletions docs/protocol/envelope.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,49 +45,48 @@ The header is binary. If you dump the file as UTF‑8 you may see odd characters

![](./evelope-structure.png)


---

## Prelude Schema

```jsonc
{
"version": 1,
"canon": "jcs-rfc8785",
"created_at": 1730338793,
"sender": {
"identity": "alice@example.org",
"ik_fingerprint": "sha256hex..."
},
"recipients": [
{
"identity": "bob@example.org",
"device_label": "default",
"spk_fingerprint": "sha256hex...",
"pqspk_fingerprint": "sha256hex...",
"signed_prekey_id": 1
}
],
"recipient_set_fpr": "sha256hex...",
"wrappings": [
{
"recipient_identity": "bob@example.org",
"device_label": "default",
"wrap_ephemeral_public": "base64url(x25519)",
"wrap_ciphertext": "base64url(kyber)"
}
],
"cipher": {
"suite": "xchacha20poly1305-v1",
"segment_count": 1,
"last_segment_bytes": 1234,
"ciphertext_len": 1234,
"nonce": "base64urlnonce"
},
"integrity": null,
"public_meta": {
"filename_hint": "optional_hint.txt"
}
"version": 1,
"canon": "jcs-rfc8785",
"created_at": 1730338793,
"sender": {
"identity": "alice@example.org",
"ik_fingerprint": "sha256hex...",
},
"recipients": [
{
"identity": "bob@example.org",
"device_label": "default",
"spk_fingerprint": "sha256hex...",
"pqspk_fingerprint": "sha256hex...",
"signed_prekey_id": 1,
},
],
"recipient_set_fpr": "sha256hex...",
"wrappings": [
{
"recipient_identity": "bob@example.org",
"device_label": "default",
"wrap_ephemeral_public": "base64url(x25519)",
"wrap_ciphertext": "base64url(kyber)",
},
],
"cipher": {
"suite": "xchacha20poly1305-v1",
"segment_count": 1,
"last_segment_bytes": 1234,
"ciphertext_len": 1234,
"nonce": "base64urlnonce",
},
"integrity": null,
"public_meta": {
"filename_hint": "optional_hint.txt",
},
}
```

Expand Down