Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
01c601f
first commit
altkdf Aug 1, 2025
4b479ee
Merge branch 'main' into alex/encrypted-chat
altkdf Aug 1, 2025
b09bbfc
add workflow
altkdf Aug 1, 2025
7bd200f
candid
altkdf Aug 1, 2025
9907e94
finish first draft of backend (some tests to be added)
altkdf Aug 5, 2025
53983cc
some test fixes
altkdf Aug 5, 2025
aac6a87
SymmetricKeyEpochCache -> EncryptedSymmetricKeyEpochCache
altkdf Aug 5, 2025
b2bc515
add vetKey resharing tests
altkdf Aug 5, 2025
388934f
add a timer test
altkdf Aug 5, 2025
1bca085
Merge branch 'main' into alex/encrypted-chat
altkdf Aug 5, 2025
c70f73f
update candid
altkdf Aug 6, 2025
861abba
dummy frontend
altkdf Aug 6, 2025
0957895
postcss
altkdf Aug 6, 2025
5d75b13
rm unused styles
altkdf Aug 6, 2025
742e859
single script output
altkdf Aug 6, 2025
6d41345
lint
altkdf Aug 6, 2025
3250c79
improve some UI stuff
altkdf Aug 6, 2025
8cec3a4
colors
altkdf Aug 6, 2025
3ca1ea0
frontend...
altkdf Aug 7, 2025
cea44c3
add files for UI component to git that I forgot to add before
altkdf Aug 7, 2025
a0bb832
typo
altkdf Aug 7, 2025
420b5e6
frontend wip
altkdf Aug 8, 2025
8666fe8
some more wip
altkdf Aug 8, 2025
26c8ba1
add file
altkdf Aug 8, 2025
4d5ee1e
frontend wip
altkdf Aug 13, 2025
1060938
message reencryption draft
altkdf Aug 13, 2025
48e4e4b
group changes
altkdf Aug 13, 2025
7620cdc
new chat
altkdf Aug 13, 2025
65dfb84
more consistent style
altkdf Aug 13, 2025
31a9bda
logout
altkdf Aug 13, 2025
1f46f54
key cache
altkdf Aug 13, 2025
453e91b
key resharing
altkdf Aug 14, 2025
09749e4
wip rotation
altkdf Aug 14, 2025
304ad9f
group rotation works with some bugs -- sometimes needs page reloading
altkdf Aug 18, 2025
ae9d00f
typos
altkdf Aug 18, 2025
16406be
rm obsolete debugging info
altkdf Aug 18, 2025
934dffc
wip
altkdf Aug 19, 2025
829cf44
add abstractions
altkdf Aug 26, 2025
83fcf2d
small improvements
altkdf Aug 26, 2025
00ea77b
fix npm run dev
altkdf Aug 27, 2025
4061a62
mv file
altkdf Aug 27, 2025
19d7e13
wip
altkdf Oct 7, 2025
6a6d896
wip
altkdf Oct 7, 2025
bb02b2b
wip
altkdf Oct 8, 2025
f928fea
remove obsolete setting
altkdf Oct 8, 2025
3548246
allow for empty other users list in group chat creation
altkdf Oct 8, 2025
b9b0178
opaque notifications
altkdf Oct 8, 2025
8c576f6
rm dark mode
altkdf Oct 8, 2025
3f44643
less frequent queries
altkdf Oct 8, 2025
f8bd7a2
nicer emojipicker
altkdf Oct 8, 2025
619395e
fix typo
altkdf Oct 8, 2025
45e4bb8
replace placeholder '??????' with a todo comment
altkdf Oct 8, 2025
b55453d
fix a few bugs
altkdf Oct 8, 2025
e271caf
small fixes
altkdf Oct 16, 2025
6839cc4
fix indexedDB
altkdf Oct 17, 2025
6885d79
rm first accessible message id and fix JSON.stringify for principals
altkdf Oct 17, 2025
cb028d3
wip
altkdf Oct 30, 2025
d18413a
Revert "wip"
fspreiss Jan 12, 2026
03fa32b
dfx.json: bin to 127.0.0.1 instead of localhost
fspreiss Jan 12, 2026
adc96a1
Rename message ID to nonce
fspreiss Jan 12, 2026
e8d2fcf
get_some_messages_for_chat_starting_from -> get_messages
fspreiss Jan 12, 2026
73f15de
Merge branch 'main' into alex/encrypted-chat
fspreiss Jan 12, 2026
6ca43ce
ignore failing tests related to vetkey epoch expiry
fspreiss Jan 13, 2026
fe08710
Add disclaimer to encrypted chat README
fspreiss Jan 13, 2026
94a7ca6
List encryted chat as example app in vetKeys repo README
fspreiss Jan 13, 2026
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
38 changes: 38 additions & 0 deletions .github/workflows/examples-encrypted-chat.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: examples-encrypted-chat
on:
push:
branches:
- main
pull_request:
paths:
- examples/encrypted_chat/**
- .github/workflows/provision-darwin.sh
- .github/workflows/provision-linux.sh
- .github/workflows/examples-encrypted-chat.yml
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
examples-encrypted-chat-rust-darwin:
runs-on: macos-15
steps:
- uses: actions/checkout@v4
- name: Provision Darwin
run: |
bash .github/workflows/provision-darwin.sh
- name: Backend Tests Encrypted Chat Rust Darwin
run: |
set -eExuo pipefail
cd examples/encrypted_chat/rust/backend
cargo build --release --target wasm32-unknown-unknown && cargo test
examples-encrypted-chat-rust-linux:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- name: Provision Linux
run: bash .github/workflows/provision-linux.sh
- name: Backend Tests Encrypted Chat Rust Linux
run: |
set -eExuo pipefail
cd examples/encrypted_chat/rust/backend
cargo build --release --target wasm32-unknown-unknown && cargo test
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,4 @@ Tools for frontend developers to interact with VetKD enabled canisters.
- **[Password Manager](examples/password_manager)** - A secure, decentralized password manager using Encrypted Maps for vault-based password storage and sharing.
- **[Password Manager with Metadata](examples/password_manager_with_metadata)** - Extends the basic password manager to support unencrypted metadata alongside encrypted passwords.
- **[Encrypted Notes](examples/encrypted_notes_dapp_vetkd)** - A secure note-taking application that uses vetKeys for encryption and enables sharing notes between users without device management.
- **[Encrypted Chat](examples/encrypted_chat)** - An *unfinished prototype* for an end-to-end encrypted messaging application based on vetKeys.
5 changes: 5 additions & 0 deletions examples/encrypted_chat/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
> **Disclaimer**: This example is an *unfinished* prototype for a vetKeys-based encrypted chat app according to the [SPEC.md](./SPEC.md).
>
> DO NOT USE IN PRODUCTION!!

[![](https://icp.ninja/assets/open.svg)](https://icp.ninja/editor?g=https://github.com/dfinity/vetkeys/tree/alex/encrypted-chat/examples/encrypted_chat/rust)
24 changes: 24 additions & 0 deletions examples/encrypted_chat/frontend/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
test-results
node_modules

# Output
.output
.vercel
.netlify
.wrangler
/.svelte-kit
/build

# OS
.DS_Store
Thumbs.db

# Env
.env
.env.*
!.env.example
!.env.test

# Vite
vite.config.js.timestamp-*
vite.config.ts.timestamp-*
1 change: 1 addition & 0 deletions examples/encrypted_chat/frontend/.npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
engine-strict=true
9 changes: 9 additions & 0 deletions examples/encrypted_chat/frontend/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Package Managers
package-lock.json
pnpm-lock.yaml
yarn.lock
bun.lock
bun.lockb

# Miscellaneous
/static/
16 changes: 16 additions & 0 deletions examples/encrypted_chat/frontend/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"useTabs": true,
"singleQuote": true,
"trailingComma": "none",
"printWidth": 100,
"plugins": ["prettier-plugin-svelte", "prettier-plugin-tailwindcss"],
"overrides": [
{
"files": "*.svelte",
"options": {
"parser": "svelte"
}
}
],
"tailwindStylesheet": "./src/app.css"
}
38 changes: 38 additions & 0 deletions examples/encrypted_chat/frontend/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# sv

Everything you need to build a Svelte project, powered by [`sv`](https://github.com/sveltejs/cli).

## Creating a project

If you're seeing this, you've probably already done this step. Congrats!

```sh
# create a new project in the current directory
npx sv create

# create a new project in my-app
npx sv create my-app
```

## Developing

Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:

```sh
npm run dev

# or start the server and open the app in a new browser tab
npm run dev -- --open
```

## Building

To create a production version of your app:

```sh
npm run build
```

You can preview the production build with `npm run preview`.

> To deploy your app, you may need to install an [adapter](https://svelte.dev/docs/kit/adapters) for your target environment.
6 changes: 6 additions & 0 deletions examples/encrypted_chat/frontend/e2e/demo.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import { expect, test } from '@playwright/test';

test('home page has expected h1', async ({ page }) => {
await page.goto('/');
await expect(page.locator('h1')).toBeVisible();
});
64 changes: 64 additions & 0 deletions examples/encrypted_chat/frontend/eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
import prettier from 'eslint-config-prettier';
import { includeIgnoreFile } from '@eslint/compat';
import js from '@eslint/js';
import svelte from 'eslint-plugin-svelte';
import globals from 'globals';
import { fileURLToPath } from 'node:url';
import ts from 'typescript-eslint';
import svelteConfig from './svelte.config.js';
import path from 'node:path';

const gitignorePath = fileURLToPath(new URL('./.gitignore', import.meta.url));

export default ts.config(
includeIgnoreFile(gitignorePath),
js.configs.recommended,
...ts.configs.recommendedTypeChecked,
...svelte.configs.recommended,
prettier,
...svelte.configs.prettier,
{
languageOptions: {
globals: { ...globals.browser, ...globals.node }
},
rules: {
// typescript-eslint strongly recommend that you do not use the no-undef lint rule on TypeScript projects.
// see: https://typescript-eslint.io/troubleshooting/faqs/eslint/#i-get-errors-from-the-no-undef-rule-about-global-variables-not-being-defined-even-though-there-are-no-typescript-errors
'no-undef': 'off'
}
},
{
files: ['**/*.ts'],
languageOptions: {
parser: ts.parser,
parserOptions: {
projectService: true,
tsconfigRootDir: import.meta.dirname
}
}
},
{
files: ['**/*.svelte', '**/*.svelte.ts', '**/*.svelte.js'],
languageOptions: {
parserOptions: {
extraFileExtensions: ['.svelte'],
parser: ts.parser,
svelteConfig,
projectService: true,
tsconfigRootDir: import.meta.dirname
}
}
},
{
ignores: [
'dist/',
'src/declarations',
'*.config.js',
'*.config.ts',
'*.config.cjs',
'*.config.mjs',
'.svelte-kit',
'e2e/'
]
}
);
Loading