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

feat: Android Key attestation format support #126

Merged
merged 1 commit into from
Mar 15, 2019

Conversation

bdewater
Copy link
Collaborator

This implements https://www.w3.org/TR/webauthn/#android-key-attestation and fixes #84

Since the certificates in the payload do not contain a root certificate, we'll need to implement the metadata service to assess trustworthiness of the attestation. See #66 for tracking this feature.

@bdewater bdewater force-pushed the android-key-attestation branch 2 times, most recently from f0ca8aa to 8595746 Compare March 10, 2019 21:49
credential_creation_options: {
challenge: 'v2h1c2VybmFtZXQ0aV9ObTRobjFDeEkwSGc3OHhzTWljaGFsbGVuZ2VQtubEDC4OSpGHebHLLNerFf8'
},
authenticator_attestation_response: {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Generated by https://fidoalliance.org/certification/functional-certification/conformance/ and these certificates have a expiry set in the far future.

@bdewater
Copy link
Collaborator Author

Might want to hold off until #127 is merged so I can add a AAGUID test here too.

@grzuy
Copy link
Contributor

grzuy commented Mar 11, 2019

Awesome! Thank you!

I'll try code review sometime this week.

@bdewater
Copy link
Collaborator Author

I added an AAGUID test here but the tests broke because cose 0.4 was released 😅 everything works locally.

@grzuy
Copy link
Contributor

grzuy commented Mar 13, 2019

Yeah, ~> 0.1 was too loose.
Fixed now in master after #129.

Copy link
Contributor

@grzuy grzuy left a comment

Choose a reason for hiding this comment

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

Looks great!

Just left this one recommendation. Let me know if you agree that could be useful.

valid_attestation_challenge?(client_data_hash) &&
all_applications_field_not_present? &&
valid_authorization_list_origin? &&
valid_authorization_list_purpose? &&
Copy link
Contributor

Choose a reason for hiding this comment

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

I wonder if we could create an abstraction for what's called in the spec "attestation certificate extension data", and call valid? on that, moving these 3 from the above inside there, to divide a bit the complexity into separate objects.

Copy link
Contributor

Choose a reason for hiding this comment

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

Not blocking the merge because of this one.
If we like the idea we can do it as a follow up PR.

@grzuy grzuy merged commit 30b711e into cedarcode:master Mar 15, 2019
@grzuy
Copy link
Contributor

grzuy commented Mar 15, 2019

Released in v1.11.0.

@bdewater bdewater deleted the android-key-attestation branch March 15, 2019 17:02
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.

Verify "android-key" attestation statement format
2 participants