7 #ifndef PACKAGER_MEDIA_PUBLIC_CRYPTO_PARAMS_H_
8 #define PACKAGER_MEDIA_PUBLIC_CRYPTO_PARAMS_H_
15 #include "packager/status.h"
36 kPlayReady = (1 << 2),
43 static_cast<uint16_t
>(b));
50 static_cast<uint16_t
>(b));
59 return (value & flag) == flag;
67 enum class SigningKeyType {
77 std::vector<uint8_t>
key;
79 std::vector<uint8_t>
iv;
127 std::vector<uint8_t>
iv;
133 using StreamLabel = std::string;
135 std::vector<uint8_t> key_id;
136 std::vector<uint8_t> key;
137 std::vector<uint8_t> iv;
165 static constexpr uint32_t kProtectionSchemeCbc1 = 0x63626331;
166 static constexpr uint32_t kProtectionSchemeCens = 0x63656E73;
167 static constexpr uint32_t kProtectionSchemeCbcs = 0x63626373;
194 StreamType stream_type = kUnknown;
201 float frame_rate = 0;
206 int number_of_channels = 0;
All the methods that are virtual are virtual for mocking.
@ kCommon
The common key system from EME: https://goo.gl/s8RIhr.
Encrypted stream information that is used to determine stream label.
double clear_lead_in_seconds
Clear lead duration in seconds.
static constexpr uint32_t kProtectionSchemeCenc
The protection scheme: "cenc", "cens", "cbc1", "cbcs".
bool vp9_subsample_encryption
Enable/disable subsample encryption for VP9.
std::string playready_extra_header_data
Extra XML data to add to PlayReady data.
std::function< std::string(const EncryptedStreamAttributes &stream_attributes)> stream_label_func
ProtectionSystem protection_systems
The protection systems to generate, multiple can be OR'd together.
static constexpr double kNoKeyRotation
std::string client_cert_private_key_file
Absolute path to the private key file.
std::string client_cert_private_key_password
Password to the private key file.
std::string program_identifier
PlayReady program identifier.
std::string client_cert_file
Absolute path to client certificate file.
std::string key_server_url
PlayReady license / key server URL.
Raw key encryption/decryption parameters, i.e. with key parameters provided.
std::map< StreamLabel, KeyInfo > key_map
std::vector< uint8_t > pssh
std::vector< uint8_t > iv
Widevine decryption parameters.
WidevineSigner signer
Signer credential for Widevine license / key server.
std::string key_server_url
Widevine license / key server URL.
Widevine encryption parameters.
WidevineSigner signer
Signer credential for Widevine license / key server.
std::string policy
The name of a stored policy, which specifies DRM content rights.
bool enable_entitlement_license
Enables entitlement license when set to true.
std::vector< uint8_t > content_id
Content identifier.
std::vector< uint8_t > group_id
Group identifier, if present licenses will belong to this group.
std::string key_server_url
Widevine license / key server URL.
Signer credential for Widevine license server.
std::string key
RSA signing private key.
SigningKeyType signing_key_type
std::string signer_name
Name of the signer / content provider.
std::vector< uint8_t > iv
AES signing IV.
std::vector< uint8_t > key
AES signing key.