Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
SDK
/
exoplayer
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
7588c26b
authored
Aug 18, 2020
by
olly
Committed by
Oliver Woodman
Aug 21, 2020
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Remove support for cbc1 and cens encryptions schemes
PiperOrigin-RevId: 327199833
parent
54c92080
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
37 deletions
RELEASENOTES.md
demos/main/src/main/assets/media.exolist.json
library/core/src/main/java/com/google/android/exoplayer2/drm/DefaultDrmSessionManager.java
playbacktests/src/androidTest/java/com/google/android/exoplayer2/playbacktests/gts/CommonEncryptionDrmTest.java
playbacktests/src/androidTest/java/com/google/android/exoplayer2/playbacktests/gts/DashTestData.java
RELEASENOTES.md
View file @
7588c26b
...
@@ -269,6 +269,10 @@
...
@@ -269,6 +269,10 @@
(
[
#7011
](
https://github.com/google/ExoPlayer/issues/7011
)
,
(
[
#7011
](
https://github.com/google/ExoPlayer/issues/7011
)
,
[
#6725
](
https://github.com/google/ExoPlayer/issues/6725
)
,
[
#6725
](
https://github.com/google/ExoPlayer/issues/6725
)
,
[
#7066
](
https://github.com/google/ExoPlayer/issues/7066
)
).
[
#7066
](
https://github.com/google/ExoPlayer/issues/7066
)
).
*
Remove support for
`cbc1`
and
`cens`
encrytion schemes. Support for
these schemes was removed from the Android platform from API level 30,
and the range of API levels for which they are supported is too small to
be useful.
*
Remove generic types from DRM components.
*
Remove generic types from DRM components.
*
Test utils: Add
`TestExoPlayer`
, a utility class with APIs to create
*
Test utils: Add
`TestExoPlayer`
, a utility class with APIs to create
`SimpleExoPlayer`
instances with fake components for testing.
`SimpleExoPlayer`
instances with fake components for testing.
...
...
demos/main/src/main/assets/media.exolist.json
View file @
7588c26b
...
@@ -125,18 +125,6 @@
...
@@ -125,18 +125,6 @@
"drm_license_uri"
:
"https://proxy.uat.widevine.com/proxy?provider=widevine_test"
"drm_license_uri"
:
"https://proxy.uat.widevine.com/proxy?provider=widevine_test"
},
},
{
{
"name"
:
"Secure (cbc1)"
,
"uri"
:
"https://storage.googleapis.com/wvmedia/cbc1/h264/tears/tears_aes_cbc1.mpd"
,
"drm_scheme"
:
"widevine"
,
"drm_license_uri"
:
"https://proxy.uat.widevine.com/proxy?provider=widevine_test"
},
{
"name"
:
"Secure UHD (cbc1)"
,
"uri"
:
"https://storage.googleapis.com/wvmedia/cbc1/h264/tears/tears_aes_cbc1_uhd.mpd"
,
"drm_scheme"
:
"widevine"
,
"drm_license_uri"
:
"https://proxy.uat.widevine.com/proxy?provider=widevine_test"
},
{
"name"
:
"Secure (cbcs)"
,
"name"
:
"Secure (cbcs)"
,
"uri"
:
"https://storage.googleapis.com/wvmedia/cbcs/h264/tears/tears_aes_cbcs.mpd"
,
"uri"
:
"https://storage.googleapis.com/wvmedia/cbcs/h264/tears/tears_aes_cbcs.mpd"
,
"drm_scheme"
:
"widevine"
,
"drm_scheme"
:
"widevine"
,
...
...
library/core/src/main/java/com/google/android/exoplayer2/drm/DefaultDrmSessionManager.java
View file @
7588c26b
...
@@ -585,12 +585,16 @@ public class DefaultDrmSessionManager implements DrmSessionManager {
...
@@ -585,12 +585,16 @@ public class DefaultDrmSessionManager implements DrmSessionManager {
if
(
schemeType
==
null
||
C
.
CENC_TYPE_cenc
.
equals
(
schemeType
))
{
if
(
schemeType
==
null
||
C
.
CENC_TYPE_cenc
.
equals
(
schemeType
))
{
// If there is no scheme information, assume patternless AES-CTR.
// If there is no scheme information, assume patternless AES-CTR.
return
true
;
return
true
;
}
else
if
(
C
.
CENC_TYPE_cbc1
.
equals
(
schemeType
)
}
else
if
(
C
.
CENC_TYPE_cbcs
.
equals
(
schemeType
))
{
||
C
.
CENC_TYPE_cbcs
.
equals
(
schemeType
)
// Support for cbcs (AES-CBC with pattern encryption) was added in API 24. However, the
||
C
.
CENC_TYPE_cens
.
equals
(
schemeType
))
{
// API support for AES-CBC and pattern encryption was added in API 24. However, the
// implementation was not stable until API 25.
// implementation was not stable until API 25.
return
Util
.
SDK_INT
>=
25
;
return
Util
.
SDK_INT
>=
25
;
}
else
if
(
C
.
CENC_TYPE_cbc1
.
equals
(
schemeType
)
||
C
.
CENC_TYPE_cens
.
equals
(
schemeType
))
{
// Support for cbc1 (AES-CTR with pattern encryption) and cens (AES-CBC without pattern
// encryption) was also added in API 24 and made stable from API 25, however support was
// removed from API 30. Since the range of API levels for which these modes are usable is too
// small to be useful, we don't indicate support on any API level.
return
false
;
}
}
// Unknown schemes, assume one of them is supported.
// Unknown schemes, assume one of them is supported.
return
true
;
return
true
;
...
...
playbacktests/src/androidTest/java/com/google/android/exoplayer2/playbacktests/gts/CommonEncryptionDrmTest.java
View file @
7588c26b
...
@@ -75,20 +75,6 @@ public final class CommonEncryptionDrmTest {
...
@@ -75,20 +75,6 @@ public final class CommonEncryptionDrmTest {
}
}
@Test
@Test
public
void
cbc1SchemeTypeV25
()
{
if
(
Util
.
SDK_INT
<
25
)
{
// cbc1 support was added in API 24, but it is stable from API 25 onwards.
// See [internal: b/65634809].
// Pass.
return
;
}
testRunner
.
setStreamName
(
"test_widevine_h264_scheme_cbc1"
)
.
setManifestUrl
(
DashTestData
.
WIDEVINE_SCHEME_CBC1
)
.
run
();
}
@Test
public
void
cbcsSchemeTypeV25
()
{
public
void
cbcsSchemeTypeV25
()
{
if
(
Util
.
SDK_INT
<
25
)
{
if
(
Util
.
SDK_INT
<
25
)
{
// cbcs support was added in API 24, but it is stable from API 25 onwards.
// cbcs support was added in API 24, but it is stable from API 25 onwards.
...
@@ -101,9 +87,4 @@ public final class CommonEncryptionDrmTest {
...
@@ -101,9 +87,4 @@ public final class CommonEncryptionDrmTest {
.
setManifestUrl
(
DashTestData
.
WIDEVINE_SCHEME_CBCS
)
.
setManifestUrl
(
DashTestData
.
WIDEVINE_SCHEME_CBCS
)
.
run
();
.
run
();
}
}
@Test
public
void
censSchemeTypeV25
()
{
// TODO: Implement once content is available. Track [internal: b/31219813].
}
}
}
playbacktests/src/androidTest/java/com/google/android/exoplayer2/playbacktests/gts/DashTestData.java
View file @
7588c26b
...
@@ -45,8 +45,6 @@ import com.google.android.exoplayer2.util.Util;
...
@@ -45,8 +45,6 @@ import com.google.android.exoplayer2.util.Util;
// Widevine encrypted content manifests using different common encryption schemes.
// Widevine encrypted content manifests using different common encryption schemes.
public
static
final
String
WIDEVINE_SCHEME_CENC
=
BASE_URL_COMMON_ENCRYPTION
+
"tears-cenc.mpd"
;
public
static
final
String
WIDEVINE_SCHEME_CENC
=
BASE_URL_COMMON_ENCRYPTION
+
"tears-cenc.mpd"
;
public
static
final
String
WIDEVINE_SCHEME_CBC1
=
BASE_URL_COMMON_ENCRYPTION
+
"tears-aes-cbc1.mpd"
;
public
static
final
String
WIDEVINE_SCHEME_CBCS
=
public
static
final
String
WIDEVINE_SCHEME_CBCS
=
BASE_URL_COMMON_ENCRYPTION
+
"tears-aes-cbcs.mpd"
;
BASE_URL_COMMON_ENCRYPTION
+
"tears-aes-cbcs.mpd"
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment