(attest: &mut Attestation, seed: [u8; 32])
| 1884 | } |
| 1885 | |
| 1886 | fn sign_did(attest: &mut Attestation, seed: [u8; 32]) -> String { |
| 1887 | let signing = ed25519_dalek::SigningKey::from_bytes(&seed); |
| 1888 | let did = format!( |
| 1889 | "did:atomic:{}", |
| 1890 | data_encoding::BASE32_NOPAD |
| 1891 | .encode(blake3::hash(signing.verifying_key().as_bytes()).as_bytes()) |
| 1892 | ); |
| 1893 | attest.sign_with_did(&did, &seed); |
| 1894 | did |
| 1895 | } |
| 1896 | |
| 1897 | /// A V4 attestation with evidence roots signs with a DID, verifies, |
| 1898 | /// roundtrips, and the roots survive the codec exactly. |
no test coverage detected