Canadian cities labeler over Bluesky DMs
Users DM @cities.pds.cosocial.ca their city and get a signed account label. Serves com.atproto.label.queryLabels and subscribeLabels, built on jacquard. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
commit
a7d410fd6d
17 files changed
+5306
No files matched your search
@@ -0,0 +1,14 @@
|
||||
//! Generates the label signing key. The public multibase goes into the
|
||||
//! labeler's DID document as the `#atproto_label` verification method.
|
||||
use jacquard::common::types::crypto::multikey;
|
||||
use k256::ecdsa::SigningKey;
|
||||
use rand_core::OsRng;
|
||||
|
||||
fn main() {
|
||||
let key = SigningKey::random(&mut OsRng);
|
||||
let public = key.verifying_key().to_encoded_point(true);
|
||||
let multibase = multikey(0xE7, public.as_bytes());
|
||||
println!("SIGNING_KEY_HEX={}", hex::encode(key.to_bytes()));
|
||||
println!("# public key (did:key): did:key:{multibase}");
|
||||
println!("# publicKeyMultibase: {multibase}");
|
||||
}
|
||||
Reference in new issue
Block a user