mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Update to Chromium version 121.0.6167.0 (#1233107)
This commit is contained in:
@ -33,7 +33,7 @@ index 10085136f52ce..ec1be9babecc2 100644
|
||||
}
|
||||
|
||||
diff --git chrome/browser/policy/browser_dm_token_storage_mac.mm chrome/browser/policy/browser_dm_token_storage_mac.mm
|
||||
index 22fdb0efb78c7..39adc3f192ba1 100644
|
||||
index 5cb3cff75871c..51333ff7d85e2 100644
|
||||
--- chrome/browser/policy/browser_dm_token_storage_mac.mm
|
||||
+++ chrome/browser/policy/browser_dm_token_storage_mac.mm
|
||||
@@ -26,6 +26,7 @@
|
||||
@ -44,7 +44,7 @@ index 22fdb0efb78c7..39adc3f192ba1 100644
|
||||
#include "chrome/common/chrome_paths.h"
|
||||
#include "third_party/abseil-cpp/absl/types/optional.h"
|
||||
|
||||
@@ -47,11 +48,6 @@ const char kEnrollmentOptionsFilePath[] = FILE_PATH_LITERAL(
|
||||
@@ -47,11 +48,6 @@
|
||||
"/Library/Google/Chrome/CloudManagementEnrollmentOptions");
|
||||
const char kEnrollmentMandatoryOption[] = "Mandatory";
|
||||
|
||||
@ -56,12 +56,13 @@ index 22fdb0efb78c7..39adc3f192ba1 100644
|
||||
constexpr char kEnrollmentTokenMetricsName[] =
|
||||
"Enterprise.CloudManagementEnrollmentTokenLocation.Mac";
|
||||
|
||||
@@ -104,16 +100,22 @@ bool DeleteDMTokenFromAppDataDir(const std::string& client_id) {
|
||||
@@ -104,16 +100,23 @@ bool DeleteDMTokenFromAppDataDir(const std::string& client_id) {
|
||||
// Get the enrollment token from policy file: /Library/com.google.Chrome.plist.
|
||||
// Return true if policy is set, otherwise false.
|
||||
bool GetEnrollmentTokenFromPolicy(std::string* enrollment_token) {
|
||||
+ base::apple::ScopedCFTypeRef<CFStringRef> bundle_id(
|
||||
+ base::apple::ScopedCFTypeRef<CFStringRef> bundle_id_scoper(
|
||||
+ ChromeBrowserPolicyConnector::GetBundleId());
|
||||
+ CFStringRef bundle_id = bundle_id_scoper.get();
|
||||
+ if (!bundle_id) {
|
||||
+ return false;
|
||||
+ }
|
||||
@ -80,13 +81,14 @@ index 22fdb0efb78c7..39adc3f192ba1 100644
|
||||
+ !CFPreferencesAppValueIsForced(kEnrollmentTokenPolicyName, bundle_id)) {
|
||||
return false;
|
||||
}
|
||||
CFStringRef value_string = base::apple::CFCast<CFStringRef>(value);
|
||||
@@ -138,12 +140,18 @@ bool GetEnrollmentTokenFromFile(std::string* enrollment_token) {
|
||||
CFStringRef value_string = base::apple::CFCast<CFStringRef>(value.get());
|
||||
@@ -138,12 +141,19 @@ bool GetEnrollmentTokenFromFile(std::string* enrollment_token) {
|
||||
}
|
||||
|
||||
absl::optional<bool> IsEnrollmentMandatoryByPolicy() {
|
||||
+ base::apple::ScopedCFTypeRef<CFStringRef> bundle_id(
|
||||
+ base::apple::ScopedCFTypeRef<CFStringRef> bundle_id_scoper(
|
||||
+ ChromeBrowserPolicyConnector::GetBundleId());
|
||||
+ CFStringRef bundle_id = bundle_id_scoper.get();
|
||||
+ if (!bundle_id) {
|
||||
+ return absl::nullopt;
|
||||
+ }
|
||||
@ -103,7 +105,7 @@ index 22fdb0efb78c7..39adc3f192ba1 100644
|
||||
}
|
||||
|
||||
diff --git chrome/browser/policy/chrome_browser_policy_connector.cc chrome/browser/policy/chrome_browser_policy_connector.cc
|
||||
index 1d38696affc60..41a711f077c5c 100644
|
||||
index c012642290973..3f4d1be7f2092 100644
|
||||
--- chrome/browser/policy/chrome_browser_policy_connector.cc
|
||||
+++ chrome/browser/policy/chrome_browser_policy_connector.cc
|
||||
@@ -13,11 +13,14 @@
|
||||
@ -121,7 +123,7 @@ index 1d38696affc60..41a711f077c5c 100644
|
||||
#include "chrome/browser/browser_process.h"
|
||||
#include "chrome/browser/enterprise/browser_management/management_service_factory.h"
|
||||
#include "chrome/browser/policy/configuration_policy_handler_list_factory.h"
|
||||
@@ -78,6 +81,11 @@
|
||||
@@ -79,6 +82,11 @@
|
||||
namespace policy {
|
||||
namespace {
|
||||
bool g_command_line_enabled_for_testing = false;
|
||||
@ -133,7 +135,7 @@ index 1d38696affc60..41a711f077c5c 100644
|
||||
} // namespace
|
||||
|
||||
ChromeBrowserPolicyConnector::ChromeBrowserPolicyConnector()
|
||||
@@ -241,6 +249,73 @@ void ChromeBrowserPolicyConnector::EnableCommandLineSupportForTesting() {
|
||||
@@ -265,6 +273,73 @@ void ChromeBrowserPolicyConnector::EnableCommandLineSupportForTesting() {
|
||||
g_command_line_enabled_for_testing = true;
|
||||
}
|
||||
|
||||
@ -207,7 +209,7 @@ index 1d38696affc60..41a711f077c5c 100644
|
||||
base::flat_set<std::string>
|
||||
ChromeBrowserPolicyConnector::device_affiliation_ids() const {
|
||||
#if BUILDFLAG(IS_CHROMEOS_LACROS)
|
||||
@@ -314,22 +389,21 @@ ChromeBrowserPolicyConnector::CreatePolicyProviders() {
|
||||
@@ -336,23 +411,22 @@ ChromeBrowserPolicyConnector::CreatePolicyProviders() {
|
||||
std::unique_ptr<ConfigurationPolicyProvider>
|
||||
ChromeBrowserPolicyConnector::CreatePlatformProvider() {
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
@ -229,17 +231,18 @@ index 1d38696affc60..41a711f077c5c 100644
|
||||
- // policies.
|
||||
- CFStringRef bundle_id = CFSTR("com.google.Chrome");
|
||||
-#else
|
||||
- base::apple::ScopedCFTypeRef<CFStringRef> bundle_id(
|
||||
- base::SysUTF8ToCFStringRef(base::apple::BaseBundleID()));
|
||||
- base::apple::ScopedCFTypeRef<CFStringRef> bundle_id_scoper =
|
||||
- base::SysUTF8ToCFStringRef(base::apple::BaseBundleID());
|
||||
+ base::apple::ScopedCFTypeRef<CFStringRef> bundle_id_scoper(GetBundleId());
|
||||
CFStringRef bundle_id = bundle_id_scoper.get();
|
||||
-#endif
|
||||
+ base::apple::ScopedCFTypeRef<CFStringRef> bundle_id(GetBundleId());
|
||||
+ if (!bundle_id) {
|
||||
+ return nullptr;
|
||||
+ }
|
||||
auto loader = std::make_unique<PolicyLoaderMac>(
|
||||
base::ThreadPool::CreateSequencedTaskRunner(
|
||||
{base::MayBlock(), base::TaskPriority::BEST_EFFORT}),
|
||||
@@ -339,7 +413,7 @@ ChromeBrowserPolicyConnector::CreatePlatformProvider() {
|
||||
@@ -362,7 +436,7 @@ ChromeBrowserPolicyConnector::CreatePlatformProvider() {
|
||||
std::move(loader));
|
||||
#elif BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID)
|
||||
base::FilePath config_dir_path;
|
||||
@ -249,7 +252,7 @@ index 1d38696affc60..41a711f077c5c 100644
|
||||
// If the folder containing the policy files doesn't exist, there's no need
|
||||
// to have a provider for them. Note that in verified boot, the folder
|
||||
diff --git chrome/browser/policy/chrome_browser_policy_connector.h chrome/browser/policy/chrome_browser_policy_connector.h
|
||||
index f949565fe137d..d6401dfededff 100644
|
||||
index daa1a4cf0820d..c33db32822fbf 100644
|
||||
--- chrome/browser/policy/chrome_browser_policy_connector.h
|
||||
+++ chrome/browser/policy/chrome_browser_policy_connector.h
|
||||
@@ -28,6 +28,10 @@
|
||||
@ -290,7 +293,7 @@ index f949565fe137d..d6401dfededff 100644
|
||||
|
||||
#if BUILDFLAG(IS_CHROMEOS_LACROS)
|
||||
diff --git chrome/browser/policy/policy_path_parser_mac.mm chrome/browser/policy/policy_path_parser_mac.mm
|
||||
index 44a46c9c37788..873a6469c7ab5 100644
|
||||
index 1a2e78c3472ec..5d1bd95a15113 100644
|
||||
--- chrome/browser/policy/policy_path_parser_mac.mm
|
||||
+++ chrome/browser/policy/policy_path_parser_mac.mm
|
||||
@@ -16,6 +16,7 @@
|
||||
@ -301,7 +304,7 @@ index 44a46c9c37788..873a6469c7ab5 100644
|
||||
#include "components/policy/policy_constants.h"
|
||||
|
||||
namespace policy::path_parser {
|
||||
@@ -97,15 +98,11 @@ base::FilePath::StringType ExpandPathVariables(
|
||||
@@ -97,16 +98,12 @@
|
||||
void CheckUserDataDirPolicy(base::FilePath* user_data_dir) {
|
||||
// Since the configuration management infrastructure is not initialized when
|
||||
// this code runs, read the policy preference directly.
|
||||
@ -311,16 +314,17 @@ index 44a46c9c37788..873a6469c7ab5 100644
|
||||
- // policies.
|
||||
- CFStringRef bundle_id = CFSTR("com.google.Chrome");
|
||||
-#else
|
||||
base::apple::ScopedCFTypeRef<CFStringRef> bundle_id(
|
||||
- base::SysUTF8ToCFStringRef(base::apple::BaseBundleID()));
|
||||
base::apple::ScopedCFTypeRef<CFStringRef> bundle_id_scoper =
|
||||
- base::SysUTF8ToCFStringRef(base::apple::BaseBundleID());
|
||||
+ policy::ChromeBrowserPolicyConnector::GetBundleId();
|
||||
CFStringRef bundle_id = bundle_id_scoper.get();
|
||||
-#endif
|
||||
+ policy::ChromeBrowserPolicyConnector::GetBundleId());
|
||||
+ if (!bundle_id) {
|
||||
+ return;
|
||||
+ }
|
||||
|
||||
base::apple::ScopedCFTypeRef<CFStringRef> key(
|
||||
base::SysUTF8ToCFStringRef(policy::key::kUserDataDir));
|
||||
base::apple::ScopedCFTypeRef<CFStringRef> key =
|
||||
base::SysUTF8ToCFStringRef(policy::key::kUserDataDir);
|
||||
diff --git chrome/browser/policy/policy_path_parser_win.cc chrome/browser/policy/policy_path_parser_win.cc
|
||||
index 8dbf958c189dd..6eaccc6688eca 100644
|
||||
--- chrome/browser/policy/policy_path_parser_win.cc
|
||||
@ -351,7 +355,7 @@ index 8dbf958c189dd..6eaccc6688eca 100644
|
||||
*dir = base::FilePath(policy::path_parser::ExpandPathVariables(value));
|
||||
return true;
|
||||
diff --git chrome/common/chrome_paths.cc chrome/common/chrome_paths.cc
|
||||
index 4733d00519f56..be7ce3c4ec38b 100644
|
||||
index 89678edacdadf..821c4448a8188 100644
|
||||
--- chrome/common/chrome_paths.cc
|
||||
+++ chrome/common/chrome_paths.cc
|
||||
@@ -523,7 +523,8 @@ bool PathProvider(int key, base::FilePath* result) {
|
||||
@ -365,7 +369,7 @@ index 4733d00519f56..be7ce3c4ec38b 100644
|
||||
cur = base::FilePath(policy::kPolicyPath);
|
||||
break;
|
||||
diff --git chrome/common/chrome_paths.h chrome/common/chrome_paths.h
|
||||
index ab0301b8eb26d..3ed179ccf84bf 100644
|
||||
index 03387b9680834..76191ba98e80b 100644
|
||||
--- chrome/common/chrome_paths.h
|
||||
+++ chrome/common/chrome_paths.h
|
||||
@@ -8,6 +8,7 @@
|
||||
@ -373,10 +377,10 @@ index ab0301b8eb26d..3ed179ccf84bf 100644
|
||||
#include "build/build_config.h"
|
||||
#include "build/chromeos_buildflags.h"
|
||||
+#include "cef/libcef/features/features.h"
|
||||
#include "extensions/buildflags/buildflags.h"
|
||||
#include "third_party/widevine/cdm/buildflags.h"
|
||||
|
||||
namespace base {
|
||||
@@ -46,7 +47,7 @@ enum {
|
||||
@@ -47,7 +48,7 @@ enum {
|
||||
DIR_INTERNAL_PLUGINS, // Directory where internal plugins reside.
|
||||
DIR_COMPONENTS, // Directory where built-in implementations of
|
||||
// component-updated libraries or data reside.
|
||||
@ -386,10 +390,10 @@ index ab0301b8eb26d..3ed179ccf84bf 100644
|
||||
// policy files that allow sys-admins
|
||||
// to set policies for chrome. This directory
|
||||
diff --git components/policy/tools/generate_policy_source.py components/policy/tools/generate_policy_source.py
|
||||
index e9d31053cb2ea..793ceac3c7772 100755
|
||||
index a17b30c37e07a..adcdf25e38ed1 100755
|
||||
--- components/policy/tools/generate_policy_source.py
|
||||
+++ components/policy/tools/generate_policy_source.py
|
||||
@@ -500,6 +500,7 @@ def _WritePolicyConstantHeader(all_policies, policy_atomic_groups,
|
||||
@@ -486,6 +486,7 @@ def _WritePolicyConstantHeader(all_policies, policy_atomic_groups,
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
|
||||
@ -397,7 +401,7 @@ index e9d31053cb2ea..793ceac3c7772 100755
|
||||
#include "components/policy/core/common/policy_details.h"
|
||||
#include "components/policy/core/common/policy_map.h"
|
||||
|
||||
@@ -522,9 +523,11 @@ struct SchemaData;
|
||||
@@ -508,9 +509,11 @@ struct SchemaData;
|
||||
''')
|
||||
|
||||
if target_platform == 'win':
|
||||
@ -411,7 +415,7 @@ index e9d31053cb2ea..793ceac3c7772 100755
|
||||
|
||||
f.write('''#if BUILDFLAG(IS_CHROMEOS)
|
||||
// Sets default profile policies values for enterprise users.
|
||||
@@ -1167,12 +1170,14 @@ namespace policy {
|
||||
@@ -1153,12 +1156,14 @@ namespace policy {
|
||||
f.write('} // namespace\n\n')
|
||||
|
||||
if target_platform == 'win':
|
||||
|
Reference in New Issue
Block a user