Skip to content

Commit

Permalink
fix: use Ed25519VerificationKey2020 instead of Multikey for now
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Bluhm <dbluhm@pm.me>
  • Loading branch information
dbluhm committed Jan 31, 2024
1 parent 68ea3c5 commit 1872e86
Showing 1 changed file with 15 additions and 6 deletions.
21 changes: 15 additions & 6 deletions aries_cloudagent/connections/base_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@
from base58 import b58decode
from did_peer_2 import KeySpec, generate
from did_peer_4 import encode, long_to_short
from did_peer_4.input_doc import KeySpec as KeySpec_DP4
from did_peer_4.input_doc import input_doc_from_keys_and_services
from pydid import (
BaseDIDDocument as ResolvedDocument,
)
Expand Down Expand Up @@ -153,10 +151,21 @@ async def create_did_peer_4(
async with self._profile.session() as session:
wallet = session.inject(BaseWallet)
key = await wallet.create_key(ED25519)
key_spec = KeySpec_DP4(multikey=self._key_info_to_multikey(key))
input_doc = input_doc_from_keys_and_services(
keys=[key_spec], services=services
)
input_doc = {
"@context": [
"https://www.w3.org/ns/did/v1",
"https://w3id.org/security/suites/ed25519-2020/v1",
],
"verificationMethod": [
{
"id": "#key-0",
"type": "Ed25519VerificationKey2020",
"publicKeyMultibase": self._key_info_to_multikey(key),
}
],
"authentication": ["#key-0"],
"service": services,
}
did = encode(input_doc)

did_info = DIDInfo(
Expand Down

0 comments on commit 1872e86

Please sign in to comment.