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

Side by Side Diff: sandbox/win/src/sandbox_policy_base.h

Issue 1849323003: Convert //sandbox to use std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixup nonsfi_sandbox_unittest.cc Created 4 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
« no previous file with comments | « sandbox/win/src/restricted_token.cc ('k') | sandbox/win/src/service_resolver_32.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef SANDBOX_WIN_SRC_SANDBOX_POLICY_BASE_H_ 5 #ifndef SANDBOX_WIN_SRC_SANDBOX_POLICY_BASE_H_
6 #define SANDBOX_WIN_SRC_SANDBOX_POLICY_BASE_H_ 6 #define SANDBOX_WIN_SRC_SANDBOX_POLICY_BASE_H_
7 7
8 #include <windows.h> 8 #include <windows.h>
9 #include <stddef.h> 9 #include <stddef.h>
10 #include <stdint.h> 10 #include <stdint.h>
11 11
12 #include <list> 12 #include <list>
13 #include <memory>
13 #include <vector> 14 #include <vector>
14 15
15 #include "base/compiler_specific.h" 16 #include "base/compiler_specific.h"
16 #include "base/macros.h" 17 #include "base/macros.h"
17 #include "base/memory/scoped_ptr.h"
18 #include "base/process/launch.h" 18 #include "base/process/launch.h"
19 #include "base/strings/string16.h" 19 #include "base/strings/string16.h"
20 #include "base/win/scoped_handle.h" 20 #include "base/win/scoped_handle.h"
21 #include "sandbox/win/src/crosscall_server.h" 21 #include "sandbox/win/src/crosscall_server.h"
22 #include "sandbox/win/src/handle_closer.h" 22 #include "sandbox/win/src/handle_closer.h"
23 #include "sandbox/win/src/ipc_tags.h" 23 #include "sandbox/win/src/ipc_tags.h"
24 #include "sandbox/win/src/policy_engine_opcodes.h" 24 #include "sandbox/win/src/policy_engine_opcodes.h"
25 #include "sandbox/win/src/policy_engine_params.h" 25 #include "sandbox/win/src/policy_engine_params.h"
26 #include "sandbox/win/src/sandbox_policy.h" 26 #include "sandbox/win/src/sandbox_policy.h"
27 #include "sandbox/win/src/win_utils.h" 27 #include "sandbox/win/src/win_utils.h"
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 LowLevelPolicy* policy_maker_; 148 LowLevelPolicy* policy_maker_;
149 // Memory structure that stores the low level policy. 149 // Memory structure that stores the low level policy.
150 PolicyGlobal* policy_; 150 PolicyGlobal* policy_;
151 // The list of dlls to unload in the target process. 151 // The list of dlls to unload in the target process.
152 std::vector<base::string16> blacklisted_dlls_; 152 std::vector<base::string16> blacklisted_dlls_;
153 // This is a map of handle-types to names that we need to close in the 153 // This is a map of handle-types to names that we need to close in the
154 // target process. A null set means we need to close all handles of the 154 // target process. A null set means we need to close all handles of the
155 // given type. 155 // given type.
156 HandleCloser handle_closer_; 156 HandleCloser handle_closer_;
157 std::vector<base::string16> capabilities_; 157 std::vector<base::string16> capabilities_;
158 scoped_ptr<AppContainerAttributes> appcontainer_list_; 158 std::unique_ptr<AppContainerAttributes> appcontainer_list_;
159 PSID lowbox_sid_; 159 PSID lowbox_sid_;
160 base::win::ScopedHandle lowbox_directory_; 160 base::win::ScopedHandle lowbox_directory_;
161 scoped_ptr<Dispatcher> dispatcher_; 161 std::unique_ptr<Dispatcher> dispatcher_;
162 bool lockdown_default_dacl_; 162 bool lockdown_default_dacl_;
163 163
164 static HDESK alternate_desktop_handle_; 164 static HDESK alternate_desktop_handle_;
165 static HWINSTA alternate_winstation_handle_; 165 static HWINSTA alternate_winstation_handle_;
166 static IntegrityLevel alternate_desktop_integrity_level_label_; 166 static IntegrityLevel alternate_desktop_integrity_level_label_;
167 167
168 // Contains the list of handles being shared with the target process. 168 // Contains the list of handles being shared with the target process.
169 // This list contains handles other than the stderr/stdout handles which are 169 // This list contains handles other than the stderr/stdout handles which are
170 // shared with the target at times. 170 // shared with the target at times.
171 base::HandlesToInheritVector handles_to_share_; 171 base::HandlesToInheritVector handles_to_share_;
172 172
173 DISALLOW_COPY_AND_ASSIGN(PolicyBase); 173 DISALLOW_COPY_AND_ASSIGN(PolicyBase);
174 }; 174 };
175 175
176 } // namespace sandbox 176 } // namespace sandbox
177 177
178 #endif // SANDBOX_WIN_SRC_SANDBOX_POLICY_BASE_H_ 178 #endif // SANDBOX_WIN_SRC_SANDBOX_POLICY_BASE_H_
OLDNEW
« no previous file with comments | « sandbox/win/src/restricted_token.cc ('k') | sandbox/win/src/service_resolver_32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698