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

Side by Side Diff: components/webauth/authenticator.mojom

Issue 2702653002: Patch #1 of multiple. Add webauth .mojom and initial usage of makeCredential. (Closed)
Patch Set: Capitalizing mojom interface method Created 3 years, 8 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 [JavaPackage="org.chromium.webauth.mojom"]
6 module webauth.mojom;
7
8 // This file describes the communication between the WebAuthentication renderer
9 // implementation and browser-side implementations to create scoped credentials
10 // and use already-created credentials to get assertions.
11 // See https://w3c.github.io/webauthn/.
12
13 // The public key and attestation that is returned by an authenticator's
14 // call to makeCredential.
15 struct ScopedCredentialInfo {
16 array<uint8> client_data;
17 array<uint8> attestation;
18 };
19
20 // Information about the relying party and the user account held by that
21 // relying party. This information is used by the authenticator to create
22 // or retrieve an appropriate scoped credential for this account.
23 struct RelyingPartyAccount {
24 string relying_party_display_name;
ikilpatrick 2017/04/24 22:11:44 Did this get changed in the spec? \o/ ?
kpaulhamus 2017/04/25 00:03:08 Welll.. it did... but this whole structure is actu
25 string display_name;
26 string id;
27 string name;
28 string image_url;
29 };
30
31 // Parameters that are used to generate an appropriate scoped credential.
32 struct ScopedCredentialParameters {
33 ScopedCredentialType type;
34 // TODO(kpaulhamus): add AlgorithmIdentifier algorithm;
35 };
36
37 // Optional parameters that are used during makeCredential.
38 struct ScopedCredentialOptions {
39 int32 timeout_seconds;
40 string relying_party_id;
41 array<ScopedCredentialDescriptor> exclude_list;
42 // TODO(kpaulhamus): add Extensions
43 };
44
45 enum ScopedCredentialType {
46 SCOPEDCRED,
47 };
48
49 // Describes the credentials that the relying party already knows about for
50 // the given account. If any of these are known to the authenticator,
51 // it should not create a new credential.
52 struct ScopedCredentialDescriptor {
53 ScopedCredentialType type;
54 array<uint8> id;
55 array<Transport> transports;
56 };
57
58 enum Transport {
59 USB,
60 NFC,
61 BLE,
62 };
63
64 // Interface to direct authenticators to create or use a scoped credential.
65 interface Authenticator {
66 // Gets the credential info for a new credential created by an authenticator
67 // for the given relying party and account.
68 MakeCredential(RelyingPartyAccount account_information,
69 array<ScopedCredentialParameters> crypto_parameters,
70 array<uint8> attestation_challenge,
71 ScopedCredentialOptions? options)
72 => (array<ScopedCredentialInfo> scoped_credentials);
73 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698