Commit 1f7499b3 authored by RJ Ascani's avatar RJ Ascani Committed by Commit Bot

[Fuchsia] Use isolated-cache for the cdm_data_directory

The ContextParams.cdm_data_directory is provided by the client for the
storage of CDM user data. This CL populates this field for CastRunner
with persistent-isolated-cache. This is temporary to prevent breakage.

Bug: 1051225, b/162078899
Change-Id: Idd291e318ccaf256194ae207018c77c8cfedd574
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2315001
Commit-Queue: RJ Ascani <rjascani@google.com>
Reviewed-by: default avatarWez <wez@chromium.org>
Cr-Commit-Position: refs/heads/master@{#799270}
parent fde99f57
......@@ -20,6 +20,7 @@ namespace base {
namespace fuchsia {
const char kPersistedDataDirectoryPath[] = "/data";
const char kPersistedCacheDirectoryPath[] = "/cache";
const char kServiceDirectoryPath[] = "/svc";
const char kPackageRootDirectoryPath[] = "/pkg";
......
......@@ -17,6 +17,9 @@ namespace fuchsia {
// PathService.
BASE_EXPORT extern const char kPersistedDataDirectoryPath[];
// Persisted cache directory, i.e. /cache .
BASE_EXPORT extern const char kPersistedCacheDirectoryPath[];
// Services directory, i.e. /svc .
BASE_EXPORT extern const char kServiceDirectoryPath[];
......
......@@ -2,6 +2,7 @@
"sandbox": {
"features": [
"deprecated-ambient-replace-as-executable",
"isolated-cache-storage",
"isolated-persistent-storage",
"isolated-temp",
"root-ssl-certificates",
......
......@@ -2,6 +2,7 @@
"sandbox": {
"features": [
"config-data",
"isolated-cache-storage",
"isolated-persistent-storage",
"isolated-temp",
"root-ssl-certificates",
......
......@@ -12,6 +12,7 @@
#include <utility>
#include "base/bind.h"
#include "base/files/file_path.h"
#include "base/fuchsia/file_utils.h"
#include "base/fuchsia/filtered_service_directory.h"
#include "base/fuchsia/fuchsia_logging.h"
......@@ -210,6 +211,12 @@ fuchsia::web::CreateContextParams CastRunner::GetCommonContextParams() {
fuchsia::web::ContextFeatureFlags::VULKAN;
}
// TODO(b/154204041) Migrate to using persistent data, and specifying an
// explicit quota for CDM storage.
params.set_cdm_data_directory(base::fuchsia::OpenDirectory(
base::FilePath(base::fuchsia::kPersistedCacheDirectoryPath)));
CHECK(params.cdm_data_directory());
const char kCastPlayreadyKeySystem[] = "com.chromecast.playready";
params.set_playready_key_system(kCastPlayreadyKeySystem);
......
{
"sandbox": {
"features": [
"config-data"
"config-data",
"isolated-cache-storage"
],
"services": [
"chromium.cast.ApplicationConfigManager",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment