sodium-friends / sodium-javascript

Pure Javascript version of sodium-native
MIT License
92 stars 24 forks source link

Secretstream #57

Closed spieglt closed 2 years ago

spieglt commented 3 years ago

Implements hchacha20 and secretstream_xchacha20poly1305 and their tests (https://github.com/jedisct1/libsodium/blob/master/test/default/xchacha20.c, https://github.com/jedisct1/libsodium/blob/master/test/default/secretstream_xchacha20poly1305.c).

It passes the C tests, and I've encrypted files with this and then decrypted them with Rust's sodiumoxide wrapper, but more real world testing may be warranted. This supersedes #55.

spieglt commented 3 years ago

Meant to mention: I've left the tests in for now so you can see it all in one place, but I'd be happy to rewrite them with tape in https://github.com/sodium-friends/sodium-test and remove them from here before merging if you'd like to merge this.

chm-diederichs commented 2 years ago

Tests added by https://github.com/sodium-friends/sodium-test/pull/16