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

Unified Diff: media/base/decrypt_config.h

Issue 10807003: Revert 147169 - Add support for encrypted WebM files as defined in the RFC. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | media/base/decrypt_config.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/decrypt_config.h
===================================================================
--- media/base/decrypt_config.h (revision 147171)
+++ media/base/decrypt_config.h (working copy)
@@ -11,50 +11,19 @@
namespace media {
-// Contains all information that a decryptor needs to decrypt a frame.
+// Contains all information that a decryptor needs to decrypt.
class MEDIA_EXPORT DecryptConfig {
public:
- // Keys are always 128 bits.
- static const int kDecryptionKeySize = 16;
-
- // |key_id| is the ID that references the decryption key for this frame. |iv|
- // is the initialization vector defined by the encrypted format. Currently
- // |iv_size| must be 16 bytes as defined by WebM and ISO. |checksum| is the
- // hash value of the encrypted buffer. |checksum| is defined by the
- // encrypted format and may be NULL. |encrypted_frame_offset| is the offset
- // into the encrypted buffer that the encrypted frame starts. The class
- // will copy the data from |key_id|, |iv|, and |checksum|.
- DecryptConfig(const uint8* key_id, int key_id_size,
- const uint8* iv, int iv_size,
- const uint8* checksum, int checksum_size,
- int encrypted_frame_offset);
+ explicit DecryptConfig(const uint8* key_id, int key_id_size);
~DecryptConfig();
const uint8* key_id() const { return key_id_.get(); }
int key_id_size() const { return key_id_size_; }
- const uint8* iv() const { return iv_.get(); }
- int iv_size() const { return iv_size_; }
- const uint8* checksum() const { return checksum_.get(); }
- int checksum_size() const { return checksum_size_; }
- int encrypted_frame_offset() const { return encrypted_frame_offset_; }
private:
- const scoped_array<uint8> key_id_;
- const int key_id_size_;
+ scoped_array<uint8> key_id_;
+ int key_id_size_;
- // Initialization vector.
- const scoped_array<uint8> iv_;
- const int iv_size_;
-
- // Checksum of the data to be verified before decrypting the data. This may
- // be NULL for some formats.
- const scoped_array<uint8> checksum_;
- const int checksum_size_;
-
- // This is the offset in bytes to where the encrypted data starts within
- // the input buffer.
- const int encrypted_frame_offset_;
-
DISALLOW_COPY_AND_ASSIGN(DecryptConfig);
};
« no previous file with comments | « no previous file | media/base/decrypt_config.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698