Index: media/crypto/aes_decryptor.h |
diff --git a/media/crypto/aes_decryptor.h b/media/crypto/aes_decryptor.h |
index d62528f0fa73beeedf61e39596b2856e9548196c..70e1ac03b9482e486b9e84d36b35ef64b8b661bf 100644 |
--- a/media/crypto/aes_decryptor.h |
+++ b/media/crypto/aes_decryptor.h |
@@ -10,8 +10,8 @@ |
#include "base/basictypes.h" |
#include "base/hash_tables.h" |
#include "base/memory/ref_counted.h" |
-#include "base/synchronization/lock.h" |
#include "media/base/media_export.h" |
+#include "media/crypto/decryptor.h" |
namespace crypto { |
class SymmetricKey; |
@@ -22,30 +22,30 @@ namespace media { |
class DecoderBuffer; |
// Decrypts AES encrypted buffer into unencrypted buffer. |
-class MEDIA_EXPORT AesDecryptor { |
+class MEDIA_EXPORT AesDecryptor : public Decryptor { |
public: |
AesDecryptor(); |
- ~AesDecryptor(); |
+ virtual ~AesDecryptor(); |
+ // Decryptor implementation. |
// Add a |key_id| and |key| pair to the key system. The key is not limited to |
// a decryption key. It can be any data that the key system accepts, such as |
// a license. If multiple calls of this function set different keys for the |
// same |key_id|, the older key will be replaced by the newer key. |
- void AddKey(const uint8* key_id, int key_id_size, |
- const uint8* key, int key_size); |
+ virtual void AddKey(const uint8* key_id, int key_id_size, |
+ const uint8* key, int key_size) OVERRIDE; |
// Decrypt |input| buffer. The |input| should not be NULL. |
// Return a DecoderBuffer with the decrypted data if decryption succeeded. |
// Return NULL if decryption failed. |
- scoped_refptr<DecoderBuffer> Decrypt( |
- const scoped_refptr<DecoderBuffer>& input); |
+ virtual scoped_refptr<DecoderBuffer> Decrypt( |
+ const scoped_refptr<DecoderBuffer>& input) OVERRIDE; |
private: |
// KeyMap owns the crypto::SymmetricKey* and must delete them when they are |
// not needed any more. |
typedef base::hash_map<std::string, crypto::SymmetricKey*> KeyMap; |
KeyMap key_map_; |
- base::Lock lock_; |
DISALLOW_COPY_AND_ASSIGN(AesDecryptor); |
}; |