Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fragment COSE Sign1 support. #1575

Merged
merged 1 commit into from
Jan 28, 2023
Merged

Fragment COSE Sign1 support. #1575

merged 1 commit into from
Jan 28, 2023

Conversation

KenGordon
Copy link
Collaborator

Fragment COSE Sign1 support. Allows for a fragment presented by the host to be checked for a good cert chain and a valid issuer DID that matches the certs and so the signature. Includes DID and COSE Sign1 packages and tooling.

Signed-off-by: Ken Gordon ken.gordon@microsoft.com

@KenGordon KenGordon requested a review from a team as a code owner November 23, 2022 14:46
@KenGordon KenGordon mentioned this pull request Nov 23, 2022
cmd/gcs/main.go Outdated Show resolved Hide resolved
internal/tools/sign1util/main.go Outdated Show resolved Hide resolved
internal/tools/sign1util/main.go Show resolved Hide resolved
internal/cosesign1/check.go Outdated Show resolved Hide resolved
internal/cosesign1/check.go Outdated Show resolved Hide resolved
internal/did-x509-resolver/resolver.go Show resolved Hide resolved
internal/guest/runtime/hcsv2/uvm.go Outdated Show resolved Hide resolved
internal/guest/runtime/hcsv2/uvm.go Outdated Show resolved Hide resolved
internal/guest/runtime/hcsv2/uvm.go Outdated Show resolved Hide resolved
internal/guest/runtime/hcsv2/uvm.go Outdated Show resolved Hide resolved
@kevpar
Copy link
Member

kevpar commented Nov 30, 2022

The PR title is too long for one line. Can you please format it so the title is a short description, and the PR body has a more detailed description.

Copy link
Contributor

@anmaxvl anmaxvl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I haven't gotten to resolver yet... now that we figured out what's up with the kernel, I'd really suggest splitting either into multiple commits or PRs...

internal/cosesign1/check.go Show resolved Hide resolved
internal/cosesign1/check.go Outdated Show resolved Hide resolved
internal/cosesign1/check.go Outdated Show resolved Hide resolved
internal/cosesign1/check.go Outdated Show resolved Hide resolved
internal/cosesign1/check.go Show resolved Hide resolved
internal/cosesign1/create.go Outdated Show resolved Hide resolved
internal/cosesign1/makedidx509.go Outdated Show resolved Hide resolved
internal/cosesign1/makedidx509.go Outdated Show resolved Hide resolved
internal/cosesign1/makedidx509.go Show resolved Hide resolved
internal/cosesign1/misc.go Show resolved Hide resolved
@KenGordon KenGordon changed the title Fragment COSE Sign1 support. Allows for a fragment presented by the h… Fragment COSE Sign1 support. Dec 2, 2022
@KenGordon
Copy link
Collaborator Author

KenGordon commented Dec 5, 2022 via email

internal/cosesign1/check.go Outdated Show resolved Hide resolved
internal/cosesign1/cosesign1util_test.go Show resolved Hide resolved
internal/cosesign1/makedidx509.go Outdated Show resolved Hide resolved
internal/cosesign1/misc.go Outdated Show resolved Hide resolved
internal/cosesign1/check.go Outdated Show resolved Hide resolved
internal/did-x509-resolver/resolver.go Show resolved Hide resolved
internal/did-x509-resolver/resolver.go Outdated Show resolved Hide resolved
internal/did-x509-resolver/resolver.go Show resolved Hide resolved
internal/did-x509-resolver/resolver.go Show resolved Hide resolved
internal/guest/runtime/hcsv2/uvm.go Show resolved Hide resolved
internal/cosesign1/misc.go Outdated Show resolved Hide resolved
Copy link
Contributor

@helsaawy helsaawy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, LGTM
Feel free to ignore nits for a later PR

},
cli.StringFlag{
Name: "salt",
Usage: "salt type [rand|zero] (default: rand)",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: we should probably add error checking for the salt and policy flags in a future PR, to make sure the values provided are valid.


When adding an option here which must match some security policy by default, make sure that the correct default (ie matches
a default security policy) is applied in handleSecurityPolicy. Inadvertantly adding an "option" which defaults to false but MUST be
true for a default security policy to work will force the annotation to have be set by the team that owns the box. That will
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: tab instead of space

internal/guest/storage/scsi/scsi.go Outdated Show resolved Hide resolved
to be checked for a good cert chain and a valid issuer DID that matches
the certs and so the signature. Includes DID and COSE Sign1 packages and
tooling.

Support extracting a DID directly from a COSE Sign1 document and also
support single cert COSE Sign document checking, but not DID generation.

`signutil` is a debug tool that allows generating valid DID given a
COSE Sign1 document and provides other utility functions like printing
cert chain, leaf certs, displaying COSE Sign1 document content etc.

Signed-off-by: Ken Gordon <ken.gordon@microsoft.com>
@anmaxvl anmaxvl merged commit fbcafad into microsoft:main Jan 28, 2023
@anmaxvl anmaxvl deleted the ken/squashed-did branch January 28, 2023 05:40
takuro-sato pushed a commit to takuro-sato/hcsshim that referenced this pull request Apr 25, 2023
…ost (microsoft#1575)

to be checked for a good cert chain and a valid issuer DID that matches
the certs and so the signature. Includes DID and COSE Sign1 packages and
tooling.

Support extracting a DID directly from a COSE Sign1 document and also
support single cert COSE Sign document checking, but not DID generation.

`signutil` is a debug tool that allows generating valid DID given a
COSE Sign1 document and provides other utility functions like printing
cert chain, leaf certs, displaying COSE Sign1 document content etc.

Signed-off-by: Ken Gordon <ken.gordon@microsoft.com>
takuro-sato pushed a commit to takuro-sato/hcsshim that referenced this pull request Apr 25, 2023
…ost (microsoft#1575)

to be checked for a good cert chain and a valid issuer DID that matches
the certs and so the signature. Includes DID and COSE Sign1 packages and
tooling.

Support extracting a DID directly from a COSE Sign1 document and also
support single cert COSE Sign document checking, but not DID generation.

`signutil` is a debug tool that allows generating valid DID given a
COSE Sign1 document and provides other utility functions like printing
cert chain, leaf certs, displaying COSE Sign1 document content etc.

Signed-off-by: Ken Gordon <ken.gordon@microsoft.com>
princepereira pushed a commit to princepereira/hcsshim that referenced this pull request Aug 29, 2024
…ost (microsoft#1575)

to be checked for a good cert chain and a valid issuer DID that matches
the certs and so the signature. Includes DID and COSE Sign1 packages and
tooling.

Support extracting a DID directly from a COSE Sign1 document and also
support single cert COSE Sign document checking, but not DID generation.

`signutil` is a debug tool that allows generating valid DID given a
COSE Sign1 document and provides other utility functions like printing
cert chain, leaf certs, displaying COSE Sign1 document content etc.

Signed-off-by: Ken Gordon <ken.gordon@microsoft.com>
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.

7 participants