#include "content/browser/media/session/media_metadata_sanitizer.h"
#include <algorithm>
#include <string>
#include "base/time/time.h"
#include "services/media_session/public/cpp/media_image.h"
#include "services/media_session/public/cpp/media_metadata.h"
namespace content {
namespace {
const size_t kMaxIPCStringLength = …;
const size_t kMaxMediaImageTypeLength = …;
const size_t kMaxNumberOfMediaImages = …;
const size_t kMaxNumberOfChapters = …;
const size_t kMaxNumberOfMediaImageSizes = …;
bool CheckMediaImageSrcSanity(const GURL& src) { … }
bool CheckMediaImageSanity(const media_session::MediaImage& image) { … }
bool CheckChapterInformationSanity(
const media_session::ChapterInformation& chapter) { … }
}
bool MediaMetadataSanitizer::CheckSanity(
const blink::mojom::SpecMediaMetadataPtr& metadata) { … }
}