Allow supervised users to delete profiles in about:settings.
[chromium-blink-merge.git] / ppapi / api / private / ppb_platform_verification_private.idl
blob87df6af7e227ee70a8468c9e86f5fbc35a0f5297
1 /* Copyright 2013 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 */
6 /**
7 * This file defines the API for platform verification. Currently, it only
8 * supports Chrome OS.
9 */
11 [generate_thunk]
13 label Chrome {
14 M32 = 0.2
17 /**
18 * The <code>PPB_PlatformVerification_Private</code> interface allows authorized
19 * services to verify that the underlying platform is trusted. An example of a
20 * trusted platform is a Chrome OS device in verified boot mode.
23 interface PPB_PlatformVerification_Private {
24 /**
25 * Create() creates a <code>PPB_PlatformVerification_Private</code> object.
27 * @pram[in] instance A <code>PP_Instance</code> identifying one instance of
28 * a module.
30 * @return A <code>PP_Resource</code> corresponding to a
31 * <code>PPB_PlatformVerification_Private</code> if successful, 0 if creation
32 * failed.
34 PP_Resource Create([in] PP_Instance instance);
36 /**
37 * IsPlatformVerification() determines if the provided resource is a
38 * <code>PPB_PlatformVerification_Private</code>.
40 * @param[in] resource A <code>PP_Resource</code> corresponding to a
41 * <code>PPB_PlatformVerification_Private</code>.
43 * @return <code>PP_TRUE</code> if the resource is a
44 * <code>PPB_PlatformVerification_Private</code>, <code>PP_FALSE</code> if the
45 * resource is invalid or some type other than
46 * <code>PPB_PlatformVerification_Private</code>.
48 PP_Bool IsPlatformVerification([in] PP_Resource resource);
50 /**
51 * Requests a platform challenge for a given service id.
53 * @param[in] service_id A <code>PP_Var</code> of type
54 * <code>PP_VARTYPE_STRING</code> containing the service_id for the challenge.
56 * @param[in] challenge A <code>PP_Var</code> of type
57 * <code>PP_VARTYPE_ARRAY_BUFFER</code> that contains the challenge data.
59 * @param[out] signed_data A <code>PP_Var</code> of type
60 * <code>PP_VARTYPE_ARRAY_BUFFER</code> that contains the data signed by the
61 * platform.
63 * @param[out] signed_data_signature A <code>PP_Var</code> of type
64 * <code>PP_VARTYPE_ARRAY_BUFFER</code> that contains the signature of the
65 * signed data block.
67 * @param[out] platform_key_certificate A <code>PP_Var</code> of type
68 * <code>PP_VARTYPE_STRING</code> that contains the device specific
69 * certificate for the requested service_id.
71 * @param[in] callback A <code>PP_CompletionCallback</code> to be called after
72 * the platform challenge has been completed. This callback will only run if
73 * the return code is <code>PP_OK_COMPLETIONPENDING</code>.
75 * @return An int32_t containing an error code from <code>pp_errors.h</code>.
77 int32_t ChallengePlatform(
78 [in] PP_Resource instance,
79 [in] PP_Var service_id,
80 [in] PP_Var challenge,
81 [out] PP_Var signed_data,
82 [out] PP_Var signed_data_signature,
83 [out] PP_Var platform_key_certificate,
84 [in] PP_CompletionCallback callback);