summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2019-12-06 22:21:17 +0100
committerCarl Hetherington <cth@carlh.net>2019-12-22 01:21:00 +0100
commit07b03fc977f813258c056e7247c9d3a13b133b54 (patch)
treefa80f34f55cd9b8d472cc8130115f5df6e59dede /src
parent2f874428086c0bd47e6efa31970be9f442e087f4 (diff)
Verify Id in ContentVersion.
Diffstat (limited to 'src')
-rw-r--r--src/verify.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/verify.cc b/src/verify.cc
index 032a3f39..6611b7b3 100644
--- a/src/verify.cc
+++ b/src/verify.cc
@@ -170,6 +170,9 @@ dcp::verify (vector<boost::filesystem::path> directories, function<void (string,
if (!good_date(cpl_doc.string_child("IssueDate"))) {
notes.push_back (VerificationNote(VerificationNote::VERIFY_ERROR, VerificationNote::Code::BAD_DATE, string("CPL <IssueDate> is malformed")));
}
+ if (cpl->standard() && cpl->standard().get() == SMPTE && !good_urn_uuid(cpl_doc.node_child("ContentVersion")->string_child("Id"))) {
+ notes.push_back (VerificationNote(VerificationNote::VERIFY_ERROR, VerificationNote::Code::BAD_URN_UUID, string("<ContentVersion> <Id> is malformed.")));
+ }
/* Check that the CPL's hash corresponds to the PKL */
BOOST_FOREACH (shared_ptr<PKL> i, dcp->pkls()) {