Closed rubdos closed 1 year ago
For the known-answer tests, I've generated a few using our own pre-existing (and working) implementation, but feel free to add some of your own to make sure.
Generated using:
use libsignal_service::push_service::ProfileKeyExt;
use rand::Rng;
use zkgroup::profiles::ProfileKey;
fn main() {
let profile_key = ProfileKey::generate(rand::thread_rng().gen());
let access_key = profile_key.derive_access_key();
println!("({:#x?}, {access_key:#x?})", profile_key.get_bytes());
}
Pulled into v0.23.0. Thank you!
We've been implementing our own access key derivation function for a while now in libsignal-service, currently as an extention trait, but it feels a bit weird not to have it in here.
Things up for discussion:
This is a suggestion PR, so feel free to suggest alternative approaches :)