Giter Site home page Giter Site logo

Comments (5)

MarkLodato avatar MarkLodato commented on July 1, 2024 2

Thanks for pointing this out, @shizhMSFT! I agree that this is a problem. It's pretty bad if we only have two implementations and they already diverge.

In addition to #41, I think we should update protocol.md to explain how to handle multiple signatures. Note that we already have something similar in in-toto/attestation. Maybe we should convert to psuedocode like that.

Basically, the steps are:

  1. Inputs: envelope + recognizedPublicKeys (each with an associated name)
  2. Receive and decode the envelope.
  3. Verify each signature against each public key ==> set of verified public key names.
  4. Reject if the set of verified public key names is not acceptable. Usually this is "at least N unique names" (most often N=1), but any application-specific logic may be used. It should never be the case that deleting a signature turns a REJECT into a PASS (e.g. "all signatures valid" is wrong).
  5. Reject if payload type not supported.
  6. Parse and decode payload...

Explaining this clearly is a bit tricky though. @shizhMSFT do you want to send a PR for this?

Edit: added note about "reject -> pass".

from dsse.

trishankatdatadog avatar trishankatdatadog commented on July 1, 2024 1

Agreed, it is deliberately vague about how to verify multiple signatures, as should be the case, as this is application-specific. In the extreme cases, you verify either no or all signatures, but the general case is ofc in between and we cannot set any prescriptions there. Perhaps you could propose some text to clarify this?

from dsse.

shizhMSFT avatar shizhMSFT commented on July 1, 2024 1

I've proposed #41 that the verification policy on multiple signatures is application-specific.

from dsse.

shizhMSFT avatar shizhMSFT commented on July 1, 2024

In fact, the reference implementation in this repo makes more sense.

Acoording to the envelope documentation,

An envelope MAY have more than one signature, which is equivalent to separate envelopes with individual signatures.

Anyone can decompose the envelope to multiple envelopes with a single signature in it.

from dsse.

shizhMSFT avatar shizhMSFT commented on July 1, 2024

@MarkLodato Sent PR #45 for formalized verification.

/cc @gokarnm Similar procedures can be applied to Notary v2 with trust policy defined.

from dsse.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.