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

Side by Side Diff: chrome/common/extensions/api/easy_unlock_private.idl

Issue 813303003: Add easyUnlockPrivate.getConnection API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 11 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
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // <code>chrome.easyUnlockPrivate</code> API that provides hooks to Chrome to 5 // <code>chrome.easyUnlockPrivate</code> API that provides hooks to Chrome to
6 // be used by Easy Unlock component app. 6 // be used by Easy Unlock component app.
7 namespace easyUnlockPrivate { 7 namespace easyUnlockPrivate {
8 // Signature algorithms supported by the crypto library methods used by 8 // Signature algorithms supported by the crypto library methods used by
9 // Easy Unlock. 9 // Easy Unlock.
10 enum SignatureType { 10 enum SignatureType {
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 // will be empty. 178 // will be empty.
179 // If the requested nonce could not be signed, |signedNonce| will be empty. 179 // If the requested nonce could not be signed, |signedNonce| will be empty.
180 // |challenge|: The sign in challenge to be used when signing in the user 180 // |challenge|: The sign in challenge to be used when signing in the user
181 // currently associated with the Easy Unlock service. 181 // currently associated with the Easy Unlock service.
182 // |signedNonce|: Nonce signed by Chrome OS TPM, provided as an argument to 182 // |signedNonce|: Nonce signed by Chrome OS TPM, provided as an argument to
183 // the |getSignInChallenge()| function and signed by the TPM key 183 // the |getSignInChallenge()| function and signed by the TPM key
184 // associated with the user. 184 // associated with the user.
185 callback SignInChallengeCallback = void(optional ArrayBuffer challenge, 185 callback SignInChallengeCallback = void(optional ArrayBuffer challenge,
186 optional ArrayBuffer signedNonce); 186 optional ArrayBuffer signedNonce);
187 187
188 // Callback for the |getConnectionInfo()| method.
189 // |rssi|: The received signal strength from the remote device in dB.
190 // |transmit_power| The local transmission power to the remote device in dB.
191 // |max_transmit_power| The maximum transmission power that can be achieved.
192 callback ConnectionInfoCallback = void(
193 long rssi, long transmit_power, long max_transmit_power);
194
188 interface Functions { 195 interface Functions {
189 // Gets localized strings required to render the API. 196 // Gets localized strings required to render the API.
190 // 197 //
191 // |callback| : Called with a dictionary mapping names to resource strings. 198 // |callback| : Called with a dictionary mapping names to resource strings.
192 // TODO(isherman): This is essentially copied from identity_private.idl. 199 // TODO(isherman): This is essentially copied from identity_private.idl.
193 // Perhaps this should be extracted to a common API instead? 200 // Perhaps this should be extracted to a common API instead?
194 static void getStrings(GetStringsCallback callback); 201 static void getStrings(GetStringsCallback callback);
195 202
196 // Generates a ECDSA key pair for P256 curve. 203 // Generates a ECDSA key pair for P256 curve.
197 // Public key will be in format recognized by secure wire transport protocol 204 // Public key will be in format recognized by secure wire transport protocol
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 // success, the user session will be started. 315 // success, the user session will be started.
309 static void trySignInSecret(ArrayBuffer signInSecret, 316 static void trySignInSecret(ArrayBuffer signInSecret,
310 EmptyCallback callback); 317 EmptyCallback callback);
311 318
312 // Retrieves information about the user associated with the Easy unlock 319 // Retrieves information about the user associated with the Easy unlock
313 // service. 320 // service.
314 static void getUserInfo(GetUserInfoCallback callback); 321 static void getUserInfo(GetUserInfoCallback callback);
315 322
316 // Gets the user's profile image as a bitmap. 323 // Gets the user's profile image as a bitmap.
317 static void getUserImage(DataCallback callback); 324 static void getUserImage(DataCallback callback);
325
326 // Gets the connection info for the Bluetooth device identified by
327 // deviceAddress.
328 static void getConnectionInfo(DOMString deviceAddress,
329 ConnectionInfoCallback callback);
318 }; 330 };
319 331
320 interface Events { 332 interface Events {
321 // Event fired when the data for the user currently associated with 333 // Event fired when the data for the user currently associated with
322 // Easy unlock service is updated. 334 // Easy unlock service is updated.
323 // |userInfo| The updated user information. 335 // |userInfo| The updated user information.
324 static void onUserInfoUpdated(UserInfo userInfo); 336 static void onUserInfoUpdated(UserInfo userInfo);
325 }; 337 };
326 }; 338 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698