Skip to content

Conversation

@chengr4
Copy link
Contributor

@chengr4 chengr4 commented Sep 22, 2025

This test using the following example JSONL file

{
  "parameters": {
    "method": "did:webvh:1.0",
    "scid": "QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4",
    "updateKeys": [
      "z6MkhnhhY8VvXY5ErP6SKSgqkEjb1Jt7FgsUsg21f6tw151s"
    ]
  },
  "proof": [
    {
      "created": "2025-09-21T23:17:10Z",
      "cryptosuite": "eddsa-jcs-2022",
      "proofPurpose": "assertionMethod",
      "proofValue": "z2Cfbhc2Heg8Vpd4U9hjLQnwdoAtX65nBQJk72vLBPsCrPC4FWtPzQV9MdQ78xTsq25BXwqGLWAbCQ82Cm8dSf3v6",
      "type": "DataIntegrityProof",
      "verificationMethod": "did:key:z6MkhnhhY8VvXY5ErP6SKSgqkEjb1Jt7FgsUsg21f6tw151s#z6MkhnhhY8VvXY5ErP6SKSgqkEjb1Jt7FgsUsg21f6tw151s"
    }
  ],
  "state": {
    "@context": [
      "https://www.w3.org/ns/did/v1",
      "https://w3id.org/security/suites/jws-2020/v1"
    ],
    "authentication": [
      "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#verification-key"
    ],
    "id": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3",
    "keyAgreement": [
      "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#encryption-key"
    ],
    "service": [
      {
        "id": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#tsp-transport",
        "serviceEndpoint": "tcp://server.name",
        "type": "TSPTransport"
      }
    ],
    "verificationMethod": [
      {
        "controller": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3",
        "id": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#verification-key",
        "publicKeyJwk": {
          "crv": "Ed25519",
          "kty": "OKP",
          "use": "sig",
          "x": "DexXNDrZNzv2m6Y3VpDEqy3xU5OclOBkhcfzCP8rUGw"
        },
        "type": "JsonWebKey2020"
      },
      {
        "controller": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3",
        "id": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#encryption-key",
        "publicKeyJwk": {
          "crv": "X25519",
          "kty": "OKP",
          "use": "enc",
          "x": "KiYr3FnDV_HvMU0h4NXALYggGq0vB6YyV-dSnj6cEQ8"
        },
        "type": "JsonWebKey2020"
      }
    ]
  },
  "versionId": "1-QmXfPRZcP8356FqZedaPFz6fAucWaP3ApahoHonXpS4qUV",
  "versionTime": "2025-09-21T23:17:10Z"
}

@chengr4 chengr4 force-pushed the test-create-webvh branch 2 times, most recently from d338555 to ddbb630 Compare September 28, 2025 22:28
@chengr4 chengr4 marked this pull request as ready for review September 28, 2025 22:28
@chengr4
Copy link
Contributor Author

chengr4 commented Sep 28, 2025

Help needed to pass cehck-wasm32

…on and properties

Signed-off-by: R4 Cheng <[email protected]>

Note: For testing the public update key, I copied the implementation from create_webvh function (2f2e90e) by using Secret data structure. There should be a better solution.

This test refers to the following JSONL file:

{
  "parameters": {
    "method": "did:webvh:1.0",
    "scid": "QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4",
    "updateKeys": [
      "z6MkhnhhY8VvXY5ErP6SKSgqkEjb1Jt7FgsUsg21f6tw151s"
    ]
  },
  "proof": [
    {
      "created": "2025-09-21T23:17:10Z",
      "cryptosuite": "eddsa-jcs-2022",
      "proofPurpose": "assertionMethod",
      "proofValue": "z2Cfbhc2Heg8Vpd4U9hjLQnwdoAtX65nBQJk72vLBPsCrPC4FWtPzQV9MdQ78xTsq25BXwqGLWAbCQ82Cm8dSf3v6",
      "type": "DataIntegrityProof",
      "verificationMethod": "did:key:z6MkhnhhY8VvXY5ErP6SKSgqkEjb1Jt7FgsUsg21f6tw151s#z6MkhnhhY8VvXY5ErP6SKSgqkEjb1Jt7FgsUsg21f6tw151s"
    }
  ],
  "state": {
    "@context": [
      "https://www.w3.org/ns/did/v1",
      "https://w3id.org/security/suites/jws-2020/v1"
    ],
    "authentication": [
      "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#verification-key"
    ],
    "id": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3",
    "keyAgreement": [
      "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#encryption-key"
    ],
    "service": [
      {
        "id": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#tsp-transport",
        "serviceEndpoint": "tcp://server.name",
        "type": "TSPTransport"
      }
    ],
    "verificationMethod": [
      {
        "controller": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3",
        "id": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#verification-key",
        "publicKeyJwk": {
          "crv": "Ed25519",
          "kty": "OKP",
          "use": "sig",
          "x": "DexXNDrZNzv2m6Y3VpDEqy3xU5OclOBkhcfzCP8rUGw"
        },
        "type": "JsonWebKey2020"
      },
      {
        "controller": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3",
        "id": "did:webvh:QmRNrR8WeDiH2aFXeADg6cfRL3PhhBUKMXfSw8aFs83oN4:did.teaspoon.world:endpoint:gg3#encryption-key",
        "publicKeyJwk": {
          "crv": "X25519",
          "kty": "OKP",
          "use": "enc",
          "x": "KiYr3FnDV_HvMU0h4NXALYggGq0vB6YyV-dSnj6cEQ8"
        },
        "type": "JsonWebKey2020"
      }
    ]
  },
  "versionId": "1-QmXfPRZcP8356FqZedaPFz6fAucWaP3ApahoHonXpS4qUV",
  "versionTime": "2025-09-21T23:17:10Z"
}
@michielp1807 michielp1807 merged commit 30ecf37 into openwallet-foundation-labs:main Sep 30, 2025
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants