microsoft / microsoft/CCF

Expose cose sign1 message sign/verify APIs in ccf.crypto

Open
#6,031 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
876
Forks
260
Avg merge
1d 11h
Merged PRs (30d)
157

Description

The CCF infra has wrappers for COSE verification in C++ (built around t-cose), but these aren't currently exposed in the JS/TS API. Ask is to look at exposing that.

There are scenarios where the CCF app client runs in confidential ACI and presents its attestation report as the means to authenticate to the /app endpoint APIs. The code running in confidential ACI container cannot use user/member cert based auth in such situations. Further the payload of the APIs needs to be signed with a key pair that is generated/re-generated on container start within the CACI instance and whose public key is then added in the report_data of the attestation report. That way one can tie the payload with the attestation report. Using cose signing for the payload is an option that we want to go with. For this we need code in the CCF app that can verify cose sign1 messages.

As a reference, https://learn.microsoft.com/en-us/dotnet/api/system.security.cryptography.cose.cosesign1message.verifyembedded?view=dotnet-plat-ext-8.0 are the .NET APIs around cose sign/verification.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the existing C++ COSE verification wrappers built around t-cose and the JS/TS API surface that should expose them. Compare the desired sign/verify behavior with the linked .NET COSE_Sign1 reference and consider how the CCF app would verify signed payloads. Done means the relevant COSE Sign1 signing and verification APIs are available to JS/TS clients.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, javascript, typescript
Domain
api, security
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.