summaryrefslogtreecommitdiffstats
path: root/media/libmediaplayerservice/Crypto.h
diff options
context:
space:
mode:
authorJeff Tinker <jtinker@google.com>2015-04-10 04:10:59 -0700
committerJeff Tinker <jtinker@google.com>2015-04-10 04:10:59 -0700
commit1849570240443d1f75775c205fa658f7070849c6 (patch)
tree86ad28892b0e8b49c8666ad39e340234c610e709 /media/libmediaplayerservice/Crypto.h
parent2fb25c873e1a7f346bd8c7c072a85ca6a74b0e95 (diff)
downloadframeworks_av-1849570240443d1f75775c205fa658f7070849c6.zip
frameworks_av-1849570240443d1f75775c205fa658f7070849c6.tar.gz
frameworks_av-1849570240443d1f75775c205fa658f7070849c6.tar.bz2
Add a method to associate MediaDrm session with MediaCrypto
Previously, to associate a MediaDrm session with MediaCrypto, the MediaDrm sessionId was passed as initData to the MediaCrypto constructor. This is not ideal for two reasons: it's pretty obscure and you can't change the association without tearing down the MediaCodec/MediaCrypto and starting all over. Use cases like key rotation require being able to update the MediaDrm session post-construction. This CL addresses both of these issues. bug: 19570317 Change-Id: Ieb32d04d61742fc1dee2105dd904690d44c46c7b
Diffstat (limited to 'media/libmediaplayerservice/Crypto.h')
-rw-r--r--media/libmediaplayerservice/Crypto.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/media/libmediaplayerservice/Crypto.h b/media/libmediaplayerservice/Crypto.h
index d5f3c50..99ea95d 100644
--- a/media/libmediaplayerservice/Crypto.h
+++ b/media/libmediaplayerservice/Crypto.h
@@ -47,6 +47,8 @@ struct Crypto : public BnCrypto {
virtual void notifyResolution(uint32_t width, uint32_t height);
+ virtual status_t setMediaDrmSession(const Vector<uint8_t> &sessionId);
+
virtual ssize_t decrypt(
bool secure,
const uint8_t key[16],