• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

LukaJCB / ts-mls / 21783166586

07 Feb 2026 04:28PM UTC coverage: 95.86% (-0.2%) from 96.096%
21783166586

Pull #272

github

web-flow
Merge 1bb59debe into 9cbb9b444
Pull Request #272: Refactor ciphersuites

406 of 411 branches covered (98.78%)

Branch coverage included in aggregate %.

12 of 17 new or added lines in 5 files covered. (70.59%)

2 existing lines in 1 file now uncovered.

2326 of 2439 relevant lines covered (95.37%)

72863.03 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

85.71
/src/crypto/implementation/default/provider.ts
1
import { CiphersuiteImpl, ciphersuiteValues, isDefaultCiphersuiteId } from "../../ciphersuite.js"
2

3
import { makeHashImpl } from "./makeHashImpl.js"
4
import { makeHpke } from "./makeHpke.js"
5
import { makeKdf } from "./makeKdfImpl.js"
6
import { makeKdfImpl } from "./makeKdfImpl.js"
7
import { defaultRng } from "./rng.js"
8
import { makeNobleSignatureImpl } from "./makeNobleSignatureImpl.js"
9
import { DependencyError } from "../../../mlsError.js"
10
import { CryptoProvider } from "../../provider.js"
11

12
/** @public */
13
export const defaultCryptoProvider: CryptoProvider = {
3✔
14
  async getCiphersuiteImpl(id: number): Promise<CiphersuiteImpl> {
15
    if (isDefaultCiphersuiteId(id)) {
1,513✔
16
      const cs = ciphersuiteValues[id]
1,513✔
17
      const sc = crypto.subtle
1,513✔
18
      return {
1,513✔
19
        kdf: makeKdfImpl(makeKdf(cs.hpke.kdf)),
20
        hash: makeHashImpl(sc, cs.hash),
21
        signature: await makeNobleSignatureImpl(cs.signature),
22
        hpke: await makeHpke(cs.hpke),
23
        rng: defaultRng,
24
        id: id,
25
      }
26
    } else {
NEW
27
      throw new DependencyError(`Unrecognized ciphersuite: ${id}`)
×
28
    }
29
  },
30
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc