diff --git a/library/dash/src/main/java/com/google/android/exoplayer2/source/dash/manifest/DashManifestParser.java b/library/dash/src/main/java/com/google/android/exoplayer2/source/dash/manifest/DashManifestParser.java index 0a4274e674f..a443ca861fd 100644 --- a/library/dash/src/main/java/com/google/android/exoplayer2/source/dash/manifest/DashManifestParser.java +++ b/library/dash/src/main/java/com/google/android/exoplayer2/source/dash/manifest/DashManifestParser.java @@ -355,6 +355,7 @@ protected int getContentType(Format format) { protected Pair parseContentProtection(XmlPullParser xpp) throws XmlPullParserException, IOException { String schemeType = null; + String licenseServerUrl = null; byte[] data = null; UUID uuid = null; boolean requiresSecureDecoder = false; @@ -389,7 +390,9 @@ protected Pair parseContentProtection(XmlPullParser xpp) do { xpp.next(); - if (XmlPullParserUtil.isStartTag(xpp, "widevine:license")) { + if (XmlPullParserUtil.isStartTag(xpp, "ms:laurl")) { + licenseServerUrl = xpp.getAttributeValue(null, "licenseUrl"); + } else if (XmlPullParserUtil.isStartTag(xpp, "widevine:license")) { String robustnessLevel = xpp.getAttributeValue(null, "robustness_level"); requiresSecureDecoder = robustnessLevel != null && robustnessLevel.startsWith("HW"); } else if (data == null) { @@ -409,8 +412,11 @@ protected Pair parseContentProtection(XmlPullParser xpp) } } } while (!XmlPullParserUtil.isEndTag(xpp, "ContentProtection")); - SchemeData schemeData = uuid != null - ? new SchemeData(uuid, MimeTypes.VIDEO_MP4, data, requiresSecureDecoder) : null; + SchemeData schemeData = + uuid != null + ? new SchemeData( + uuid, licenseServerUrl, MimeTypes.VIDEO_MP4, data, requiresSecureDecoder) + : null; return Pair.create(schemeType, schemeData); }