Skip to content

feat: implement DAVE end-to-end encryption #10921

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 30 commits into from
Jul 13, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
400a4be
feat(voice): implement DAVE E2EE encryption
Snazzah Jun 4, 2025
ec6b8b4
chore(voice): update dependencies
Snazzah Jun 4, 2025
0c716b5
chore(voice): update debug logs and dependency report
Snazzah Jun 4, 2025
4952ef6
feat(voice): emit and propogate DAVESession errors
Snazzah Jun 4, 2025
9571449
chore(voice): export dave session things
Snazzah Jun 4, 2025
6c2d9be
chore(voice): move expiry numbers to consts
Snazzah Jun 4, 2025
5461e94
feat(voice): keep track of and pass connected client IDs
Snazzah Jun 4, 2025
d44b76a
fix(voice): dont set initial transitions as pending
Snazzah Jun 4, 2025
99e10b4
feat(voice): dave encryption
Snazzah Jun 4, 2025
c196909
chore(voice): directly reference package name in import
Snazzah Jun 4, 2025
c925557
feat(voice): dave decryption
Snazzah Jun 4, 2025
bd29b62
chore(deps): update @snazzah/davey
Snazzah Jun 5, 2025
04dac3a
fix(voice): handle decryption failure tolerance
Snazzah Jun 5, 2025
5feb52c
fix(voice): move and update decryption failure logic to DAVESession
Snazzah Jun 6, 2025
890c20d
feat(voice): propogate voice privacy code
Snazzah Jun 8, 2025
f8fa827
fix(voice): actually send a transition ready when ready
Snazzah Jun 8, 2025
333d50e
feat(voice): propogate transitions and verification code function
Snazzah Jun 8, 2025
fb7c39a
feat(voice): add dave options
Snazzah Jun 8, 2025
4102bac
Merge branch 'main' into feat/dave-protocol
Snazzah Jun 8, 2025
d6eb94e
chore: resolve format change requests
Snazzah Jun 9, 2025
22f1f06
chore: emit debug messages on bad transitions
Snazzah Jun 9, 2025
f054fc6
chore: downgrade commit/welcome errors as debug messages
Snazzah Jun 9, 2025
b74395c
chore: resolve formatting change requests
Snazzah Jun 9, 2025
c1f3cc6
chore: update davey dependency
Snazzah Jun 10, 2025
00b8717
chore: add types for underlying dave session
Snazzah Jun 10, 2025
e58eb4f
Merge branch 'main' into feat/dave-protocol
Snazzah Jun 15, 2025
59ff18d
Merge branch 'main' into feat/dave-protocol
Snazzah Jul 3, 2025
9520210
fix: fix rebase
Snazzah Jul 3, 2025
50ad3cb
chore: change "ID" to "id" in typedocs
Snazzah Jul 3, 2025
0388570
Merge branch 'main' into feat/dave-protocol
Jiralite Jul 13, 2025
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
Prev Previous commit
Next Next commit
fix(voice): actually send a transition ready when ready
  • Loading branch information
Snazzah committed Jun 8, 2025
commit f8fa827fe1d121560b2c3c6ec1eb90366fbac900
4 changes: 2 additions & 2 deletions packages/voice/src/networking/DAVESession.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ const TRANSITION_EXPIRY = 10;

/**
* The arbitrary amount of seconds to allow passthrough for mid-downgrade.
* Generally, transitions should not even last this long, but should be more than enough to cover it.
* Generally, transitions last about 3 seconds maximum, but this should cover for when connections are delayed.
*/
const TRANSITION_EXPIRY_PENDING_DOWNGRADE = 120;
const TRANSITION_EXPIRY_PENDING_DOWNGRADE = 24;

/**
* The amount of packets to allow decryption failure for until we deem the transition bad and re-initialize.
Expand Down
10 changes: 8 additions & 2 deletions packages/voice/src/networking/Networking.ts
Original file line number Diff line number Diff line change
Expand Up @@ -537,8 +537,14 @@ export class Networking extends EventEmitter {
(this.state.code === NetworkingStatusCode.Ready || this.state.code === NetworkingStatusCode.Resuming) &&
this.state.dave
) {
if (packet.op === VoiceOpcodes.DavePrepareTransition) this.state.dave.prepareTransition(packet.d);
else if (packet.op === VoiceOpcodes.DaveExecuteTransition)
if (packet.op === VoiceOpcodes.DavePrepareTransition) {
const ready = this.state.dave.prepareTransition(packet.d);
if (ready)
this.state.ws.sendPacket({
op: VoiceOpcodes.DaveTransitionReady,
d: { transition_id: packet.d.transition_id },
});
} else if (packet.op === VoiceOpcodes.DaveExecuteTransition)
this.state.dave.executeTransition(packet.d.transition_id);
else if (packet.op === VoiceOpcodes.DavePrepareEpoch) this.state.dave.prepareEpoch(packet.d);
}
Expand Down
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy