Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(21)

Side by Side Diff: chrome/browser/extensions/permissions_updater_delegate_chromeos.h

Issue 2794803003: PS - Remove Clipboard Read permission from extensions in Public Sessions (except for whitelisted on… (Closed)
Patch Set: Using a platform delegate Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_EXTENSIONS_PERMISSIONS_UPDATER_DELEGATE_CHROMEOS_H_
6 #define CHROME_BROWSER_EXTENSIONS_PERMISSIONS_UPDATER_DELEGATE_CHROMEOS_H_
7
8 #include "base/macros.h"
9 #include "chrome/browser/extensions/permissions_updater.h"
10 #include "content/public/browser/browser_context.h"
Devlin 2017/04/05 14:35:20 unneeded
Ivan Šandrk 2017/04/07 14:39:40 Done.
11 #include "extensions/common/extension.h"
Devlin 2017/04/05 14:35:20 prefer forward declaration
Ivan Šandrk 2017/04/07 14:39:40 Done.
12
13 namespace extensions {
14
15 // In Public Sessions, apps and extensions are force-installed by admin policy
16 // so the user does not get a chance to review the permissions for these apps.
17 // This is not acceptable from a security standpoint, so we remove ClipboardRead
18 // permission from them (except for whitelisted ones - eg. remote desktop
19 // clients). This forceful removal of permission is safe since the clipboard
20 // pasting code checks for this permission before doing the paste (the end
21 // result is just an empty paste).
22 class PermissionsUpdaterDelegateChromeOS : public PermissionsUpdater::Delegate {
Devlin 2017/04/05 14:35:20 as hinted in permissions updater, it'd be great fo
Ivan Šandrk 2017/04/07 14:39:40 Done.
23 public:
24 PermissionsUpdaterDelegateChromeOS();
25 ~PermissionsUpdaterDelegateChromeOS() override;
26
27 // PermissionsUpdater::Delegate
28 void InitializePermissions(PermissionsUpdater* permissions_updater,
29 const Extension* extension) override;
30
31 private:
32 DISALLOW_COPY_AND_ASSIGN(PermissionsUpdaterDelegateChromeOS);
33 };
34
35 } // namespace extensions
36
37 #endif // CHROME_BROWSER_EXTENSIONS_PERMISSIONS_UPDATER_DELEGATE_CHROMEOS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698