Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(97)

Unified Diff: components/webauth/authenticator.mojom

Issue 2788823002: Add the Mojo implementation of authenticator.mojom's MakeCredential. (Closed)
Patch Set: Addressing mkwst comments Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/webauth/DEPS ('k') | components/webauth/authenticator_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/webauth/authenticator.mojom
diff --git a/components/webauth/authenticator.mojom b/components/webauth/authenticator.mojom
index 1bf69a9796dadf18fd326a94ff19cd322f144fb5..4a38c14ca6919bbe52e5bd8ff5b042f7cbd5ed1e 100644
--- a/components/webauth/authenticator.mojom
+++ b/components/webauth/authenticator.mojom
@@ -10,6 +10,15 @@ module webauth.mojom;
// and use already-created credentials to get assertions.
// See https://w3c.github.io/webauthn/.
+enum AuthenticatorStatus {
+ SUCCESS,
+ CANCELLED,
+ UNKNOWN_ERROR,
+ NOT_ALLOWED_ERROR,
+ NOT_SUPPORTED_ERROR,
+ SECURITY_ERROR,
+};
+
// The public key and attestation that is returned by an authenticator's
// call to makeCredential.
struct ScopedCredentialInfo {
@@ -24,7 +33,6 @@ struct ScopedCredentialInfo {
// relying party. This information is used by the authenticator to create
// or retrieve an appropriate scoped credential for this account.
// These fields take arbitrary input.
-
struct RelyingPartyAccount {
// Friendly name of the Relying Party, e.g. "Acme Corporation"
string relying_party_display_name;
@@ -34,10 +42,10 @@ struct RelyingPartyAccount {
// per authenticator and Relying Party.
string id;
// Detailed name for the account, e.g. john.p.smith@example.com
- string name;
+ string? name;
// User image, if any.
- // Todo make this url.mojom.Url in a followup CL
- string image_url;
+ // TODO(kpaulhamus): make this url.mojom.Url in a followup CL
+ string? image_url;
};
// Parameters that are used to generate an appropriate scoped credential.
@@ -49,8 +57,8 @@ struct ScopedCredentialParameters {
// Optional parameters that are used during makeCredential.
struct ScopedCredentialOptions {
//TODO(kpaulhamus): Make this mojo.common.mojom.TimeDelta in followup CL
- int32 timeout_seconds;
- string relying_party_id;
+ double adjusted_timeout;
+ string? relying_party_id;
array<ScopedCredentialDescriptor> exclude_list;
// TODO(kpaulhamus): add Extensions
};
@@ -84,6 +92,7 @@ interface Authenticator {
MakeCredential(RelyingPartyAccount account_information,
array<ScopedCredentialParameters> crypto_parameters,
array<uint8> attestation_challenge,
- ScopedCredentialOptions? options)
- => (array<ScopedCredentialInfo> scoped_credentials);
+ ScopedCredentialOptions options)
+ => (AuthenticatorStatus status,
+ ScopedCredentialInfo? scoped_credential);
};
« no previous file with comments | « components/webauth/DEPS ('k') | components/webauth/authenticator_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698