summaryrefslogtreecommitdiffstats
path: root/ppapi
diff options
context:
space:
mode:
authorjrummell <jrummell@chromium.org>2015-01-08 14:35:43 -0800
committerCommit bot <commit-bot@chromium.org>2015-01-08 22:36:50 +0000
commita68c98fe5d09235cdfff39176964e10ac2074a6b (patch)
tree76a322aac7228e577ec7520918f0fe543f6433c4 /ppapi
parent2e8ed92e162ff1684b4f97fc7a9bbdaa2d78451b (diff)
downloadchromium_src-a68c98fe5d09235cdfff39176964e10ac2074a6b.zip
chromium_src-a68c98fe5d09235cdfff39176964e10ac2074a6b.tar.gz
chromium_src-a68c98fe5d09235cdfff39176964e10ac2074a6b.tar.bz2
Changes to support CDM_7
Add support for CDM_7 and update Pepper to support the updated interface. Changes: - Rename CreateSession() to CreateSessionAndGenerateRequest() with reordered parameter list. - Add |session_type| to LoadSession(). - OnSessionMessage() adds |message_type|, removes |destination_url|. - OnSessionKeysChange() adds |key_information|. - Remove GetUsableKeyIds() - Remove OnPromiseResolvedWithKeyIds() - Remove OnSessionReady(). BUG=428384 TEST=existing EME test cases pass Review URL: https://codereview.chromium.org/811923002 Cr-Commit-Position: refs/heads/master@{#310615}
Diffstat (limited to 'ppapi')
-rw-r--r--ppapi/api/private/pp_content_decryptor.idl47
-rw-r--r--ppapi/api/private/ppb_content_decryptor_private.idl56
-rw-r--r--ppapi/api/private/ppp_content_decryptor_private.idl44
-rw-r--r--ppapi/c/pp_macros.h4
-rw-r--r--ppapi/c/private/pp_content_decryptor.h54
-rw-r--r--ppapi/c/private/ppb_content_decryptor_private.h62
-rw-r--r--ppapi/c/private/ppp_content_decryptor_private.h56
-rw-r--r--ppapi/cpp/private/content_decryptor_private.cc87
-rw-r--r--ppapi/cpp/private/content_decryptor_private.h23
-rw-r--r--ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c232
-rw-r--r--ppapi/proxy/ppapi_messages.h42
-rw-r--r--ppapi/proxy/ppapi_param_traits.cc46
-rw-r--r--ppapi/proxy/ppapi_param_traits.h9
-rw-r--r--ppapi/proxy/ppb_instance_proxy.cc140
-rw-r--r--ppapi/proxy/ppb_instance_proxy.h39
-rw-r--r--ppapi/proxy/ppp_content_decryptor_private_proxy.cc93
-rw-r--r--ppapi/proxy/ppp_content_decryptor_private_proxy.h15
-rw-r--r--ppapi/thunk/interfaces_ppb_private.h4
-rw-r--r--ppapi/thunk/ppb_content_decryptor_private_thunk.cc50
-rw-r--r--ppapi/thunk/ppb_instance_api.h18
20 files changed, 491 insertions, 630 deletions
diff --git a/ppapi/api/private/pp_content_decryptor.idl b/ppapi/api/private/pp_content_decryptor.idl
index 4493c3e..ee7a631 100644
--- a/ppapi/api/private/pp_content_decryptor.idl
+++ b/ppapi/api/private/pp_content_decryptor.idl
@@ -406,7 +406,8 @@ enum PP_DecryptorStreamType {
[assert_size(4)]
enum PP_SessionType {
PP_SESSIONTYPE_TEMPORARY = 0,
- PP_SESSIONTYPE_PERSISTENT = 1
+ PP_SESSIONTYPE_PERSISTENT_LICENSE = 1,
+ PP_SESSIONTYPE_PERSISTENT_RELEASE = 2
};
/**
@@ -422,3 +423,47 @@ enum PP_CdmExceptionCode {
PP_CDMEXCEPTIONCODE_CLIENTERROR = 6,
PP_CDMEXCEPTIONCODE_OUTPUTERROR = 7
};
+
+/**
+ * <code>PP_CdmMessageType</code> contains message type constants.
+ */
+[assert_size(4)]
+enum PP_CdmMessageType {
+ PP_CDMMESSAGETYPE_LICENSE_REQUEST = 0,
+ PP_CDMMESSAGETYPE_LICENSE_RENEWAL = 1,
+ PP_CDMMESSAGETYPE_LICENSE_RELEASE = 2
+};
+
+/**
+ * <code>PP_CdmKeyStatus</code> contains key status constants.
+ */
+[assert_size(4)]
+enum PP_CdmKeyStatus {
+ PP_CDMKEYSTATUS_USABLE = 0,
+ PP_CDMKEYSTATUS_INVALID = 1,
+ PP_CDMKEYSTATUS_EXPIRED = 2,
+ PP_CDMKEYSTATUS_OUTPUTNOTALLOWED = 3
+};
+
+/**
+ * The <code>PP_KeyInformation</code> struct contains information about a
+ * key used for decryption.
+ */
+[assert_size(524)]
+struct PP_KeyInformation {
+ /**
+ * Key ID.
+ */
+ uint8_t[512] key_id;
+ uint32_t key_id_size;
+
+ /**
+ * Status of this key.
+ */
+ PP_CdmKeyStatus key_status;
+
+ /**
+ * Optional error code for keys that are not usable.
+ */
+ uint32_t system_code;
+};
diff --git a/ppapi/api/private/ppb_content_decryptor_private.idl b/ppapi/api/private/ppb_content_decryptor_private.idl
index ad59210..49cc0b3 100644
--- a/ppapi/api/private/ppb_content_decryptor_private.idl
+++ b/ppapi/api/private/ppb_content_decryptor_private.idl
@@ -12,7 +12,7 @@
[generate_thunk]
label Chrome {
- M36 = 0.12
+ M41 = 0.13
};
/**
@@ -45,19 +45,6 @@ interface PPB_ContentDecryptor_Private {
[in] uint32_t promise_id,
[in] PP_Var web_session_id);
- /**
- * A promise that returns a set of key IDs has been resolved by the CDM.
- *
- * @param[in] promise_id Identifies the promise that the CDM resolved.
- *
- * @param[in] key_ids A <code>PP_Var</code> of type
- * <code>PP_VARTYPE_ARRAY</code> containing elements of type
- * <code>PP_VARTYPE_ARRAYBUFFER</code> that are the session's usable key IDs.
- */
- void PromiseResolvedWithKeyIds(
- [in] PP_Instance instance,
- [in] uint32_t promise_id,
- [in] PP_Var key_ids_array);
/**
* A promise has been rejected by the CDM due to an error.
@@ -97,18 +84,17 @@ interface PPB_ContentDecryptor_Private {
* <code>PP_VARTYPE_STRING</code> containing the ID of a session for
* which this message is intended.
*
+ * @param[in] message_type A <code>PP_CdmMessageType</code> containing the
+ * message type.
+ *
* @param[in] message A <code>PP_Var</code> of type
* <code>PP_VARTYPE_ARRAY_BUFFER</code> that contains the message.
- *
- * @param[in] destination_url A <code>PP_Var</code> of type
- * <code>PP_VARTYPE_STRING</code> containing the destination URL for the
- * message.
*/
void SessionMessage(
[in] PP_Instance instance,
[in] PP_Var web_session_id,
- [in] PP_Var message,
- [in] PP_Var destination_url);
+ [in] PP_CdmMessageType message_type,
+ [in] PP_Var message);
/**
* The keys for a session have changed.
@@ -119,11 +105,19 @@ interface PPB_ContentDecryptor_Private {
*
* @param[in] has_additional_usable_key A <code>PP_Bool</code> indicating if
* a new usable key has been added.
+ *
+ * @param[in] key_count The number of arguments contained in
+ * <code>key_information</code>
+ *
+ * @param[in] key_information An array of type <code>PP_KeyInformation</code>
+ * that are the session's key IDs and their status.
*/
void SessionKeysChange(
[in] PP_Instance instance,
[in] PP_Var web_session_id,
- [in] PP_Bool has_additional_usable_key);
+ [in] PP_Bool has_additional_usable_key,
+ [in] uint32_t key_count,
+ [in, size_as=key_count] PP_KeyInformation[] key_information);
/**
* The expiration time for a session has changed.
@@ -142,26 +136,6 @@ interface PPB_ContentDecryptor_Private {
[in] PP_Time new_expiry_time);
/**
- * The session is now ready to decrypt the media stream.
- *
- * Note: The above describes the most simple case. Depending on the key
- * system, a series of <code>SessionMessage()</code> calls from the CDM will
- * be sent to the browser, and then on to the web application. The web
- * application must then provide more data to the CDM by directing the browser
- * to pass the data to the CDM via calls to <code>UpdateSession()</code> on
- * the <code>PPP_ContentDecryptor_Private</code> interface.
- * The CDM must call <code>SessionReady()</code> when the sequence is
- * completed, and, in response, the browser must notify the web application.
- *
- * @param[in] web_session_id A <code>PP_Var</code> of type
- * <code>PP_VARTYPE_STRING</code> containing the session's ID attribute of
- * the session that is now ready.
- */
- void SessionReady(
- [in] PP_Instance instance,
- [in] PP_Var web_session_id);
-
- /**
* The session has been closed as the result of a call to the
* <code>ReleaseSession()</code> method on the
* <code>PPP_ContentDecryptor_Private</code> interface, or due to other
diff --git a/ppapi/api/private/ppp_content_decryptor_private.idl b/ppapi/api/private/ppp_content_decryptor_private.idl
index 46fc701..77ab49c 100644
--- a/ppapi/api/private/ppp_content_decryptor_private.idl
+++ b/ppapi/api/private/ppp_content_decryptor_private.idl
@@ -9,7 +9,7 @@
* Decryption Modules, not normal plugins.
*/
label Chrome {
- M36 = 0.12
+ M41 = 0.13
};
/**
@@ -46,33 +46,34 @@ interface PPP_ContentDecryptor_Private {
[in] PP_Var server_certificate);
/**
- * Creates a session. <code>init_data_type</code> contains the MIME type of
+ * Creates a session and subsequently generates a request for a license.
+ * <code>init_data_type</code> contains the MIME type of
* <code>init_data</code>. <code>init_data</code> is a data buffer
* containing data for use in generating the request.
*
- * Note: <code>CreateSession()</code> must create a web session ID and provide
- * it to the browser via <code>SessionCreated()</code> on the
- * <code>PPB_ContentDecryptor_Private</code> interface.
+ * Note: <code>CreateSessionAndGenerateRequest()</code> must create a web
+ * session ID and provide it to the browser via <code>SessionCreated()</code>
+ * on the <code>PPB_ContentDecryptor_Private</code> interface.
*
* @param[in] promise_id A reference for the promise that gets resolved or
* rejected depending upon the success or failure when creating the session.
*
+ * @param[in] session_type A <code>PP_SessionType</code> that indicates the
+ * type of session to be created.
+ *
* @param[in] init_data_type A <code>PP_Var</code> of type
* <code>PP_VARTYPE_STRING</code> containing the MIME type for init_data.
*
* @param[in] init_data A <code>PP_Var</code> of type
* <code>PP_VARTYPE_ARRAYBUFFER</code> containing container specific
* initialization data.
- *
- * @param[in] session_type A <code>PP_SessionType</code> that indicates the
- * type of session to be created.
*/
- void CreateSession(
+ void CreateSessionAndGenerateRequest(
[in] PP_Instance instance,
[in] uint32_t promise_id,
+ [in] PP_SessionType session_type,
[in] PP_Var init_data_type,
- [in] PP_Var init_data,
- [in] PP_SessionType session_type);
+ [in] PP_Var init_data);
/**
* Loads a session whose web session ID is <code>web_session_id</code>.
@@ -84,6 +85,9 @@ interface PPP_ContentDecryptor_Private {
* @param[in] promise_id A reference for the promise that gets resolved or
* rejected depending upon the success or failure of loading the session.
*
+ * @param[in] session_type A <code>PP_SessionType</code> that indicates the
+ * type of session to be loaded.
+ *
* @param[in] web_session_id A <code>PP_Var</code> of type
* <code>PP_VARTYPE_STRING</code> containing the web session ID of the session
* to load.
@@ -91,6 +95,7 @@ interface PPP_ContentDecryptor_Private {
void LoadSession(
[in] PP_Instance instance,
[in] uint32_t promise_id,
+ [in] PP_SessionType session_type,
[in] PP_Var web_session_id);
/**
@@ -156,23 +161,6 @@ interface PPP_ContentDecryptor_Private {
[in] PP_Var web_session_id);
/**
- * Get the key IDs for keys in the session that the CDM knows are currently
- * usable to decrypt media data.
- *
- * @param[in] promise_id A reference for the promise that gets resolved or
- * rejected depending upon the success or failure of obtaining the key IDs.
- *
- * @param[in] web_session_id A <code>PP_Var</code> of type
- * <code>PP_VARTYPE_STRING</code> containing the web session ID of the session
- * to be queried.
- *
- */
- void GetUsableKeyIds(
- [in] PP_Instance instance,
- [in] uint32_t promise_id,
- [in] PP_Var web_session_id);
-
- /**
* Decrypts the block and returns the unencrypted block via
* <code>DeliverBlock()</code> on the
* <code>PPB_ContentDecryptor_Private</code> interface. The returned block
diff --git a/ppapi/c/pp_macros.h b/ppapi/c/pp_macros.h
index 7d75eba..91f7a90 100644
--- a/ppapi/c/pp_macros.h
+++ b/ppapi/c/pp_macros.h
@@ -3,13 +3,13 @@
* found in the LICENSE file.
*/
-/* From pp_macros.idl modified Thu Sep 18 11:36:39 2014. */
+/* From pp_macros.idl modified Thu Jun 26 10:08:35 2014. */
#ifndef PPAPI_C_PP_MACROS_H_
#define PPAPI_C_PP_MACROS_H_
-#define PPAPI_RELEASE 40
+#define PPAPI_RELEASE 41
/**
* @file
diff --git a/ppapi/c/private/pp_content_decryptor.h b/ppapi/c/private/pp_content_decryptor.h
index 971d2a0..6e03ed5 100644
--- a/ppapi/c/private/pp_content_decryptor.h
+++ b/ppapi/c/private/pp_content_decryptor.h
@@ -3,7 +3,7 @@
* found in the LICENSE file.
*/
-/* From private/pp_content_decryptor.idl modified Thu Jun 5 13:39:15 2014. */
+/* From private/pp_content_decryptor.idl modified Wed Jan 7 18:40:14 2015. */
#ifndef PPAPI_C_PRIVATE_PP_CONTENT_DECRYPTOR_H_
#define PPAPI_C_PRIVATE_PP_CONTENT_DECRYPTOR_H_
@@ -455,7 +455,8 @@ PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_DecryptorStreamType, 4);
*/
typedef enum {
PP_SESSIONTYPE_TEMPORARY = 0,
- PP_SESSIONTYPE_PERSISTENT = 1
+ PP_SESSIONTYPE_PERSISTENT_LICENSE = 1,
+ PP_SESSIONTYPE_PERSISTENT_RELEASE = 2
} PP_SessionType;
PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_SessionType, 4);
@@ -472,6 +473,55 @@ typedef enum {
PP_CDMEXCEPTIONCODE_OUTPUTERROR = 7
} PP_CdmExceptionCode;
PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_CdmExceptionCode, 4);
+
+/**
+ * <code>PP_CdmMessageType</code> contains message type constants.
+ */
+typedef enum {
+ PP_CDMMESSAGETYPE_LICENSE_REQUEST = 0,
+ PP_CDMMESSAGETYPE_LICENSE_RENEWAL = 1,
+ PP_CDMMESSAGETYPE_LICENSE_RELEASE = 2
+} PP_CdmMessageType;
+PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_CdmMessageType, 4);
+
+/**
+ * <code>PP_CdmKeyStatus</code> contains key status constants.
+ */
+typedef enum {
+ PP_CDMKEYSTATUS_USABLE = 0,
+ PP_CDMKEYSTATUS_INVALID = 1,
+ PP_CDMKEYSTATUS_EXPIRED = 2,
+ PP_CDMKEYSTATUS_OUTPUTNOTALLOWED = 3
+} PP_CdmKeyStatus;
+PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_CdmKeyStatus, 4);
+/**
+ * @}
+ */
+
+/**
+ * @addtogroup Structs
+ * @{
+ */
+/**
+ * The <code>PP_KeyInformation</code> struct contains information about a
+ * key used for decryption.
+ */
+struct PP_KeyInformation {
+ /**
+ * Key ID.
+ */
+ uint8_t key_id[512];
+ uint32_t key_id_size;
+ /**
+ * Status of this key.
+ */
+ PP_CdmKeyStatus key_status;
+ /**
+ * Optional error code for keys that are not usable.
+ */
+ uint32_t system_code;
+};
+PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_KeyInformation, 524);
/**
* @}
*/
diff --git a/ppapi/c/private/ppb_content_decryptor_private.h b/ppapi/c/private/ppb_content_decryptor_private.h
index 5665806..3b7d309 100644
--- a/ppapi/c/private/ppb_content_decryptor_private.h
+++ b/ppapi/c/private/ppb_content_decryptor_private.h
@@ -4,7 +4,7 @@
*/
/* From private/ppb_content_decryptor_private.idl,
- * modified Mon Aug 25 13:52:39 2014.
+ * modified Wed Jan 7 16:48:10 2015.
*/
#ifndef PPAPI_C_PRIVATE_PPB_CONTENT_DECRYPTOR_PRIVATE_H_
@@ -19,10 +19,10 @@
#include "ppapi/c/pp_var.h"
#include "ppapi/c/private/pp_content_decryptor.h"
-#define PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_12 \
- "PPB_ContentDecryptor_Private;0.12"
+#define PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_13 \
+ "PPB_ContentDecryptor_Private;0.13"
#define PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE \
- PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_12
+ PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_13
/**
* @file
@@ -43,7 +43,7 @@
* browser side support for the Content Decryption Module (CDM) for Encrypted
* Media Extensions: http://www.w3.org/TR/encrypted-media/
*/
-struct PPB_ContentDecryptor_Private_0_12 {
+struct PPB_ContentDecryptor_Private_0_13 {
/**
* A promise has been resolved by the CDM.
*
@@ -62,18 +62,6 @@ struct PPB_ContentDecryptor_Private_0_12 {
uint32_t promise_id,
struct PP_Var web_session_id);
/**
- * A promise that returns a set of key IDs has been resolved by the CDM.
- *
- * @param[in] promise_id Identifies the promise that the CDM resolved.
- *
- * @param[in] key_ids A <code>PP_Var</code> of type
- * <code>PP_VARTYPE_ARRAY</code> containing elements of type
- * <code>PP_VARTYPE_ARRAYBUFFER</code> that are the session's usable key IDs.
- */
- void (*PromiseResolvedWithKeyIds)(PP_Instance instance,
- uint32_t promise_id,
- struct PP_Var key_ids_array);
- /**
* A promise has been rejected by the CDM due to an error.
*
* @param[in] promise_id Identifies the promise that the CDM rejected.
@@ -109,17 +97,16 @@ struct PPB_ContentDecryptor_Private_0_12 {
* <code>PP_VARTYPE_STRING</code> containing the ID of a session for
* which this message is intended.
*
+ * @param[in] message_type A <code>PP_CdmMessageType</code> containing the
+ * message type.
+ *
* @param[in] message A <code>PP_Var</code> of type
* <code>PP_VARTYPE_ARRAY_BUFFER</code> that contains the message.
- *
- * @param[in] destination_url A <code>PP_Var</code> of type
- * <code>PP_VARTYPE_STRING</code> containing the destination URL for the
- * message.
*/
void (*SessionMessage)(PP_Instance instance,
struct PP_Var web_session_id,
- struct PP_Var message,
- struct PP_Var destination_url);
+ PP_CdmMessageType message_type,
+ struct PP_Var message);
/**
* The keys for a session have changed.
*
@@ -129,10 +116,18 @@ struct PPB_ContentDecryptor_Private_0_12 {
*
* @param[in] has_additional_usable_key A <code>PP_Bool</code> indicating if
* a new usable key has been added.
+ *
+ * @param[in] key_count The number of arguments contained in
+ * <code>key_information</code>
+ *
+ * @param[in] key_information An array of type <code>PP_KeyInformation</code>
+ * that are the session's key IDs and their status.
*/
void (*SessionKeysChange)(PP_Instance instance,
struct PP_Var web_session_id,
- PP_Bool has_additional_usable_key);
+ PP_Bool has_additional_usable_key,
+ uint32_t key_count,
+ const struct PP_KeyInformation key_information[]);
/**
* The expiration time for a session has changed.
*
@@ -148,23 +143,6 @@ struct PPB_ContentDecryptor_Private_0_12 {
struct PP_Var web_session_id,
PP_Time new_expiry_time);
/**
- * The session is now ready to decrypt the media stream.
- *
- * Note: The above describes the most simple case. Depending on the key
- * system, a series of <code>SessionMessage()</code> calls from the CDM will
- * be sent to the browser, and then on to the web application. The web
- * application must then provide more data to the CDM by directing the browser
- * to pass the data to the CDM via calls to <code>UpdateSession()</code> on
- * the <code>PPP_ContentDecryptor_Private</code> interface.
- * The CDM must call <code>SessionReady()</code> when the sequence is
- * completed, and, in response, the browser must notify the web application.
- *
- * @param[in] web_session_id A <code>PP_Var</code> of type
- * <code>PP_VARTYPE_STRING</code> containing the session's ID attribute of
- * the session that is now ready.
- */
- void (*SessionReady)(PP_Instance instance, struct PP_Var web_session_id);
- /**
* The session has been closed as the result of a call to the
* <code>ReleaseSession()</code> method on the
* <code>PPP_ContentDecryptor_Private</code> interface, or due to other
@@ -325,7 +303,7 @@ struct PPB_ContentDecryptor_Private_0_12 {
const struct PP_DecryptedSampleInfo* decrypted_sample_info);
};
-typedef struct PPB_ContentDecryptor_Private_0_12 PPB_ContentDecryptor_Private;
+typedef struct PPB_ContentDecryptor_Private_0_13 PPB_ContentDecryptor_Private;
/**
* @}
*/
diff --git a/ppapi/c/private/ppp_content_decryptor_private.h b/ppapi/c/private/ppp_content_decryptor_private.h
index 145d843..4945ab2 100644
--- a/ppapi/c/private/ppp_content_decryptor_private.h
+++ b/ppapi/c/private/ppp_content_decryptor_private.h
@@ -4,7 +4,7 @@
*/
/* From private/ppp_content_decryptor_private.idl,
- * modified Mon Aug 25 14:02:40 2014.
+ * modified Fri Dec 19 15:58:46 2014.
*/
#ifndef PPAPI_C_PRIVATE_PPP_CONTENT_DECRYPTOR_PRIVATE_H_
@@ -18,10 +18,10 @@
#include "ppapi/c/pp_var.h"
#include "ppapi/c/private/pp_content_decryptor.h"
-#define PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_12 \
- "PPP_ContentDecryptor_Private;0.12"
+#define PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_13 \
+ "PPP_ContentDecryptor_Private;0.13"
#define PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE \
- PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_12
+ PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_13
/**
* @file
@@ -42,7 +42,7 @@
* Decryption Module (CDM) for Encrypted Media Extensions:
* http://www.w3.org/TR/encrypted-media/
*/
-struct PPP_ContentDecryptor_Private_0_12 {
+struct PPP_ContentDecryptor_Private_0_13 {
/**
* Initialize for the specified key system.
*
@@ -64,32 +64,33 @@ struct PPP_ContentDecryptor_Private_0_12 {
uint32_t promise_id,
struct PP_Var server_certificate);
/**
- * Creates a session. <code>init_data_type</code> contains the MIME type of
+ * Creates a session and subsequently generates a request for a license.
+ * <code>init_data_type</code> contains the MIME type of
* <code>init_data</code>. <code>init_data</code> is a data buffer
* containing data for use in generating the request.
*
- * Note: <code>CreateSession()</code> must create a web session ID and provide
- * it to the browser via <code>SessionCreated()</code> on the
- * <code>PPB_ContentDecryptor_Private</code> interface.
+ * Note: <code>CreateSessionAndGenerateRequest()</code> must create a web
+ * session ID and provide it to the browser via <code>SessionCreated()</code>
+ * on the <code>PPB_ContentDecryptor_Private</code> interface.
*
* @param[in] promise_id A reference for the promise that gets resolved or
* rejected depending upon the success or failure when creating the session.
*
+ * @param[in] session_type A <code>PP_SessionType</code> that indicates the
+ * type of session to be created.
+ *
* @param[in] init_data_type A <code>PP_Var</code> of type
* <code>PP_VARTYPE_STRING</code> containing the MIME type for init_data.
*
* @param[in] init_data A <code>PP_Var</code> of type
* <code>PP_VARTYPE_ARRAYBUFFER</code> containing container specific
* initialization data.
- *
- * @param[in] session_type A <code>PP_SessionType</code> that indicates the
- * type of session to be created.
*/
- void (*CreateSession)(PP_Instance instance,
- uint32_t promise_id,
- struct PP_Var init_data_type,
- struct PP_Var init_data,
- PP_SessionType session_type);
+ void (*CreateSessionAndGenerateRequest)(PP_Instance instance,
+ uint32_t promise_id,
+ PP_SessionType session_type,
+ struct PP_Var init_data_type,
+ struct PP_Var init_data);
/**
* Loads a session whose web session ID is <code>web_session_id</code>.
*
@@ -100,12 +101,16 @@ struct PPP_ContentDecryptor_Private_0_12 {
* @param[in] promise_id A reference for the promise that gets resolved or
* rejected depending upon the success or failure of loading the session.
*
+ * @param[in] session_type A <code>PP_SessionType</code> that indicates the
+ * type of session to be loaded.
+ *
* @param[in] web_session_id A <code>PP_Var</code> of type
* <code>PP_VARTYPE_STRING</code> containing the web session ID of the session
* to load.
*/
void (*LoadSession)(PP_Instance instance,
uint32_t promise_id,
+ PP_SessionType session_type,
struct PP_Var web_session_id);
/**
* Provides a license or other message to the decryptor.
@@ -164,21 +169,6 @@ struct PPP_ContentDecryptor_Private_0_12 {
uint32_t promise_id,
struct PP_Var web_session_id);
/**
- * Get the key IDs for keys in the session that the CDM knows are currently
- * usable to decrypt media data.
- *
- * @param[in] promise_id A reference for the promise that gets resolved or
- * rejected depending upon the success or failure of obtaining the key IDs.
- *
- * @param[in] web_session_id A <code>PP_Var</code> of type
- * <code>PP_VARTYPE_STRING</code> containing the web session ID of the session
- * to be queried.
- *
- */
- void (*GetUsableKeyIds)(PP_Instance instance,
- uint32_t promise_id,
- struct PP_Var web_session_id);
- /**
* Decrypts the block and returns the unencrypted block via
* <code>DeliverBlock()</code> on the
* <code>PPB_ContentDecryptor_Private</code> interface. The returned block
@@ -304,7 +294,7 @@ struct PPP_ContentDecryptor_Private_0_12 {
const struct PP_EncryptedBlockInfo* encrypted_block_info);
};
-typedef struct PPP_ContentDecryptor_Private_0_12 PPP_ContentDecryptor_Private;
+typedef struct PPP_ContentDecryptor_Private_0_13 PPP_ContentDecryptor_Private;
/**
* @}
*/
diff --git a/ppapi/cpp/private/content_decryptor_private.cc b/ppapi/cpp/private/content_decryptor_private.cc
index 65f822c..d64d502 100644
--- a/ppapi/cpp/private/content_decryptor_private.cc
+++ b/ppapi/cpp/private/content_decryptor_private.cc
@@ -56,11 +56,11 @@ void SetServerCertificate(PP_Instance instance,
->SetServerCertificate(promise_id, server_certificate);
}
-void CreateSession(PP_Instance instance,
- uint32_t promise_id,
- PP_Var init_data_type_arg,
- PP_Var init_data_arg,
- PP_SessionType session_type) {
+void CreateSessionAndGenerateRequest(PP_Instance instance,
+ uint32_t promise_id,
+ PP_SessionType session_type,
+ PP_Var init_data_type_arg,
+ PP_Var init_data_arg) {
void* object =
Instance::GetPerInstanceObject(instance, kPPPContentDecryptorInterface);
if (!object)
@@ -76,14 +76,14 @@ void CreateSession(PP_Instance instance,
pp::VarArrayBuffer init_data_array_buffer(init_data_var);
static_cast<ContentDecryptor_Private*>(object)
- ->CreateSession(promise_id,
- init_data_type_var.AsString(),
- init_data_array_buffer,
- session_type);
+ ->CreateSessionAndGenerateRequest(promise_id, session_type,
+ init_data_type_var.AsString(),
+ init_data_array_buffer);
}
void LoadSession(PP_Instance instance,
uint32_t promise_id,
+ PP_SessionType session_type,
PP_Var web_session_id_arg) {
void* object =
Instance::GetPerInstanceObject(instance, kPPPContentDecryptorInterface);
@@ -95,7 +95,7 @@ void LoadSession(PP_Instance instance,
return;
static_cast<ContentDecryptor_Private*>(object)
- ->LoadSession(promise_id, web_session_id_var.AsString());
+ ->LoadSession(promise_id, session_type, web_session_id_var.AsString());
}
void UpdateSession(PP_Instance instance,
@@ -152,22 +152,6 @@ void RemoveSession(PP_Instance instance,
->RemoveSession(promise_id, web_session_id_var.AsString());
}
-void GetUsableKeyIds(PP_Instance instance,
- uint32_t promise_id,
- PP_Var web_session_id_arg) {
- void* object =
- Instance::GetPerInstanceObject(instance, kPPPContentDecryptorInterface);
- if (!object)
- return;
-
- pp::Var web_session_id_var(web_session_id_arg);
- if (!web_session_id_var.is_string())
- return;
-
- static_cast<ContentDecryptor_Private*>(object)
- ->GetUsableKeyIds(promise_id, web_session_id_var.AsString());
-}
-
void Decrypt(PP_Instance instance,
PP_Resource encrypted_resource,
const PP_EncryptedBlockInfo* encrypted_block_info) {
@@ -258,12 +242,11 @@ void DecryptAndDecode(PP_Instance instance,
const PPP_ContentDecryptor_Private ppp_content_decryptor = {
&Initialize,
&SetServerCertificate,
- &CreateSession,
+ &CreateSessionAndGenerateRequest,
&LoadSession,
&UpdateSession,
&CloseSession,
&RemoveSession,
- &GetUsableKeyIds,
&Decrypt,
&InitializeAudioDecoder,
&InitializeVideoDecoder,
@@ -309,23 +292,6 @@ void ContentDecryptor_Private::PromiseResolvedWithSession(
}
}
-void ContentDecryptor_Private::PromiseResolvedWithKeyIds(
- uint32_t promise_id,
- const std::vector<std::vector<uint8_t> >& key_ids) {
- if (has_interface<PPB_ContentDecryptor_Private>()) {
- pp::VarArray key_ids_array = pp::VarArray();
- key_ids_array.SetLength(key_ids.size());
- for (size_t i = 0; i < key_ids.size(); ++i) {
- const std::vector<uint8_t>& entry = key_ids[i];
- pp::VarArrayBuffer array_buffer(entry.size());
- memcpy(array_buffer.Map(), &entry[0], entry.size());
- key_ids_array.Set(i, array_buffer);
- }
- get_interface<PPB_ContentDecryptor_Private>()->PromiseResolvedWithKeyIds(
- associated_instance_.pp_instance(), promise_id, key_ids_array.pp_var());
- }
-}
-
void ContentDecryptor_Private::PromiseRejected(
uint32_t promise_id,
PP_CdmExceptionCode exception_code,
@@ -342,30 +308,27 @@ void ContentDecryptor_Private::PromiseRejected(
}
}
-void ContentDecryptor_Private::SessionMessage(
- const std::string& web_session_id,
- pp::VarArrayBuffer message,
- const std::string& destination_url) {
+void ContentDecryptor_Private::SessionMessage(const std::string& web_session_id,
+ PP_CdmMessageType message_type,
+ pp::VarArrayBuffer message) {
if (has_interface<PPB_ContentDecryptor_Private>()) {
pp::Var web_session_id_var(web_session_id);
- pp::Var destination_url_var(destination_url);
get_interface<PPB_ContentDecryptor_Private>()->SessionMessage(
- associated_instance_.pp_instance(),
- web_session_id_var.pp_var(),
- message.pp_var(),
- destination_url_var.pp_var());
+ associated_instance_.pp_instance(), web_session_id_var.pp_var(),
+ message_type, message.pp_var());
}
}
void ContentDecryptor_Private::SessionKeysChange(
const std::string& web_session_id,
- bool has_additional_usable_key) {
+ bool has_additional_usable_key,
+ const std::vector<PP_KeyInformation>& key_information) {
if (has_interface<PPB_ContentDecryptor_Private>()) {
pp::Var web_session_id_var(web_session_id);
get_interface<PPB_ContentDecryptor_Private>()->SessionKeysChange(
- associated_instance_.pp_instance(),
- web_session_id_var.pp_var(),
- PP_FromBool(has_additional_usable_key));
+ associated_instance_.pp_instance(), web_session_id_var.pp_var(),
+ PP_FromBool(has_additional_usable_key), key_information.size(),
+ key_information.empty() ? NULL : &key_information[0]);
}
}
@@ -381,14 +344,6 @@ void ContentDecryptor_Private::SessionExpirationChange(
}
}
-void ContentDecryptor_Private::SessionReady(const std::string& web_session_id) {
- if (has_interface<PPB_ContentDecryptor_Private>()) {
- pp::Var web_session_id_var(web_session_id);
- get_interface<PPB_ContentDecryptor_Private>()->SessionReady(
- associated_instance_.pp_instance(), web_session_id_var.pp_var());
- }
-}
-
void ContentDecryptor_Private::SessionClosed(
const std::string& web_session_id) {
if (has_interface<PPB_ContentDecryptor_Private>()) {
diff --git a/ppapi/cpp/private/content_decryptor_private.h b/ppapi/cpp/private/content_decryptor_private.h
index 25aba52..0117c72 100644
--- a/ppapi/cpp/private/content_decryptor_private.h
+++ b/ppapi/cpp/private/content_decryptor_private.h
@@ -37,11 +37,13 @@ class ContentDecryptor_Private {
virtual void Initialize(const std::string& key_system) = 0;
virtual void SetServerCertificate(uint32_t promise_id,
pp::VarArrayBuffer server_certificate) = 0;
- virtual void CreateSession(uint32_t promise_id,
- const std::string& init_data_type,
- pp::VarArrayBuffer init_data,
- PP_SessionType session_type) = 0;
+ virtual void CreateSessionAndGenerateRequest(
+ uint32_t promise_id,
+ PP_SessionType session_type,
+ const std::string& init_data_type,
+ pp::VarArrayBuffer init_data) = 0;
virtual void LoadSession(uint32_t promise_id,
+ PP_SessionType session_type,
const std::string& web_session_id) = 0;
virtual void UpdateSession(uint32_t promise_id,
const std::string& web_session_id,
@@ -50,8 +52,6 @@ class ContentDecryptor_Private {
const std::string& web_session_id) = 0;
virtual void RemoveSession(uint32_t promise_id,
const std::string& web_session_id) = 0;
- virtual void GetUsableKeyIds(uint32_t promise_id,
- const std::string& web_session_id) = 0;
virtual void Decrypt(pp::Buffer_Dev encrypted_buffer,
const PP_EncryptedBlockInfo& encrypted_block_info) = 0;
virtual void InitializeAudioDecoder(
@@ -75,21 +75,18 @@ class ContentDecryptor_Private {
void PromiseResolved(uint32_t promise_id);
void PromiseResolvedWithSession(uint32_t promise_id,
const std::string& web_session_id);
- void PromiseResolvedWithKeyIds(
- uint32_t promise_id,
- const std::vector<std::vector<uint8_t> >& key_ids);
void PromiseRejected(uint32_t promise_id,
PP_CdmExceptionCode exception_code,
uint32_t system_code,
const std::string& error_description);
void SessionMessage(const std::string& web_session_id,
- pp::VarArrayBuffer message,
- const std::string& destination_url);
+ PP_CdmMessageType message_type,
+ pp::VarArrayBuffer message);
void SessionKeysChange(const std::string& web_session_id,
- bool has_additional_usable_key);
+ bool has_additional_usable_key,
+ const std::vector<PP_KeyInformation>& key_information);
void SessionExpirationChange(const std::string& web_session_id,
PP_Time new_expiry_time);
- void SessionReady(const std::string& web_session_id);
void SessionClosed(const std::string& web_session_id);
void SessionError(const std::string& web_session_id,
PP_CdmExceptionCode exception_code,
diff --git a/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c b/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c
index f2cd8ca..6212a7b 100644
--- a/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c
+++ b/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c
@@ -1,4 +1,4 @@
-/* Copyright (c) 2014 The Chromium Authors. All rights reserved.
+/* Copyright (c) 2015 The Chromium Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
@@ -165,7 +165,7 @@ static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_URLUtil_Dev_0_7;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_VideoCapture_Dev_0_3;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_VideoDecoder_Dev_0_16;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_Selection_Dev_0_3;
-static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12;
+static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_DisplayColorProfile_Private_0_1;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_Ext_CrxFileSystem_Private_0_1;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_FileIO_Private_0_1;
@@ -206,7 +206,7 @@ static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_UMA_Private_0_3;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_VideoDestination_Private_0_1;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_VideoSource_Private_0_1;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_X509Certificate_Private_0_1;
-static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12;
+static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_Instance_Private_0_1;
/* END Declarations for all Wrapper Infos. */
@@ -2882,89 +2882,79 @@ static struct PP_Var Pnacl_M13_PPP_Selection_Dev_GetSelectedText(PP_Instance ins
/* Not generating wrapper methods for PPB_CameraCapabilities_Private_0_1 */
-/* Begin wrapper methods for PPB_ContentDecryptor_Private_0_12 */
+/* Begin wrapper methods for PPB_ContentDecryptor_Private_0_13 */
-static void Pnacl_M36_PPB_ContentDecryptor_Private_PromiseResolved(PP_Instance instance, uint32_t promise_id) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_PromiseResolved(PP_Instance instance, uint32_t promise_id) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->PromiseResolved(instance, promise_id);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_PromiseResolvedWithSession(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_PromiseResolvedWithSession(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->PromiseResolvedWithSession(instance, promise_id, *web_session_id);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_PromiseResolvedWithKeyIds(PP_Instance instance, uint32_t promise_id, struct PP_Var* key_ids_array) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
- iface->PromiseResolvedWithKeyIds(instance, promise_id, *key_ids_array);
-}
-
-static void Pnacl_M36_PPB_ContentDecryptor_Private_PromiseRejected(PP_Instance instance, uint32_t promise_id, PP_CdmExceptionCode exception_code, uint32_t system_code, struct PP_Var* error_description) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_PromiseRejected(PP_Instance instance, uint32_t promise_id, PP_CdmExceptionCode exception_code, uint32_t system_code, struct PP_Var* error_description) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->PromiseRejected(instance, promise_id, exception_code, system_code, *error_description);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_SessionMessage(PP_Instance instance, struct PP_Var* web_session_id, struct PP_Var* message, struct PP_Var* destination_url) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
- iface->SessionMessage(instance, *web_session_id, *message, *destination_url);
+static void Pnacl_M41_PPB_ContentDecryptor_Private_SessionMessage(PP_Instance instance, struct PP_Var* web_session_id, PP_CdmMessageType message_type, struct PP_Var* message) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
+ iface->SessionMessage(instance, *web_session_id, message_type, *message);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_SessionKeysChange(PP_Instance instance, struct PP_Var* web_session_id, PP_Bool has_additional_usable_key) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
- iface->SessionKeysChange(instance, *web_session_id, has_additional_usable_key);
+static void Pnacl_M41_PPB_ContentDecryptor_Private_SessionKeysChange(PP_Instance instance, struct PP_Var* web_session_id, PP_Bool has_additional_usable_key, uint32_t key_count, const struct PP_KeyInformation key_information[]) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
+ iface->SessionKeysChange(instance, *web_session_id, has_additional_usable_key, key_count, key_information);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_SessionExpirationChange(PP_Instance instance, struct PP_Var* web_session_id, PP_Time new_expiry_time) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_SessionExpirationChange(PP_Instance instance, struct PP_Var* web_session_id, PP_Time new_expiry_time) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->SessionExpirationChange(instance, *web_session_id, new_expiry_time);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_SessionReady(PP_Instance instance, struct PP_Var* web_session_id) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
- iface->SessionReady(instance, *web_session_id);
-}
-
-static void Pnacl_M36_PPB_ContentDecryptor_Private_SessionClosed(PP_Instance instance, struct PP_Var* web_session_id) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_SessionClosed(PP_Instance instance, struct PP_Var* web_session_id) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->SessionClosed(instance, *web_session_id);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_SessionError(PP_Instance instance, struct PP_Var* web_session_id, PP_CdmExceptionCode exception_code, uint32_t system_code, struct PP_Var* error_description) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_SessionError(PP_Instance instance, struct PP_Var* web_session_id, PP_CdmExceptionCode exception_code, uint32_t system_code, struct PP_Var* error_description) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->SessionError(instance, *web_session_id, exception_code, system_code, *error_description);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_DeliverBlock(PP_Instance instance, PP_Resource decrypted_block, const struct PP_DecryptedBlockInfo* decrypted_block_info) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_DeliverBlock(PP_Instance instance, PP_Resource decrypted_block, const struct PP_DecryptedBlockInfo* decrypted_block_info) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->DeliverBlock(instance, decrypted_block, decrypted_block_info);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_DecoderInitializeDone(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id, PP_Bool success) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_DecoderInitializeDone(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id, PP_Bool success) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->DecoderInitializeDone(instance, decoder_type, request_id, success);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_DecoderDeinitializeDone(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_DecoderDeinitializeDone(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->DecoderDeinitializeDone(instance, decoder_type, request_id);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_DecoderResetDone(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_DecoderResetDone(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->DecoderResetDone(instance, decoder_type, request_id);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_DeliverFrame(PP_Instance instance, PP_Resource decrypted_frame, const struct PP_DecryptedFrameInfo* decrypted_frame_info) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_DeliverFrame(PP_Instance instance, PP_Resource decrypted_frame, const struct PP_DecryptedFrameInfo* decrypted_frame_info) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->DeliverFrame(instance, decrypted_frame, decrypted_frame_info);
}
-static void Pnacl_M36_PPB_ContentDecryptor_Private_DeliverSamples(PP_Instance instance, PP_Resource audio_frames, const struct PP_DecryptedSampleInfo* decrypted_sample_info) {
- const struct PPB_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPB_ContentDecryptor_Private_DeliverSamples(PP_Instance instance, PP_Resource audio_frames, const struct PP_DecryptedSampleInfo* decrypted_sample_info) {
+ const struct PPB_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13.real_iface;
iface->DeliverSamples(instance, audio_frames, decrypted_sample_info);
}
-/* End wrapper methods for PPB_ContentDecryptor_Private_0_12 */
+/* End wrapper methods for PPB_ContentDecryptor_Private_0_13 */
/* Begin wrapper methods for PPB_DisplayColorProfile_Private_0_1 */
@@ -4547,107 +4537,100 @@ static void Pnacl_M19_PPB_X509Certificate_Private_GetField(struct PP_Var* _struc
/* End wrapper methods for PPB_X509Certificate_Private_0_1 */
-/* Begin wrapper methods for PPP_ContentDecryptor_Private_0_12 */
+/* Begin wrapper methods for PPP_ContentDecryptor_Private_0_13 */
-static void Pnacl_M36_PPP_ContentDecryptor_Private_Initialize(PP_Instance instance, struct PP_Var key_system) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_Initialize(PP_Instance instance, struct PP_Var key_system) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, struct PP_Var* key_system) =
((void (*)(PP_Instance instance, struct PP_Var* key_system))iface->Initialize);
temp_fp(instance, &key_system);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_SetServerCertificate(PP_Instance instance, uint32_t promise_id, struct PP_Var server_certificate) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_SetServerCertificate(PP_Instance instance, uint32_t promise_id, struct PP_Var server_certificate) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, uint32_t promise_id, struct PP_Var* server_certificate) =
((void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var* server_certificate))iface->SetServerCertificate);
temp_fp(instance, promise_id, &server_certificate);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_CreateSession(PP_Instance instance, uint32_t promise_id, struct PP_Var init_data_type, struct PP_Var init_data, PP_SessionType session_type) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
- void (*temp_fp)(PP_Instance instance, uint32_t promise_id, struct PP_Var* init_data_type, struct PP_Var* init_data, PP_SessionType session_type) =
- ((void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var* init_data_type, struct PP_Var* init_data, PP_SessionType session_type))iface->CreateSession);
- temp_fp(instance, promise_id, &init_data_type, &init_data, session_type);
+static void Pnacl_M41_PPP_ContentDecryptor_Private_CreateSessionAndGenerateRequest(PP_Instance instance, uint32_t promise_id, PP_SessionType session_type, struct PP_Var init_data_type, struct PP_Var init_data) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
+ void (*temp_fp)(PP_Instance instance, uint32_t promise_id, PP_SessionType session_type, struct PP_Var* init_data_type, struct PP_Var* init_data) =
+ ((void (*)(PP_Instance instance, uint32_t promise_id, PP_SessionType session_type, struct PP_Var* init_data_type, struct PP_Var* init_data))iface->CreateSessionAndGenerateRequest);
+ temp_fp(instance, promise_id, session_type, &init_data_type, &init_data);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_LoadSession(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
- void (*temp_fp)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id) =
- ((void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id))iface->LoadSession);
- temp_fp(instance, promise_id, &web_session_id);
+static void Pnacl_M41_PPP_ContentDecryptor_Private_LoadSession(PP_Instance instance, uint32_t promise_id, PP_SessionType session_type, struct PP_Var web_session_id) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
+ void (*temp_fp)(PP_Instance instance, uint32_t promise_id, PP_SessionType session_type, struct PP_Var* web_session_id) =
+ ((void (*)(PP_Instance instance, uint32_t promise_id, PP_SessionType session_type, struct PP_Var* web_session_id))iface->LoadSession);
+ temp_fp(instance, promise_id, session_type, &web_session_id);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_UpdateSession(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id, struct PP_Var response) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_UpdateSession(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id, struct PP_Var response) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id, struct PP_Var* response) =
((void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id, struct PP_Var* response))iface->UpdateSession);
temp_fp(instance, promise_id, &web_session_id, &response);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_CloseSession(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_CloseSession(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id) =
((void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id))iface->CloseSession);
temp_fp(instance, promise_id, &web_session_id);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_RemoveSession(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_RemoveSession(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id) =
((void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id))iface->RemoveSession);
temp_fp(instance, promise_id, &web_session_id);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_GetUsableKeyIds(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
- void (*temp_fp)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id) =
- ((void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var* web_session_id))iface->GetUsableKeyIds);
- temp_fp(instance, promise_id, &web_session_id);
-}
-
-static void Pnacl_M36_PPP_ContentDecryptor_Private_Decrypt(PP_Instance instance, PP_Resource encrypted_block, const struct PP_EncryptedBlockInfo* encrypted_block_info) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_Decrypt(PP_Instance instance, PP_Resource encrypted_block, const struct PP_EncryptedBlockInfo* encrypted_block_info) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, PP_Resource encrypted_block, const struct PP_EncryptedBlockInfo* encrypted_block_info) =
((void (*)(PP_Instance instance, PP_Resource encrypted_block, const struct PP_EncryptedBlockInfo* encrypted_block_info))iface->Decrypt);
temp_fp(instance, encrypted_block, encrypted_block_info);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_InitializeAudioDecoder(PP_Instance instance, const struct PP_AudioDecoderConfig* decoder_config, PP_Resource codec_extra_data) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_InitializeAudioDecoder(PP_Instance instance, const struct PP_AudioDecoderConfig* decoder_config, PP_Resource codec_extra_data) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, const struct PP_AudioDecoderConfig* decoder_config, PP_Resource codec_extra_data) =
((void (*)(PP_Instance instance, const struct PP_AudioDecoderConfig* decoder_config, PP_Resource codec_extra_data))iface->InitializeAudioDecoder);
temp_fp(instance, decoder_config, codec_extra_data);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_InitializeVideoDecoder(PP_Instance instance, const struct PP_VideoDecoderConfig* decoder_config, PP_Resource codec_extra_data) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_InitializeVideoDecoder(PP_Instance instance, const struct PP_VideoDecoderConfig* decoder_config, PP_Resource codec_extra_data) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, const struct PP_VideoDecoderConfig* decoder_config, PP_Resource codec_extra_data) =
((void (*)(PP_Instance instance, const struct PP_VideoDecoderConfig* decoder_config, PP_Resource codec_extra_data))iface->InitializeVideoDecoder);
temp_fp(instance, decoder_config, codec_extra_data);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_DeinitializeDecoder(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_DeinitializeDecoder(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) =
((void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id))iface->DeinitializeDecoder);
temp_fp(instance, decoder_type, request_id);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_ResetDecoder(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_ResetDecoder(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id) =
((void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id))iface->ResetDecoder);
temp_fp(instance, decoder_type, request_id);
}
-static void Pnacl_M36_PPP_ContentDecryptor_Private_DecryptAndDecode(PP_Instance instance, PP_DecryptorStreamType decoder_type, PP_Resource encrypted_buffer, const struct PP_EncryptedBlockInfo* encrypted_block_info) {
- const struct PPP_ContentDecryptor_Private_0_12 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12.real_iface;
+static void Pnacl_M41_PPP_ContentDecryptor_Private_DecryptAndDecode(PP_Instance instance, PP_DecryptorStreamType decoder_type, PP_Resource encrypted_buffer, const struct PP_EncryptedBlockInfo* encrypted_block_info) {
+ const struct PPP_ContentDecryptor_Private_0_13 *iface = Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13.real_iface;
void (*temp_fp)(PP_Instance instance, PP_DecryptorStreamType decoder_type, PP_Resource encrypted_buffer, const struct PP_EncryptedBlockInfo* encrypted_block_info) =
((void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, PP_Resource encrypted_buffer, const struct PP_EncryptedBlockInfo* encrypted_block_info))iface->DecryptAndDecode);
temp_fp(instance, decoder_type, encrypted_buffer, encrypted_block_info);
}
-/* End wrapper methods for PPP_ContentDecryptor_Private_0_12 */
+/* End wrapper methods for PPP_ContentDecryptor_Private_0_13 */
/* Not generating wrapper methods for PPP_Find_Private_0_3 */
@@ -5453,23 +5436,21 @@ static const struct PPP_Selection_Dev_0_3 Pnacl_Wrappers_PPP_Selection_Dev_0_3 =
/* Not generating wrapper interface for PPB_CameraCapabilities_Private_0_1 */
-static const struct PPB_ContentDecryptor_Private_0_12 Pnacl_Wrappers_PPB_ContentDecryptor_Private_0_12 = {
- .PromiseResolved = (void (*)(PP_Instance instance, uint32_t promise_id))&Pnacl_M36_PPB_ContentDecryptor_Private_PromiseResolved,
- .PromiseResolvedWithSession = (void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id))&Pnacl_M36_PPB_ContentDecryptor_Private_PromiseResolvedWithSession,
- .PromiseResolvedWithKeyIds = (void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var key_ids_array))&Pnacl_M36_PPB_ContentDecryptor_Private_PromiseResolvedWithKeyIds,
- .PromiseRejected = (void (*)(PP_Instance instance, uint32_t promise_id, PP_CdmExceptionCode exception_code, uint32_t system_code, struct PP_Var error_description))&Pnacl_M36_PPB_ContentDecryptor_Private_PromiseRejected,
- .SessionMessage = (void (*)(PP_Instance instance, struct PP_Var web_session_id, struct PP_Var message, struct PP_Var destination_url))&Pnacl_M36_PPB_ContentDecryptor_Private_SessionMessage,
- .SessionKeysChange = (void (*)(PP_Instance instance, struct PP_Var web_session_id, PP_Bool has_additional_usable_key))&Pnacl_M36_PPB_ContentDecryptor_Private_SessionKeysChange,
- .SessionExpirationChange = (void (*)(PP_Instance instance, struct PP_Var web_session_id, PP_Time new_expiry_time))&Pnacl_M36_PPB_ContentDecryptor_Private_SessionExpirationChange,
- .SessionReady = (void (*)(PP_Instance instance, struct PP_Var web_session_id))&Pnacl_M36_PPB_ContentDecryptor_Private_SessionReady,
- .SessionClosed = (void (*)(PP_Instance instance, struct PP_Var web_session_id))&Pnacl_M36_PPB_ContentDecryptor_Private_SessionClosed,
- .SessionError = (void (*)(PP_Instance instance, struct PP_Var web_session_id, PP_CdmExceptionCode exception_code, uint32_t system_code, struct PP_Var error_description))&Pnacl_M36_PPB_ContentDecryptor_Private_SessionError,
- .DeliverBlock = (void (*)(PP_Instance instance, PP_Resource decrypted_block, const struct PP_DecryptedBlockInfo* decrypted_block_info))&Pnacl_M36_PPB_ContentDecryptor_Private_DeliverBlock,
- .DecoderInitializeDone = (void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id, PP_Bool success))&Pnacl_M36_PPB_ContentDecryptor_Private_DecoderInitializeDone,
- .DecoderDeinitializeDone = (void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id))&Pnacl_M36_PPB_ContentDecryptor_Private_DecoderDeinitializeDone,
- .DecoderResetDone = (void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id))&Pnacl_M36_PPB_ContentDecryptor_Private_DecoderResetDone,
- .DeliverFrame = (void (*)(PP_Instance instance, PP_Resource decrypted_frame, const struct PP_DecryptedFrameInfo* decrypted_frame_info))&Pnacl_M36_PPB_ContentDecryptor_Private_DeliverFrame,
- .DeliverSamples = (void (*)(PP_Instance instance, PP_Resource audio_frames, const struct PP_DecryptedSampleInfo* decrypted_sample_info))&Pnacl_M36_PPB_ContentDecryptor_Private_DeliverSamples
+static const struct PPB_ContentDecryptor_Private_0_13 Pnacl_Wrappers_PPB_ContentDecryptor_Private_0_13 = {
+ .PromiseResolved = (void (*)(PP_Instance instance, uint32_t promise_id))&Pnacl_M41_PPB_ContentDecryptor_Private_PromiseResolved,
+ .PromiseResolvedWithSession = (void (*)(PP_Instance instance, uint32_t promise_id, struct PP_Var web_session_id))&Pnacl_M41_PPB_ContentDecryptor_Private_PromiseResolvedWithSession,
+ .PromiseRejected = (void (*)(PP_Instance instance, uint32_t promise_id, PP_CdmExceptionCode exception_code, uint32_t system_code, struct PP_Var error_description))&Pnacl_M41_PPB_ContentDecryptor_Private_PromiseRejected,
+ .SessionMessage = (void (*)(PP_Instance instance, struct PP_Var web_session_id, PP_CdmMessageType message_type, struct PP_Var message))&Pnacl_M41_PPB_ContentDecryptor_Private_SessionMessage,
+ .SessionKeysChange = (void (*)(PP_Instance instance, struct PP_Var web_session_id, PP_Bool has_additional_usable_key, uint32_t key_count, const struct PP_KeyInformation key_information[]))&Pnacl_M41_PPB_ContentDecryptor_Private_SessionKeysChange,
+ .SessionExpirationChange = (void (*)(PP_Instance instance, struct PP_Var web_session_id, PP_Time new_expiry_time))&Pnacl_M41_PPB_ContentDecryptor_Private_SessionExpirationChange,
+ .SessionClosed = (void (*)(PP_Instance instance, struct PP_Var web_session_id))&Pnacl_M41_PPB_ContentDecryptor_Private_SessionClosed,
+ .SessionError = (void (*)(PP_Instance instance, struct PP_Var web_session_id, PP_CdmExceptionCode exception_code, uint32_t system_code, struct PP_Var error_description))&Pnacl_M41_PPB_ContentDecryptor_Private_SessionError,
+ .DeliverBlock = (void (*)(PP_Instance instance, PP_Resource decrypted_block, const struct PP_DecryptedBlockInfo* decrypted_block_info))&Pnacl_M41_PPB_ContentDecryptor_Private_DeliverBlock,
+ .DecoderInitializeDone = (void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id, PP_Bool success))&Pnacl_M41_PPB_ContentDecryptor_Private_DecoderInitializeDone,
+ .DecoderDeinitializeDone = (void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id))&Pnacl_M41_PPB_ContentDecryptor_Private_DecoderDeinitializeDone,
+ .DecoderResetDone = (void (*)(PP_Instance instance, PP_DecryptorStreamType decoder_type, uint32_t request_id))&Pnacl_M41_PPB_ContentDecryptor_Private_DecoderResetDone,
+ .DeliverFrame = (void (*)(PP_Instance instance, PP_Resource decrypted_frame, const struct PP_DecryptedFrameInfo* decrypted_frame_info))&Pnacl_M41_PPB_ContentDecryptor_Private_DeliverFrame,
+ .DeliverSamples = (void (*)(PP_Instance instance, PP_Resource audio_frames, const struct PP_DecryptedSampleInfo* decrypted_sample_info))&Pnacl_M41_PPB_ContentDecryptor_Private_DeliverSamples
};
static const struct PPB_DisplayColorProfile_Private_0_1 Pnacl_Wrappers_PPB_DisplayColorProfile_Private_0_1 = {
@@ -5889,21 +5870,20 @@ static const struct PPB_X509Certificate_Private_0_1 Pnacl_Wrappers_PPB_X509Certi
.GetField = (struct PP_Var (*)(PP_Resource resource, PP_X509Certificate_Private_Field field))&Pnacl_M19_PPB_X509Certificate_Private_GetField
};
-static const struct PPP_ContentDecryptor_Private_0_12 Pnacl_Wrappers_PPP_ContentDecryptor_Private_0_12 = {
- .Initialize = &Pnacl_M36_PPP_ContentDecryptor_Private_Initialize,
- .SetServerCertificate = &Pnacl_M36_PPP_ContentDecryptor_Private_SetServerCertificate,
- .CreateSession = &Pnacl_M36_PPP_ContentDecryptor_Private_CreateSession,
- .LoadSession = &Pnacl_M36_PPP_ContentDecryptor_Private_LoadSession,
- .UpdateSession = &Pnacl_M36_PPP_ContentDecryptor_Private_UpdateSession,
- .CloseSession = &Pnacl_M36_PPP_ContentDecryptor_Private_CloseSession,
- .RemoveSession = &Pnacl_M36_PPP_ContentDecryptor_Private_RemoveSession,
- .GetUsableKeyIds = &Pnacl_M36_PPP_ContentDecryptor_Private_GetUsableKeyIds,
- .Decrypt = &Pnacl_M36_PPP_ContentDecryptor_Private_Decrypt,
- .InitializeAudioDecoder = &Pnacl_M36_PPP_ContentDecryptor_Private_InitializeAudioDecoder,
- .InitializeVideoDecoder = &Pnacl_M36_PPP_ContentDecryptor_Private_InitializeVideoDecoder,
- .DeinitializeDecoder = &Pnacl_M36_PPP_ContentDecryptor_Private_DeinitializeDecoder,
- .ResetDecoder = &Pnacl_M36_PPP_ContentDecryptor_Private_ResetDecoder,
- .DecryptAndDecode = &Pnacl_M36_PPP_ContentDecryptor_Private_DecryptAndDecode
+static const struct PPP_ContentDecryptor_Private_0_13 Pnacl_Wrappers_PPP_ContentDecryptor_Private_0_13 = {
+ .Initialize = &Pnacl_M41_PPP_ContentDecryptor_Private_Initialize,
+ .SetServerCertificate = &Pnacl_M41_PPP_ContentDecryptor_Private_SetServerCertificate,
+ .CreateSessionAndGenerateRequest = &Pnacl_M41_PPP_ContentDecryptor_Private_CreateSessionAndGenerateRequest,
+ .LoadSession = &Pnacl_M41_PPP_ContentDecryptor_Private_LoadSession,
+ .UpdateSession = &Pnacl_M41_PPP_ContentDecryptor_Private_UpdateSession,
+ .CloseSession = &Pnacl_M41_PPP_ContentDecryptor_Private_CloseSession,
+ .RemoveSession = &Pnacl_M41_PPP_ContentDecryptor_Private_RemoveSession,
+ .Decrypt = &Pnacl_M41_PPP_ContentDecryptor_Private_Decrypt,
+ .InitializeAudioDecoder = &Pnacl_M41_PPP_ContentDecryptor_Private_InitializeAudioDecoder,
+ .InitializeVideoDecoder = &Pnacl_M41_PPP_ContentDecryptor_Private_InitializeVideoDecoder,
+ .DeinitializeDecoder = &Pnacl_M41_PPP_ContentDecryptor_Private_DeinitializeDecoder,
+ .ResetDecoder = &Pnacl_M41_PPP_ContentDecryptor_Private_ResetDecoder,
+ .DecryptAndDecode = &Pnacl_M41_PPP_ContentDecryptor_Private_DecryptAndDecode
};
/* Not generating wrapper interface for PPP_Find_Private_0_3 */
@@ -6334,9 +6314,9 @@ static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_Selection_Dev_0_3 = {
.real_iface = NULL
};
-static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12 = {
- .iface_macro = PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_12,
- .wrapped_iface = (const void *) &Pnacl_Wrappers_PPB_ContentDecryptor_Private_0_12,
+static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13 = {
+ .iface_macro = PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_13,
+ .wrapped_iface = (const void *) &Pnacl_Wrappers_PPB_ContentDecryptor_Private_0_13,
.real_iface = NULL
};
@@ -6580,9 +6560,9 @@ static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_X509Certificate_Private_0
.real_iface = NULL
};
-static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12 = {
- .iface_macro = PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_12,
- .wrapped_iface = (const void *) &Pnacl_Wrappers_PPP_ContentDecryptor_Private_0_12,
+static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13 = {
+ .iface_macro = PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_13,
+ .wrapped_iface = (const void *) &Pnacl_Wrappers_PPP_ContentDecryptor_Private_0_13,
.real_iface = NULL
};
@@ -6660,7 +6640,7 @@ static struct __PnaclWrapperInfo *s_ppb_wrappers[] = {
&Pnacl_WrapperInfo_PPB_URLUtil_Dev_0_7,
&Pnacl_WrapperInfo_PPB_VideoCapture_Dev_0_3,
&Pnacl_WrapperInfo_PPB_VideoDecoder_Dev_0_16,
- &Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_12,
+ &Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_13,
&Pnacl_WrapperInfo_PPB_DisplayColorProfile_Private_0_1,
&Pnacl_WrapperInfo_PPB_Ext_CrxFileSystem_Private_0_1,
&Pnacl_WrapperInfo_PPB_FileIO_Private_0_1,
@@ -6707,7 +6687,7 @@ static struct __PnaclWrapperInfo *s_ppb_wrappers[] = {
static struct __PnaclWrapperInfo *s_ppp_wrappers[] = {
&Pnacl_WrapperInfo_PPP_Messaging_1_0,
&Pnacl_WrapperInfo_PPP_Selection_Dev_0_3,
- &Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_12,
+ &Pnacl_WrapperInfo_PPP_ContentDecryptor_Private_0_13,
&Pnacl_WrapperInfo_PPP_Instance_Private_0_1,
NULL
};
diff --git a/ppapi/proxy/ppapi_messages.h b/ppapi/proxy/ppapi_messages.h
index 275e39c..c899527 100644
--- a/ppapi/proxy/ppapi_messages.h
+++ b/ppapi/proxy/ppapi_messages.h
@@ -89,10 +89,11 @@ IPC_ENUM_TRAITS_MAX_VALUE(ppapi::TCPSocketVersion,
ppapi::TCP_SOCKET_VERSION_1_1_OR_ABOVE)
IPC_ENUM_TRAITS(PP_AudioSampleRate)
IPC_ENUM_TRAITS_MAX_VALUE(PP_BlendMode, PP_BLENDMODE_LAST)
+IPC_ENUM_TRAITS_MAX_VALUE(PP_CdmExceptionCode, PP_CDMEXCEPTIONCODE_OUTPUTERROR)
+IPC_ENUM_TRAITS_MAX_VALUE(PP_CdmKeyStatus, PP_CDMKEYSTATUS_OUTPUTNOTALLOWED)
+IPC_ENUM_TRAITS_MAX_VALUE(PP_CdmMessageType, PP_CDMMESSAGETYPE_LICENSE_RELEASE)
IPC_ENUM_TRAITS(PP_DeviceType_Dev)
IPC_ENUM_TRAITS(PP_DecryptorStreamType)
-IPC_ENUM_TRAITS(PP_SessionType)
-IPC_ENUM_TRAITS(PP_CdmExceptionCode)
IPC_ENUM_TRAITS_MAX_VALUE(PP_FileSystemType, PP_FILESYSTEMTYPE_ISOLATED)
IPC_ENUM_TRAITS_MAX_VALUE(PP_FileType, PP_FILETYPE_OTHER)
IPC_ENUM_TRAITS(PP_Flash_BrowserOperations_Permission)
@@ -114,6 +115,7 @@ IPC_ENUM_TRAITS_MAX_VALUE(PP_PrintDuplexMode_Dev, PP_PRINTDUPLEXMODE_SHORT_EDGE)
IPC_ENUM_TRAITS(PP_PrivateFontCharset)
IPC_ENUM_TRAITS(PP_ResourceImage)
IPC_ENUM_TRAITS(PP_ResourceString)
+IPC_ENUM_TRAITS_MAX_VALUE(PP_SessionType, PP_SESSIONTYPE_PERSISTENT_RELEASE)
IPC_ENUM_TRAITS_MAX_VALUE(PP_TalkEvent, PP_TALKEVENT_NUM_EVENTS - 1)
IPC_ENUM_TRAITS_MAX_VALUE(PP_TalkPermission,
PP_TALKPERMISSION_NUM_PERMISSIONS - 1)
@@ -781,15 +783,17 @@ IPC_MESSAGE_ROUTED3(PpapiMsg_PPPContentDecryptor_SetServerCertificate,
PP_Instance /* instance */,
uint32_t /* promise_id */,
std::vector<uint8_t> /* certificate */)
-IPC_MESSAGE_ROUTED5(PpapiMsg_PPPContentDecryptor_CreateSession,
- PP_Instance /* instance */,
- uint32_t /* promise_id */,
- ppapi::proxy::SerializedVar /* init_data_type, String */,
- ppapi::proxy::SerializedVar /* init_data, ArrayBuffer */,
- PP_SessionType /* session_type */)
-IPC_MESSAGE_ROUTED3(PpapiMsg_PPPContentDecryptor_LoadSession,
+IPC_MESSAGE_ROUTED5(
+ PpapiMsg_PPPContentDecryptor_CreateSessionAndGenerateRequest,
+ PP_Instance /* instance */,
+ uint32_t /* promise_id */,
+ PP_SessionType /* session_type */,
+ ppapi::proxy::SerializedVar /* init_data_type, String */,
+ ppapi::proxy::SerializedVar /* init_data, ArrayBuffer */)
+IPC_MESSAGE_ROUTED4(PpapiMsg_PPPContentDecryptor_LoadSession,
PP_Instance /* instance */,
uint32_t /* promise_id */,
+ PP_SessionType /* session_type */,
ppapi::proxy::SerializedVar /* web_session_id, String */)
IPC_MESSAGE_ROUTED4(PpapiMsg_PPPContentDecryptor_UpdateSession,
PP_Instance /* instance */,
@@ -804,10 +808,6 @@ IPC_MESSAGE_ROUTED3(PpapiMsg_PPPContentDecryptor_RemoveSession,
PP_Instance /* instance */,
uint32_t /* promise_id */,
std::string /* web_session_id */)
-IPC_MESSAGE_ROUTED3(PpapiMsg_PPPContentDecryptor_GetUsableKeyIds,
- PP_Instance /* instance */,
- uint32_t /* promise_id */,
- std::string /* web_session_id */)
IPC_MESSAGE_ROUTED3(PpapiMsg_PPPContentDecryptor_Decrypt,
PP_Instance /* instance */,
ppapi::proxy::PPPDecryptor_Buffer /* buffer */,
@@ -1128,10 +1128,6 @@ IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_PromiseResolvedWithSession,
PP_Instance /* instance */,
uint32_t /* promise_id */,
ppapi::proxy::SerializedVar /* web_session_id, String */)
-IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_PromiseResolvedWithKeyIds,
- PP_Instance /* instance */,
- uint32_t /* promise_id */,
- std::vector<std::vector<uint8_t> > /* key_ids */)
IPC_MESSAGE_ROUTED5(PpapiHostMsg_PPBInstance_PromiseRejected,
PP_Instance /* instance */,
uint32_t /* promise_id */,
@@ -1141,19 +1137,17 @@ IPC_MESSAGE_ROUTED5(PpapiHostMsg_PPBInstance_PromiseRejected,
IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBInstance_SessionMessage,
PP_Instance /* instance */,
ppapi::proxy::SerializedVar /* web_session_id, String */,
- ppapi::proxy::SerializedVar /* message, ArrayBuffer */,
- ppapi::proxy::SerializedVar /* destination_url, String */)
-IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_SessionKeysChange,
+ PP_CdmMessageType /* message_type */,
+ ppapi::proxy::SerializedVar /* message, ArrayBuffer */)
+IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBInstance_SessionKeysChange,
PP_Instance /* instance */,
std::string /* web_session_id */,
- PP_Bool /* has_additional_usable_key */)
+ PP_Bool /* has_additional_usable_key */,
+ std::vector<PP_KeyInformation> /* key_information */)
IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_SessionExpirationChange,
PP_Instance /* instance */,
std::string /* web_session_id */,
PP_Time /* new_expiry_time */)
-IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBInstance_SessionReady,
- PP_Instance /* instance */,
- ppapi::proxy::SerializedVar /* web_session_id, String */)
IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBInstance_SessionClosed,
PP_Instance /* instance */,
ppapi::proxy::SerializedVar /* web_session_id, String */)
diff --git a/ppapi/proxy/ppapi_param_traits.cc b/ppapi/proxy/ppapi_param_traits.cc
index 94ec2e6..c3e5af1 100644
--- a/ppapi/proxy/ppapi_param_traits.cc
+++ b/ppapi/proxy/ppapi_param_traits.cc
@@ -97,6 +97,52 @@ bool ParamTraits<PP_Bool>::Read(const Message* m,
void ParamTraits<PP_Bool>::Log(const param_type& p, std::string* l) {
}
+// PP_KeyInformation -------------------------------------------------------
+
+// static
+void ParamTraits<PP_KeyInformation>::Write(Message* m, const param_type& p) {
+ WriteParam(m, p.key_id_size);
+ m->WriteBytes(p.key_id, static_cast<int>(p.key_id_size));
+ WriteParam(m, p.key_status);
+ WriteParam(m, p.system_code);
+}
+
+// static
+bool ParamTraits<PP_KeyInformation>::Read(const Message* m,
+ PickleIterator* iter,
+ param_type* p) {
+ uint32_t size;
+ if (!ReadParam(m, iter, &size))
+ return false;
+ if (size > sizeof(p->key_id))
+ return false;
+ p->key_id_size = size;
+
+ const char* data;
+ if (!iter->ReadBytes(&data, size))
+ return false;
+ memcpy(p->key_id, data, size);
+
+ PP_CdmKeyStatus key_status;
+ if (!ReadParam(m, iter, &key_status))
+ return false;
+ p->key_status = key_status;
+
+ uint32_t system_code;
+ if (!ReadParam(m, iter, &system_code))
+ return false;
+ p->system_code = system_code;
+
+ return true;
+}
+
+// static
+void ParamTraits<PP_KeyInformation>::Log(const param_type& p, std::string* l) {
+ l->append("<PP_KeyInformation (");
+ LogParam(p.key_id_size, l);
+ l->append(" bytes)>");
+}
+
// PP_NetAddress_Private -------------------------------------------------------
// static
diff --git a/ppapi/proxy/ppapi_param_traits.h b/ppapi/proxy/ppapi_param_traits.h
index 76dd10d..d2d4762 100644
--- a/ppapi/proxy/ppapi_param_traits.h
+++ b/ppapi/proxy/ppapi_param_traits.h
@@ -21,6 +21,7 @@
#include "ppapi/shared_impl/ppapi_permissions.h"
#include "ppapi/shared_impl/socket_option_data.h"
+struct PP_KeyInformation;
struct PP_NetAddress_Private;
namespace ppapi {
@@ -60,6 +61,14 @@ struct PPAPI_PROXY_EXPORT ParamTraits<PP_NetAddress_Private> {
static void Log(const param_type& p, std::string* l);
};
+template <>
+struct PPAPI_PROXY_EXPORT ParamTraits<PP_KeyInformation> {
+ typedef PP_KeyInformation param_type;
+ static void Write(Message* m, const param_type& p);
+ static bool Read(const Message* m, PickleIterator* iter, param_type* p);
+ static void Log(const param_type& p, std::string* l);
+};
+
template<>
struct PPAPI_PROXY_EXPORT ParamTraits<
ppapi::proxy::PPBFlash_DrawGlyphs_Params> {
diff --git a/ppapi/proxy/ppb_instance_proxy.cc b/ppapi/proxy/ppb_instance_proxy.cc
index 1dfb897..32ee8b2 100644
--- a/ppapi/proxy/ppb_instance_proxy.cc
+++ b/ppapi/proxy/ppb_instance_proxy.cc
@@ -5,6 +5,7 @@
#include "ppapi/proxy/ppb_instance_proxy.h"
#include "base/memory/ref_counted.h"
+#include "base/stl_util.h"
#include "build/build_config.h"
#include "media/base/limits.h"
#include "ppapi/c/pp_errors.h"
@@ -182,8 +183,6 @@ bool PPB_Instance_Proxy::OnMessageReceived(const IPC::Message& msg) {
OnHostMsgPromiseResolved)
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_PromiseResolvedWithSession,
OnHostMsgPromiseResolvedWithSession)
- IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_PromiseResolvedWithKeyIds,
- OnHostMsgPromiseResolvedWithKeyIds)
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_PromiseRejected,
OnHostMsgPromiseRejected)
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_SessionMessage,
@@ -192,8 +191,6 @@ bool PPB_Instance_Proxy::OnMessageReceived(const IPC::Message& msg) {
OnHostMsgSessionKeysChange)
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_SessionExpirationChange,
OnHostMsgSessionExpirationChange)
- IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_SessionReady,
- OnHostMsgSessionReady)
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_SessionClosed,
OnHostMsgSessionClosed)
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_SessionError,
@@ -586,35 +583,6 @@ void PPB_Instance_Proxy::PromiseResolvedWithSession(PP_Instance instance,
SerializedVarSendInput(dispatcher(), web_session_id_var)));
}
-void PPB_Instance_Proxy::PromiseResolvedWithKeyIds(PP_Instance instance,
- uint32 promise_id,
- PP_Var key_ids_var) {
- ArrayVar* key_ids_array = ArrayVar::FromPPVar(key_ids_var);
- if (!key_ids_array ||
- key_ids_array->GetLength() > media::limits::kMaxKeyIds) {
- NOTREACHED();
- return;
- }
-
- std::vector<std::vector<uint8_t> > key_ids;
- for (size_t i = 0; i < key_ids_array->GetLength(); ++i) {
- ArrayBufferVar* key_id = ArrayBufferVar::FromPPVar(key_ids_array->Get(i));
- if (!key_id || key_id->ByteLength() < media::limits::kMinKeyIdLength ||
- key_id->ByteLength() > media::limits::kMaxKeyIdLength) {
- NOTREACHED();
- continue;
- }
-
- const uint8_t* key_id_ptr = static_cast<const uint8_t*>(key_id->Map());
- const uint32_t key_id_size = key_id->ByteLength();
- std::vector<uint8_t> key_id_vector(key_id_ptr, key_id_ptr + key_id_size);
- key_ids.push_back(key_id_vector);
- }
-
- dispatcher()->Send(new PpapiHostMsg_PPBInstance_PromiseResolvedWithKeyIds(
- API_ID_PPB_INSTANCE, instance, promise_id, key_ids));
-}
-
void PPB_Instance_Proxy::PromiseRejected(PP_Instance instance,
uint32 promise_id,
PP_CdmExceptionCode exception_code,
@@ -631,19 +599,20 @@ void PPB_Instance_Proxy::PromiseRejected(PP_Instance instance,
void PPB_Instance_Proxy::SessionMessage(PP_Instance instance,
PP_Var web_session_id_var,
- PP_Var message_var,
- PP_Var destination_url_var) {
+ PP_CdmMessageType message_type,
+ PP_Var message_var) {
dispatcher()->Send(new PpapiHostMsg_PPBInstance_SessionMessage(
- API_ID_PPB_INSTANCE,
- instance,
- SerializedVarSendInput(dispatcher(), web_session_id_var),
- SerializedVarSendInput(dispatcher(), message_var),
- SerializedVarSendInput(dispatcher(), destination_url_var)));
+ API_ID_PPB_INSTANCE, instance,
+ SerializedVarSendInput(dispatcher(), web_session_id_var), message_type,
+ SerializedVarSendInput(dispatcher(), message_var)));
}
-void PPB_Instance_Proxy::SessionKeysChange(PP_Instance instance,
- PP_Var web_session_id_var,
- PP_Bool has_additional_usable_key) {
+void PPB_Instance_Proxy::SessionKeysChange(
+ PP_Instance instance,
+ PP_Var web_session_id_var,
+ PP_Bool has_additional_usable_key,
+ uint32_t key_count,
+ const struct PP_KeyInformation key_information[]) {
StringVar* session_id = StringVar::FromPPVar(web_session_id_var);
if (!session_id ||
session_id->value().length() > media::limits::kMaxWebSessionIdLength) {
@@ -651,11 +620,16 @@ void PPB_Instance_Proxy::SessionKeysChange(PP_Instance instance,
return;
}
+ if (key_count > media::limits::kMaxKeyIds) {
+ NOTREACHED();
+ return;
+ }
+
dispatcher()->Send(new PpapiHostMsg_PPBInstance_SessionKeysChange(
- API_ID_PPB_INSTANCE,
- instance,
- session_id->value(),
- has_additional_usable_key));
+ API_ID_PPB_INSTANCE, instance, session_id->value(),
+ has_additional_usable_key,
+ std::vector<PP_KeyInformation>(key_information,
+ key_information + key_count)));
}
void PPB_Instance_Proxy::SessionExpirationChange(PP_Instance instance,
@@ -672,14 +646,6 @@ void PPB_Instance_Proxy::SessionExpirationChange(PP_Instance instance,
API_ID_PPB_INSTANCE, instance, session_id->value(), new_expiry_time));
}
-void PPB_Instance_Proxy::SessionReady(PP_Instance instance,
- PP_Var web_session_id_var) {
- dispatcher()->Send(new PpapiHostMsg_PPBInstance_SessionReady(
- API_ID_PPB_INSTANCE,
- instance,
- SerializedVarSendInput(dispatcher(), web_session_id_var)));
-}
-
void PPB_Instance_Proxy::SessionClosed(PP_Instance instance,
PP_Var web_session_id_var) {
dispatcher()->Send(new PpapiHostMsg_PPBInstance_SessionClosed(
@@ -1286,40 +1252,6 @@ void PPB_Instance_Proxy::OnHostMsgPromiseResolvedWithSession(
}
}
-void PPB_Instance_Proxy::OnHostMsgPromiseResolvedWithKeyIds(
- PP_Instance instance,
- uint32_t promise_id,
- const std::vector<std::vector<uint8_t> >& key_ids) {
- if (!dispatcher()->permissions().HasPermission(PERMISSION_PRIVATE))
- return;
- if (key_ids.size() > media::limits::kMaxKeyIds) {
- NOTREACHED();
- return;
- }
-
- scoped_refptr<ArrayVar> key_ids_array = new ArrayVar();
- key_ids_array->SetLength(key_ids.size());
- for (size_t i = 0; i < key_ids.size(); ++i) {
- const std::vector<uint8_t>& entry = key_ids[i];
- if (entry.size() < media::limits::kMinKeyIdLength ||
- entry.size() > media::limits::kMaxKeyIdLength) {
- NOTREACHED();
- continue;
- }
- key_ids_array->Set(
- i,
- PpapiGlobals::Get()->GetVarTracker()->MakeArrayBufferPPVar(entry.size(),
- &entry[0]));
- }
-
- EnterInstanceNoLock enter(instance);
- if (enter.succeeded()) {
- ScopedPPVar key_ids_var(ScopedPPVar::PassRef(), key_ids_array->GetPPVar());
- enter.functions()->PromiseResolvedWithKeyIds(
- instance, promise_id, key_ids_var.get());
- }
-}
-
void PPB_Instance_Proxy::OnHostMsgPromiseRejected(
PP_Instance instance,
uint32_t promise_id,
@@ -1341,31 +1273,38 @@ void PPB_Instance_Proxy::OnHostMsgPromiseRejected(
void PPB_Instance_Proxy::OnHostMsgSessionMessage(
PP_Instance instance,
SerializedVarReceiveInput web_session_id,
- SerializedVarReceiveInput message,
- SerializedVarReceiveInput destination_url) {
+ PP_CdmMessageType message_type,
+ SerializedVarReceiveInput message) {
if (!dispatcher()->permissions().HasPermission(PERMISSION_PRIVATE))
return;
EnterInstanceNoLock enter(instance);
if (enter.succeeded()) {
enter.functions()->SessionMessage(instance,
web_session_id.Get(dispatcher()),
- message.Get(dispatcher()),
- destination_url.Get(dispatcher()));
+ message_type, message.Get(dispatcher()));
}
}
void PPB_Instance_Proxy::OnHostMsgSessionKeysChange(
PP_Instance instance,
const std::string& web_session_id,
- PP_Bool has_additional_usable_key) {
+ PP_Bool has_additional_usable_key,
+ const std::vector<PP_KeyInformation>& key_information) {
if (!dispatcher()->permissions().HasPermission(PERMISSION_PRIVATE))
return;
+
+ if (key_information.size() > media::limits::kMaxKeyIds) {
+ NOTREACHED();
+ return;
+ }
+
EnterInstanceNoLock enter(instance);
if (enter.succeeded()) {
ScopedPPVar web_session_id_var(ScopedPPVar::PassRef(),
StringVar::StringToPPVar(web_session_id));
enter.functions()->SessionKeysChange(
- instance, web_session_id_var.get(), has_additional_usable_key);
+ instance, web_session_id_var.get(), has_additional_usable_key,
+ key_information.size(), vector_as_array(&key_information));
}
}
@@ -1384,17 +1323,6 @@ void PPB_Instance_Proxy::OnHostMsgSessionExpirationChange(
}
}
-void PPB_Instance_Proxy::OnHostMsgSessionReady(
- PP_Instance instance,
- SerializedVarReceiveInput web_session_id) {
- if (!dispatcher()->permissions().HasPermission(PERMISSION_PRIVATE))
- return;
- EnterInstanceNoLock enter(instance);
- if (enter.succeeded()) {
- enter.functions()->SessionReady(instance, web_session_id.Get(dispatcher()));
- }
-}
-
void PPB_Instance_Proxy::OnHostMsgSessionClosed(
PP_Instance instance,
SerializedVarReceiveInput web_session_id) {
diff --git a/ppapi/proxy/ppb_instance_proxy.h b/ppapi/proxy/ppb_instance_proxy.h
index e45bccc..d6ed5c4 100644
--- a/ppapi/proxy/ppb_instance_proxy.h
+++ b/ppapi/proxy/ppb_instance_proxy.h
@@ -136,9 +136,6 @@ class PPB_Instance_Proxy : public InterfaceProxy,
virtual void PromiseResolvedWithSession(PP_Instance instance,
uint32 promise_id,
PP_Var web_session_id_var) override;
- virtual void PromiseResolvedWithKeyIds(PP_Instance instance,
- uint32 promise_id,
- PP_Var key_ids_var) override;
virtual void PromiseRejected(PP_Instance instance,
uint32 promise_id,
PP_CdmExceptionCode exception_code,
@@ -146,16 +143,17 @@ class PPB_Instance_Proxy : public InterfaceProxy,
PP_Var error_description_var) override;
virtual void SessionMessage(PP_Instance instance,
PP_Var web_session_id_var,
- PP_Var message_var,
- PP_Var destination_url_var) override;
- virtual void SessionKeysChange(PP_Instance instance,
- PP_Var web_session_id_var,
- PP_Bool has_additional_usable_key) override;
+ PP_CdmMessageType message_type,
+ PP_Var message_var) override;
+ virtual void SessionKeysChange(
+ PP_Instance instance,
+ PP_Var web_session_id_var,
+ PP_Bool has_additional_usable_key,
+ uint32_t key_count,
+ const struct PP_KeyInformation key_information[]) override;
virtual void SessionExpirationChange(PP_Instance instance,
PP_Var web_session_id_var,
PP_Time new_expiry_time) override;
- virtual void SessionReady(PP_Instance instance,
- PP_Var web_session_id_var) override;
virtual void SessionClosed(PP_Instance instance,
PP_Var web_session_id_var) override;
virtual void SessionError(PP_Instance instance,
@@ -269,30 +267,25 @@ class PPB_Instance_Proxy : public InterfaceProxy,
PP_Instance instance,
uint32_t promise_id,
SerializedVarReceiveInput web_session_id);
- virtual void OnHostMsgPromiseResolvedWithKeyIds(
- PP_Instance instance,
- uint32 promise_id,
- const std::vector<std::vector<uint8_t> >& key_ids);
virtual void OnHostMsgPromiseRejected(
PP_Instance instance,
uint32_t promise_id,
PP_CdmExceptionCode exception_code,
uint32_t system_code,
SerializedVarReceiveInput error_description);
- virtual void OnHostMsgSessionMessage(
+ virtual void OnHostMsgSessionMessage(PP_Instance instance,
+ SerializedVarReceiveInput web_session_id,
+ PP_CdmMessageType message_type,
+ SerializedVarReceiveInput message);
+ virtual void OnHostMsgSessionKeysChange(
PP_Instance instance,
- SerializedVarReceiveInput web_session_id,
- SerializedVarReceiveInput message,
- SerializedVarReceiveInput destination_url);
- virtual void OnHostMsgSessionKeysChange(PP_Instance instance,
- const std::string& web_session_id,
- PP_Bool has_additional_usable_key);
+ const std::string& web_session_id,
+ PP_Bool has_additional_usable_key,
+ const std::vector<PP_KeyInformation>& key_information);
virtual void OnHostMsgSessionExpirationChange(
PP_Instance instance,
const std::string& web_session_id,
PP_Time new_expiry_time);
- virtual void OnHostMsgSessionReady(PP_Instance instance,
- SerializedVarReceiveInput web_session_id);
virtual void OnHostMsgSessionClosed(PP_Instance instance,
SerializedVarReceiveInput web_session_id);
virtual void OnHostMsgSessionError(
diff --git a/ppapi/proxy/ppp_content_decryptor_private_proxy.cc b/ppapi/proxy/ppp_content_decryptor_private_proxy.cc
index e956d12..0ec1d10 100644
--- a/ppapi/proxy/ppp_content_decryptor_private_proxy.cc
+++ b/ppapi/proxy/ppp_content_decryptor_private_proxy.cc
@@ -160,28 +160,27 @@ void SetServerCertificate(PP_Instance instance,
server_certificate_vector));
}
-void CreateSession(PP_Instance instance,
- uint32_t promise_id,
- PP_Var init_data_type,
- PP_Var init_data,
- PP_SessionType session_type) {
+void CreateSessionAndGenerateRequest(PP_Instance instance,
+ uint32_t promise_id,
+ PP_SessionType session_type,
+ PP_Var init_data_type,
+ PP_Var init_data) {
HostDispatcher* dispatcher = HostDispatcher::GetForInstance(instance);
if (!dispatcher) {
NOTREACHED();
return;
}
- dispatcher->Send(new PpapiMsg_PPPContentDecryptor_CreateSession(
- API_ID_PPP_CONTENT_DECRYPTOR_PRIVATE,
- instance,
- promise_id,
- SerializedVarSendInput(dispatcher, init_data_type),
- SerializedVarSendInput(dispatcher, init_data),
- session_type));
+ dispatcher->Send(
+ new PpapiMsg_PPPContentDecryptor_CreateSessionAndGenerateRequest(
+ API_ID_PPP_CONTENT_DECRYPTOR_PRIVATE, instance, promise_id,
+ session_type, SerializedVarSendInput(dispatcher, init_data_type),
+ SerializedVarSendInput(dispatcher, init_data)));
}
void LoadSession(PP_Instance instance,
uint32_t promise_id,
+ PP_SessionType session_type,
PP_Var web_session_id) {
HostDispatcher* dispatcher = HostDispatcher::GetForInstance(instance);
if (!dispatcher) {
@@ -190,9 +189,7 @@ void LoadSession(PP_Instance instance,
}
dispatcher->Send(new PpapiMsg_PPPContentDecryptor_LoadSession(
- API_ID_PPP_CONTENT_DECRYPTOR_PRIVATE,
- instance,
- promise_id,
+ API_ID_PPP_CONTENT_DECRYPTOR_PRIVATE, instance, promise_id, session_type,
SerializedVarSendInput(dispatcher, web_session_id)));
}
@@ -260,29 +257,6 @@ void RemoveSession(PP_Instance instance,
session_id->value()));
}
-void GetUsableKeyIds(PP_Instance instance,
- uint32_t promise_id,
- PP_Var web_session_id) {
- HostDispatcher* dispatcher = HostDispatcher::GetForInstance(instance);
- if (!dispatcher) {
- NOTREACHED();
- return;
- }
-
- StringVar* session_id = StringVar::FromPPVar(web_session_id);
- if (!session_id ||
- session_id->value().length() > media::limits::kMaxWebSessionIdLength) {
- NOTREACHED();
- return;
- }
-
- dispatcher->Send(new PpapiMsg_PPPContentDecryptor_GetUsableKeyIds(
- API_ID_PPP_CONTENT_DECRYPTOR_PRIVATE,
- instance,
- promise_id,
- session_id->value()));
-}
-
void Decrypt(PP_Instance instance,
PP_Resource encrypted_block,
const PP_EncryptedBlockInfo* encrypted_block_info) {
@@ -473,12 +447,11 @@ void DecryptAndDecode(PP_Instance instance,
static const PPP_ContentDecryptor_Private content_decryptor_interface = {
&Initialize,
&SetServerCertificate,
- &CreateSession,
+ &CreateSessionAndGenerateRequest,
&LoadSession,
&UpdateSession,
&CloseSession,
&RemoveSession,
- &GetUsableKeyIds,
&Decrypt,
&InitializeAudioDecoder,
&InitializeVideoDecoder,
@@ -520,8 +493,9 @@ bool PPP_ContentDecryptor_Private_Proxy::OnMessageReceived(
OnMsgInitialize)
IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_SetServerCertificate,
OnMsgSetServerCertificate)
- IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_CreateSession,
- OnMsgCreateSession)
+ IPC_MESSAGE_HANDLER(
+ PpapiMsg_PPPContentDecryptor_CreateSessionAndGenerateRequest,
+ OnMsgCreateSessionAndGenerateRequest)
IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_LoadSession,
OnMsgLoadSession)
IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_UpdateSession,
@@ -530,8 +504,6 @@ bool PPP_ContentDecryptor_Private_Proxy::OnMessageReceived(
OnMsgCloseSession)
IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_RemoveSession,
OnMsgRemoveSession)
- IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_GetUsableKeyIds,
- OnMsgGetUsableKeyIds)
IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_Decrypt,
OnMsgDecrypt)
IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_InitializeAudioDecoder,
@@ -585,32 +557,29 @@ void PPP_ContentDecryptor_Private_Proxy::OnMsgSetServerCertificate(
}
}
-void PPP_ContentDecryptor_Private_Proxy::OnMsgCreateSession(
+void PPP_ContentDecryptor_Private_Proxy::OnMsgCreateSessionAndGenerateRequest(
PP_Instance instance,
uint32_t promise_id,
+ PP_SessionType session_type,
SerializedVarReceiveInput init_data_type,
- SerializedVarReceiveInput init_data,
- PP_SessionType session_type) {
+ SerializedVarReceiveInput init_data) {
if (ppp_decryptor_impl_) {
CallWhileUnlocked(
- ppp_decryptor_impl_->CreateSession,
- instance,
- promise_id,
+ ppp_decryptor_impl_->CreateSessionAndGenerateRequest, instance,
+ promise_id, session_type,
ExtractReceivedVarAndAddRef(dispatcher(), &init_data_type),
- ExtractReceivedVarAndAddRef(dispatcher(), &init_data),
- session_type);
+ ExtractReceivedVarAndAddRef(dispatcher(), &init_data));
}
}
void PPP_ContentDecryptor_Private_Proxy::OnMsgLoadSession(
PP_Instance instance,
uint32_t promise_id,
+ PP_SessionType session_type,
SerializedVarReceiveInput web_session_id) {
if (ppp_decryptor_impl_) {
CallWhileUnlocked(
- ppp_decryptor_impl_->LoadSession,
- instance,
- promise_id,
+ ppp_decryptor_impl_->LoadSession, instance, promise_id, session_type,
ExtractReceivedVarAndAddRef(dispatcher(), &web_session_id));
}
}
@@ -658,20 +627,6 @@ void PPP_ContentDecryptor_Private_Proxy::OnMsgRemoveSession(
}
}
-void PPP_ContentDecryptor_Private_Proxy::OnMsgGetUsableKeyIds(
- PP_Instance instance,
- uint32_t promise_id,
- const std::string& web_session_id) {
- if (ppp_decryptor_impl_) {
- ScopedPPVar web_session_id_var(ScopedPPVar::PassRef(),
- StringVar::StringToPPVar(web_session_id));
- CallWhileUnlocked(ppp_decryptor_impl_->GetUsableKeyIds,
- instance,
- promise_id,
- web_session_id_var.get());
- }
-}
-
void PPP_ContentDecryptor_Private_Proxy::OnMsgDecrypt(
PP_Instance instance,
const PPPDecryptor_Buffer& encrypted_buffer,
diff --git a/ppapi/proxy/ppp_content_decryptor_private_proxy.h b/ppapi/proxy/ppp_content_decryptor_private_proxy.h
index 217a9b9..398be63 100644
--- a/ppapi/proxy/ppp_content_decryptor_private_proxy.h
+++ b/ppapi/proxy/ppp_content_decryptor_private_proxy.h
@@ -36,13 +36,15 @@ class PPP_ContentDecryptor_Private_Proxy : public InterfaceProxy {
void OnMsgSetServerCertificate(PP_Instance instance,
uint32_t promise_id,
std::vector<uint8_t> server_certificate);
- void OnMsgCreateSession(PP_Instance instance,
- uint32_t promise_id,
- SerializedVarReceiveInput init_data_type,
- SerializedVarReceiveInput init_data,
- PP_SessionType session_type);
+ void OnMsgCreateSessionAndGenerateRequest(
+ PP_Instance instance,
+ uint32_t promise_id,
+ PP_SessionType session_type,
+ SerializedVarReceiveInput init_data_type,
+ SerializedVarReceiveInput init_data);
void OnMsgLoadSession(PP_Instance instance,
uint32_t promise_id,
+ PP_SessionType session_type,
SerializedVarReceiveInput web_session_id);
void OnMsgUpdateSession(PP_Instance instance,
uint32_t promise_id,
@@ -54,9 +56,6 @@ class PPP_ContentDecryptor_Private_Proxy : public InterfaceProxy {
void OnMsgRemoveSession(PP_Instance instance,
uint32_t promise_id,
const std::string& web_session_id);
- void OnMsgGetUsableKeyIds(PP_Instance instance,
- uint32_t promise_id,
- const std::string& web_session_id);
void OnMsgDecrypt(PP_Instance instance,
const PPPDecryptor_Buffer& encrypted_buffer,
const std::string& serialized_encrypted_block_info);
diff --git a/ppapi/thunk/interfaces_ppb_private.h b/ppapi/thunk/interfaces_ppb_private.h
index e4aff22..70c6c2e 100644
--- a/ppapi/thunk/interfaces_ppb_private.h
+++ b/ppapi/thunk/interfaces_ppb_private.h
@@ -23,8 +23,8 @@ PROXIED_IFACE(PPB_BROKER_TRUSTED_INTERFACE_0_3,
PPB_BrokerTrusted_0_3)
PROXIED_IFACE(PPB_BROWSERFONT_TRUSTED_INTERFACE_1_0,
PPB_BrowserFont_Trusted_1_0)
-PROXIED_IFACE(PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_12,
- PPB_ContentDecryptor_Private_0_12)
+PROXIED_IFACE(PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_13,
+ PPB_ContentDecryptor_Private_0_13)
PROXIED_IFACE(PPB_CHARSET_TRUSTED_INTERFACE_1_0,
PPB_CharSet_Trusted_1_0)
PROXIED_IFACE(PPB_FILECHOOSER_TRUSTED_INTERFACE_0_5,
diff --git a/ppapi/thunk/ppb_content_decryptor_private_thunk.cc b/ppapi/thunk/ppb_content_decryptor_private_thunk.cc
index fc601d6..6f359f3 100644
--- a/ppapi/thunk/ppb_content_decryptor_private_thunk.cc
+++ b/ppapi/thunk/ppb_content_decryptor_private_thunk.cc
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// From private/ppb_content_decryptor_private.idl modified Wed Nov 5 14:29:15
-// 2014.
+// From private/ppb_content_decryptor_private.idl modified Wed Jan 7 16:48:10
+// 2015.
#include "ppapi/c/pp_errors.h"
#include "ppapi/c/private/ppb_content_decryptor_private.h"
@@ -35,17 +35,6 @@ void PromiseResolvedWithSession(PP_Instance instance,
web_session_id);
}
-void PromiseResolvedWithKeyIds(PP_Instance instance,
- uint32_t promise_id,
- struct PP_Var key_ids_array) {
- VLOG(4) << "PPB_ContentDecryptor_Private::PromiseResolvedWithKeyIds()";
- EnterInstance enter(instance);
- if (enter.failed())
- return;
- enter.functions()->PromiseResolvedWithKeyIds(instance, promise_id,
- key_ids_array);
-}
-
void PromiseRejected(PP_Instance instance,
uint32_t promise_id,
PP_CdmExceptionCode exception_code,
@@ -61,25 +50,28 @@ void PromiseRejected(PP_Instance instance,
void SessionMessage(PP_Instance instance,
struct PP_Var web_session_id,
- struct PP_Var message,
- struct PP_Var destination_url) {
+ PP_CdmMessageType message_type,
+ struct PP_Var message) {
VLOG(4) << "PPB_ContentDecryptor_Private::SessionMessage()";
EnterInstance enter(instance);
if (enter.failed())
return;
- enter.functions()->SessionMessage(instance, web_session_id, message,
- destination_url);
+ enter.functions()->SessionMessage(instance, web_session_id, message_type,
+ message);
}
void SessionKeysChange(PP_Instance instance,
struct PP_Var web_session_id,
- PP_Bool has_additional_usable_key) {
+ PP_Bool has_additional_usable_key,
+ uint32_t key_count,
+ const struct PP_KeyInformation key_information[]) {
VLOG(4) << "PPB_ContentDecryptor_Private::SessionKeysChange()";
EnterInstance enter(instance);
if (enter.failed())
return;
enter.functions()->SessionKeysChange(instance, web_session_id,
- has_additional_usable_key);
+ has_additional_usable_key, key_count,
+ key_information);
}
void SessionExpirationChange(PP_Instance instance,
@@ -93,14 +85,6 @@ void SessionExpirationChange(PP_Instance instance,
new_expiry_time);
}
-void SessionReady(PP_Instance instance, struct PP_Var web_session_id) {
- VLOG(4) << "PPB_ContentDecryptor_Private::SessionReady()";
- EnterInstance enter(instance);
- if (enter.failed())
- return;
- enter.functions()->SessionReady(instance, web_session_id);
-}
-
void SessionClosed(PP_Instance instance, struct PP_Var web_session_id) {
VLOG(4) << "PPB_ContentDecryptor_Private::SessionClosed()";
EnterInstance enter(instance);
@@ -189,15 +173,13 @@ void DeliverSamples(
decrypted_sample_info);
}
-const PPB_ContentDecryptor_Private_0_12
- g_ppb_contentdecryptor_private_thunk_0_12 = {&PromiseResolved,
+const PPB_ContentDecryptor_Private_0_13
+ g_ppb_contentdecryptor_private_thunk_0_13 = {&PromiseResolved,
&PromiseResolvedWithSession,
- &PromiseResolvedWithKeyIds,
&PromiseRejected,
&SessionMessage,
&SessionKeysChange,
&SessionExpirationChange,
- &SessionReady,
&SessionClosed,
&SessionError,
&DeliverBlock,
@@ -209,9 +191,9 @@ const PPB_ContentDecryptor_Private_0_12
} // namespace
-PPAPI_THUNK_EXPORT const PPB_ContentDecryptor_Private_0_12*
-GetPPB_ContentDecryptor_Private_0_12_Thunk() {
- return &g_ppb_contentdecryptor_private_thunk_0_12;
+PPAPI_THUNK_EXPORT const PPB_ContentDecryptor_Private_0_13*
+GetPPB_ContentDecryptor_Private_0_13_Thunk() {
+ return &g_ppb_contentdecryptor_private_thunk_0_13;
}
} // namespace thunk
diff --git a/ppapi/thunk/ppb_instance_api.h b/ppapi/thunk/ppb_instance_api.h
index 997c32e..5f84de5 100644
--- a/ppapi/thunk/ppb_instance_api.h
+++ b/ppapi/thunk/ppb_instance_api.h
@@ -166,9 +166,6 @@ class PPB_Instance_API {
virtual void PromiseResolvedWithSession(PP_Instance instance,
uint32 promise_id,
PP_Var web_session_id_var) = 0;
- virtual void PromiseResolvedWithKeyIds(PP_Instance instance,
- uint32 promise_id,
- PP_Var key_ids_var) = 0;
virtual void PromiseRejected(PP_Instance instance,
uint32 promise_id,
PP_CdmExceptionCode exception_code,
@@ -176,16 +173,17 @@ class PPB_Instance_API {
PP_Var error_description_var) = 0;
virtual void SessionMessage(PP_Instance instance,
PP_Var web_session_id_var,
- PP_Var message_var,
- PP_Var destination_url_var) = 0;
- virtual void SessionKeysChange(PP_Instance instance,
- PP_Var web_session_id_var,
- PP_Bool has_additional_usable_key) = 0;
+ PP_CdmMessageType message_type,
+ PP_Var message_var) = 0;
+ virtual void SessionKeysChange(
+ PP_Instance instance,
+ PP_Var web_session_id_var,
+ PP_Bool has_additional_usable_key,
+ uint32_t key_count,
+ const struct PP_KeyInformation key_information[]) = 0;
virtual void SessionExpirationChange(PP_Instance instance,
PP_Var web_session_id_var,
PP_Time new_expiry_time) = 0;
- virtual void SessionReady(PP_Instance instance,
- PP_Var web_session_id_var) = 0;
virtual void SessionClosed(PP_Instance instance,
PP_Var web_session_id_var) = 0;
virtual void SessionError(PP_Instance instance,