Use upper case for Marlin uuid
This is required by Marlin although it is against uuid specification (ITU-T X.667). Issue #525. Change-Id: I1592d6abe24ae09bfbb2f80931a330ee6fd61eb5
This commit is contained in:
parent
c5fa32f0eb
commit
492f55a018
|
@ -10,7 +10,7 @@
|
||||||
<ContentProtection schemeIdUri="urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed">
|
<ContentProtection schemeIdUri="urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed">
|
||||||
<cenc:pssh>AAAAOHBzc2gAAAAA7e+LqXnWSs6jyCfc1R0h7QAAABgSEDEyMzQ1Njc4OTAxMjM0NTZI49yVmwY=</cenc:pssh>
|
<cenc:pssh>AAAAOHBzc2gAAAAA7e+LqXnWSs6jyCfc1R0h7QAAABgSEDEyMzQ1Njc4OTAxMjM0NTZI49yVmwY=</cenc:pssh>
|
||||||
</ContentProtection>
|
</ContentProtection>
|
||||||
<ContentProtection schemeIdUri="urn:uuid:5e629af5-38da-4063-8977-97ffbd9902d4">
|
<ContentProtection schemeIdUri="urn:uuid:5E629AF5-38DA-4063-8977-97FFBD9902D4">
|
||||||
<mas:MarlinContentIds>
|
<mas:MarlinContentIds>
|
||||||
<mas:MarlinContentId>urn:marlin:kid:31323334353637383930313233343536</mas:MarlinContentId>
|
<mas:MarlinContentId>urn:marlin:kid:31323334353637383930313233343536</mas:MarlinContentId>
|
||||||
</mas:MarlinContentIds>
|
</mas:MarlinContentIds>
|
||||||
|
@ -30,7 +30,7 @@
|
||||||
<ContentProtection schemeIdUri="urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed">
|
<ContentProtection schemeIdUri="urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed">
|
||||||
<cenc:pssh>AAAAOHBzc2gAAAAA7e+LqXnWSs6jyCfc1R0h7QAAABgSEDEyMzQ1Njc4OTAxMjM0NTZI49yVmwY=</cenc:pssh>
|
<cenc:pssh>AAAAOHBzc2gAAAAA7e+LqXnWSs6jyCfc1R0h7QAAABgSEDEyMzQ1Njc4OTAxMjM0NTZI49yVmwY=</cenc:pssh>
|
||||||
</ContentProtection>
|
</ContentProtection>
|
||||||
<ContentProtection schemeIdUri="urn:uuid:5e629af5-38da-4063-8977-97ffbd9902d4">
|
<ContentProtection schemeIdUri="urn:uuid:5E629AF5-38DA-4063-8977-97FFBD9902D4">
|
||||||
<mas:MarlinContentIds>
|
<mas:MarlinContentIds>
|
||||||
<mas:MarlinContentId>urn:marlin:kid:31323334353637383930313233343536</mas:MarlinContentId>
|
<mas:MarlinContentId>urn:marlin:kid:31323334353637383930313233343536</mas:MarlinContentId>
|
||||||
</mas:MarlinContentIds>
|
</mas:MarlinContentIds>
|
||||||
|
|
|
@ -385,7 +385,6 @@ void AddContentProtectionElementsHelperTemplated(
|
||||||
}
|
}
|
||||||
|
|
||||||
ContentProtectionElement drm_content_protection;
|
ContentProtectionElement drm_content_protection;
|
||||||
drm_content_protection.scheme_id_uri = "urn:uuid:" + entry.uuid();
|
|
||||||
|
|
||||||
if (entry.has_name_version())
|
if (entry.has_name_version())
|
||||||
drm_content_protection.value = entry.name_version();
|
drm_content_protection.value = entry.name_version();
|
||||||
|
@ -395,11 +394,17 @@ void AddContentProtectionElementsHelperTemplated(
|
||||||
"not support DASH signaling.";
|
"not support DASH signaling.";
|
||||||
continue;
|
continue;
|
||||||
} else if (entry.uuid() == kMarlinUUID) {
|
} else if (entry.uuid() == kMarlinUUID) {
|
||||||
|
// Marlin requires its uuid to be in upper case. See #525 for details.
|
||||||
|
drm_content_protection.scheme_id_uri =
|
||||||
|
"urn:uuid:" + base::ToUpperASCII(entry.uuid());
|
||||||
drm_content_protection.subelements.push_back(
|
drm_content_protection.subelements.push_back(
|
||||||
GenerateMarlinContentIds(protected_content.default_key_id()));
|
GenerateMarlinContentIds(protected_content.default_key_id()));
|
||||||
} else if (!entry.pssh().empty()) {
|
} else {
|
||||||
drm_content_protection.subelements.push_back(
|
drm_content_protection.scheme_id_uri = "urn:uuid:" + entry.uuid();
|
||||||
GenerateCencPsshElement(entry.pssh()));
|
if (!entry.pssh().empty()) {
|
||||||
|
drm_content_protection.subelements.push_back(
|
||||||
|
GenerateCencPsshElement(entry.pssh()));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!key_id_uuid_format.empty() && !is_mp4_container) {
|
if (!key_id_uuid_format.empty() && !is_mp4_container) {
|
||||||
|
|
|
@ -103,7 +103,7 @@ TEST_F(MpdUtilsTest, ContentProtectionMarlin) {
|
||||||
" schemeIdUri='urn:mpeg:dash:mp4protection:2011'"
|
" schemeIdUri='urn:mpeg:dash:mp4protection:2011'"
|
||||||
" cenc:default_KID='30313233-3435-3637-3839-3a3b3c3d3e3f'/>"
|
" cenc:default_KID='30313233-3435-3637-3839-3a3b3c3d3e3f'/>"
|
||||||
" <ContentProtection"
|
" <ContentProtection"
|
||||||
" schemeIdUri='urn:uuid:5e629af5-38da-4063-8977-97ffbd9902d4'>"
|
" schemeIdUri='urn:uuid:5E629AF5-38DA-4063-8977-97FFBD9902D4'>"
|
||||||
" <mas:MarlinContentIds>"
|
" <mas:MarlinContentIds>"
|
||||||
" <mas:MarlinContentId>"
|
" <mas:MarlinContentId>"
|
||||||
" urn:marlin:kid:303132333435363738393a3b3c3d3e3f"
|
" urn:marlin:kid:303132333435363738393a3b3c3d3e3f"
|
||||||
|
|
Loading…
Reference in New Issue