From f09bebe51a9e594b6e36d7a8667bc944fa10342d Mon Sep 17 00:00:00 2001 From: Pat Losoponkul Date: Wed, 22 May 2024 12:27:00 +0700 Subject: [PATCH 1/3] docs: update new key types in DID tutorials [skip ci] Signed-off-by: Pat Losoponkul --- docs/docusaurus/dids/create.md | 8 +++++--- docs/docusaurus/dids/update.md | 3 ++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/docs/docusaurus/dids/create.md b/docs/docusaurus/dids/create.md index 2496a3a13e..42868604c7 100644 --- a/docs/docusaurus/dids/create.md +++ b/docs/docusaurus/dids/create.md @@ -54,8 +54,9 @@ The result should show an empty list, as no DIDs exist on this Cloud Agent insta ### 2. Create the Cloud Agent managed DID using DID registrar endpoint The DID controller can create a new DID by sending a [DID document](/docs/concepts/glossary#did-document) template to the Agent. -Since key pairs are generated and managed by the Cloud Agent, DID controller only has to specify the key `id` and its purpose (e.g., `authentication`, `assertionMethod`, etc.). -The current PRISM DID method supports a key with a single purpose, but it is extendible to support a key with multiple purposes in the future. +Since key pairs are generated and managed by the Cloud Agent, DID controller only has to specify the key `id`, +`purpose` (`authentication`, `assertionMethod`, etc.), and optional `curve` (`secp256k1`, `Ed25519`, `X25519`). +If the `curve` is omitted, the agent uses the `secp256k1` curve by default. ```bash curl --location --request POST 'http://localhost:8080/cloud-agent/did-registrar/dids' \ @@ -67,7 +68,8 @@ curl --location --request POST 'http://localhost:8080/cloud-agent/did-registrar/ "publicKeys": [ { "id": "auth-1", - "purpose": "authentication" + "purpose": "authentication", + "curve": "secp256k1" } ], "services": [] diff --git a/docs/docusaurus/dids/update.md b/docs/docusaurus/dids/update.md index b3e5e6760f..4a91c93107 100644 --- a/docs/docusaurus/dids/update.md +++ b/docs/docusaurus/dids/update.md @@ -120,7 +120,8 @@ curl --location --request POST 'http://localhost:8080/cloud-agent/did-registrar/ "actionType": "ADD_KEY", "addKey": { "id": "key-2", - "purpose": "authentication" + "purpose": "authentication", + "curve": "secp256k1" } } ] From 30f634453e4bc0782cd670f351fb537bd1ad733a Mon Sep 17 00:00:00 2001 From: Pat Losoponkul Date: Wed, 22 May 2024 13:42:36 +0700 Subject: [PATCH 2/3] ci: skip jobs when pr title is mark skipped Signed-off-by: Pat Losoponkul --- .github/workflows/integration-tests.yml | 1 + .github/workflows/lint.yml | 2 ++ .github/workflows/performance-tests.yml | 1 + .github/workflows/unit-tests.yml | 1 + 4 files changed, 5 insertions(+) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 3a8202ed48..2467780df2 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -26,6 +26,7 @@ jobs: run-integration-tests: name: "Run integration tests" runs-on: ubuntu-latest + if: ${{ !contains(github.event.pull_request.title, '[skip ci]') }} env: REPORTS_DIR: "tests/integration-tests/target/site/serenity" steps: diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index e1e6eead0b..51fba461bf 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -20,6 +20,8 @@ jobs: runs-on: ubuntu-latest + if: ${{ !contains(github.event.pull_request.title, '[skip ci]') }} + permissions: contents: write issues: write diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index 6a85eaaf81..c487e92863 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -21,6 +21,7 @@ jobs: run-e2e-tests: name: "Run performance tests" runs-on: ubuntu-latest + if: ${{ !contains(github.event.pull_request.title, '[skip ci]') }} steps: - name: Checkout uses: actions/checkout@v4 diff --git a/.github/workflows/unit-tests.yml b/.github/workflows/unit-tests.yml index 065e5a5fcd..5a45f81988 100644 --- a/.github/workflows/unit-tests.yml +++ b/.github/workflows/unit-tests.yml @@ -16,6 +16,7 @@ jobs: build-and-unit-tests: name: "Build and unit tests" runs-on: self-hosted + if: ${{ !contains(github.event.pull_request.title, '[skip ci]') }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} container: From ee8456854085008dd44d9427e5a7a7ac16bff9f9 Mon Sep 17 00:00:00 2001 From: Pat Losoponkul Date: Wed, 22 May 2024 17:12:52 +0700 Subject: [PATCH 3/3] revert: linter is not skipped Signed-off-by: Pat Losoponkul --- .github/workflows/lint.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 51fba461bf..e1e6eead0b 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -20,8 +20,6 @@ jobs: runs-on: ubuntu-latest - if: ${{ !contains(github.event.pull_request.title, '[skip ci]') }} - permissions: contents: write issues: write