From 4d57f4eef7098ab176650961bef9df867acb81fa Mon Sep 17 00:00:00 2001 From: Orie Steele Date: Sun, 11 Aug 2024 11:00:34 -0500 Subject: [PATCH] test ci --- .github/workflows/ci.yml | 56 ++++++++++++++++++++++++++-------------- 1 file changed, 37 insertions(+), 19 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cf4c82f2..d34f0d39 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -59,37 +59,55 @@ jobs: # jose decrypt ./tests/fixtures/private.enc.jwk.json ./tests/fixtures/message.ciphertext.compact.jwe --compact # - name: Log Message Decryption # run: echo "${{ steps.decrypt_message.outputs.json }}" - cose: + # cose: + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - name: Private Key + # id: generate_private_key + # uses: ./ + # with: + # transmute: | + # cose keygen --alg ES256 --verbose --output ./tests/fixtures/private.sig.key.cbor + # - name: Attempt to Log Private Key + # run: echo "${{ steps.generate_private_key.outputs.cbor }}" + # - name: Public Key + # id: extract_public_key + # uses: ./ + # with: + # transmute: | + # cose keypub ./tests/fixtures/private.sig.key.cbor --output ./tests/fixtures/public.sig.key.cbor + # - name: Log Public Key + # run: echo "${{ steps.extract_public_key.outputs.cbor }}" + # - name: Sign Message + # id: sign_message + # uses: ./ + # with: + # transmute: | + # cose sign ./tests/fixtures/private.sig.key.cbor ./tests/fixtures/message.json --detached --output ./tests/fixtures/message.signature.detached.cbor + # - name: Verify Message + # id: verify_message + # uses: ./ + # with: + # transmute: | + # cose verify ./tests/fixtures/public.sig.key.cbor ./tests/fixtures/message.signature.detached.cbor ./tests/fixtures/message.json --detached + # - name: Log Message Verification + # run: echo "${{ steps.verify_message.outputs.cbor }}" + scitt: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - name: Private Key - id: generate_private_key - uses: ./ - with: - transmute: | - cose keygen --alg ES256 --verbose --output ./tests/fixtures/private.sig.key.cbor - - name: Attempt to Log Private Key - run: echo "${{ steps.generate_private_key.outputs.cbor }}" - - name: Public Key - id: extract_public_key - uses: ./ - with: - transmute: | - cose keypub ./tests/fixtures/private.sig.key.cbor --output ./tests/fixtures/public.sig.key.cbor - - name: Log Public Key - run: echo "${{ steps.extract_public_key.outputs.cbor }}" - name: Sign Message id: sign_message uses: ./ with: transmute: | - cose sign ./tests/fixtures/private.sig.key.cbor ./tests/fixtures/message.json --detached --output ./tests/fixtures/message.signature.detached.cbor + scitt sign ./tests/fixtures/private.sig.key.cbor ./tests/fixtures/message.json --output ./tests/fixtures/message.hash-envelope.cbor - name: Verify Message id: verify_message uses: ./ with: transmute: | - cose verify ./tests/fixtures/public.sig.key.cbor ./tests/fixtures/message.signature.detached.cbor ./tests/fixtures/message.json --detached + cose verify ./tests/fixtures/public.sig.key.cbor ./tests/fixtures/message.hash-envelope.cbor 3073d614f853aaec9a1146872c7bab75495ee678c8864ed3562f8787555c1e22 - name: Log Message Verification run: echo "${{ steps.verify_message.outputs.cbor }}"