| OLD | NEW |
| (Empty) |
| 1 # Copyright (c) 2012 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 { | |
| 6 'target_defaults': { | |
| 7 'variables': { | |
| 8 'sandbox_windows_target': 0, | |
| 9 'target_arch%': 'ia32', | |
| 10 }, | |
| 11 'target_conditions': [ | |
| 12 ['sandbox_windows_target==1', { | |
| 13 # Files that are shared between the 32-bit and the 64-bit versions | |
| 14 # of the Windows sandbox library. | |
| 15 'sources': [ | |
| 16 'src/acl.cc', | |
| 17 'src/acl.h', | |
| 18 'src/broker_services.cc', | |
| 19 'src/broker_services.h', | |
| 20 'src/crosscall_client.h', | |
| 21 'src/crosscall_params.h', | |
| 22 'src/crosscall_server.cc', | |
| 23 'src/crosscall_server.h', | |
| 24 'src/eat_resolver.cc', | |
| 25 'src/eat_resolver.h', | |
| 26 'src/filesystem_dispatcher.cc', | |
| 27 'src/filesystem_dispatcher.h', | |
| 28 'src/filesystem_interception.cc', | |
| 29 'src/filesystem_interception.h', | |
| 30 'src/filesystem_policy.cc', | |
| 31 'src/filesystem_policy.h', | |
| 32 'src/handle_closer.cc', | |
| 33 'src/handle_closer.h', | |
| 34 'src/handle_closer_agent.cc', | |
| 35 'src/handle_closer_agent.h', | |
| 36 'src/interception.cc', | |
| 37 'src/interception.h', | |
| 38 'src/interception_agent.cc', | |
| 39 'src/interception_agent.h', | |
| 40 'src/interception_internal.h', | |
| 41 'src/interceptors.h', | |
| 42 'src/internal_types.h', | |
| 43 'src/ipc_tags.h', | |
| 44 'src/job.cc', | |
| 45 'src/job.h', | |
| 46 'src/named_pipe_dispatcher.cc', | |
| 47 'src/named_pipe_dispatcher.h', | |
| 48 'src/named_pipe_interception.cc', | |
| 49 'src/named_pipe_interception.h', | |
| 50 'src/named_pipe_policy.cc', | |
| 51 'src/named_pipe_policy.h', | |
| 52 'src/nt_internals.h', | |
| 53 'src/policy_broker.cc', | |
| 54 'src/policy_broker.h', | |
| 55 'src/policy_engine_opcodes.cc', | |
| 56 'src/policy_engine_opcodes.h', | |
| 57 'src/policy_engine_params.h', | |
| 58 'src/policy_engine_processor.cc', | |
| 59 'src/policy_engine_processor.h', | |
| 60 'src/policy_low_level.cc', | |
| 61 'src/policy_low_level.h', | |
| 62 'src/policy_params.h', | |
| 63 'src/policy_target.cc', | |
| 64 'src/policy_target.h', | |
| 65 'src/process_mitigations.cc', | |
| 66 'src/process_mitigations.h', | |
| 67 'src/process_mitigations_win32k_dispatcher.cc', | |
| 68 'src/process_mitigations_win32k_dispatcher.h', | |
| 69 'src/process_mitigations_win32k_interception.cc', | |
| 70 'src/process_mitigations_win32k_interception.h', | |
| 71 'src/process_mitigations_win32k_policy.cc', | |
| 72 'src/process_mitigations_win32k_policy.h', | |
| 73 'src/process_thread_dispatcher.cc', | |
| 74 'src/process_thread_dispatcher.h', | |
| 75 'src/process_thread_interception.cc', | |
| 76 'src/process_thread_interception.h', | |
| 77 'src/process_thread_policy.cc', | |
| 78 'src/process_thread_policy.h', | |
| 79 'src/registry_dispatcher.cc', | |
| 80 'src/registry_dispatcher.h', | |
| 81 'src/registry_interception.cc', | |
| 82 'src/registry_interception.h', | |
| 83 'src/registry_policy.cc', | |
| 84 'src/registry_policy.h', | |
| 85 'src/resolver.cc', | |
| 86 'src/resolver.h', | |
| 87 'src/restricted_token_utils.cc', | |
| 88 'src/restricted_token_utils.h', | |
| 89 'src/restricted_token.cc', | |
| 90 'src/restricted_token.h', | |
| 91 'src/sandbox_factory.h', | |
| 92 'src/sandbox_globals.cc', | |
| 93 'src/sandbox_nt_types.h', | |
| 94 'src/sandbox_nt_util.cc', | |
| 95 'src/sandbox_nt_util.h', | |
| 96 'src/sandbox_policy_base.cc', | |
| 97 'src/sandbox_policy_base.h', | |
| 98 'src/sandbox_policy.h', | |
| 99 'src/sandbox_rand.cc', | |
| 100 'src/sandbox_rand.h', | |
| 101 'src/sandbox_types.h', | |
| 102 'src/sandbox_utils.cc', | |
| 103 'src/sandbox_utils.h', | |
| 104 'src/sandbox.cc', | |
| 105 'src/sandbox.h', | |
| 106 'src/security_level.h', | |
| 107 'src/service_resolver.cc', | |
| 108 'src/service_resolver.h', | |
| 109 'src/sharedmem_ipc_client.cc', | |
| 110 'src/sharedmem_ipc_client.h', | |
| 111 'src/sharedmem_ipc_server.cc', | |
| 112 'src/sharedmem_ipc_server.h', | |
| 113 'src/sid.cc', | |
| 114 'src/sid.h', | |
| 115 'src/sync_dispatcher.cc', | |
| 116 'src/sync_dispatcher.h', | |
| 117 'src/sync_interception.cc', | |
| 118 'src/sync_interception.h', | |
| 119 'src/sync_policy.cc', | |
| 120 'src/sync_policy.h', | |
| 121 'src/target_interceptions.cc', | |
| 122 'src/target_interceptions.h', | |
| 123 'src/target_process.cc', | |
| 124 'src/target_process.h', | |
| 125 'src/target_services.cc', | |
| 126 'src/target_services.h', | |
| 127 'src/top_level_dispatcher.cc', | |
| 128 'src/top_level_dispatcher.h', | |
| 129 'src/win_utils.cc', | |
| 130 'src/win_utils.h', | |
| 131 'src/win2k_threadpool.cc', | |
| 132 'src/win2k_threadpool.h', | |
| 133 'src/window.cc', | |
| 134 'src/window.h', | |
| 135 ], | |
| 136 'target_conditions': [ | |
| 137 ['target_arch=="x64"', { | |
| 138 'sources': [ | |
| 139 'src/interceptors_64.cc', | |
| 140 'src/interceptors_64.h', | |
| 141 'src/resolver_64.cc', | |
| 142 'src/service_resolver_64.cc', | |
| 143 ], | |
| 144 }], | |
| 145 ['target_arch=="ia32"', { | |
| 146 'sources': [ | |
| 147 'src/resolver_32.cc', | |
| 148 'src/service_resolver_32.cc', | |
| 149 'src/sidestep_resolver.cc', | |
| 150 'src/sidestep_resolver.h', | |
| 151 'src/sidestep\ia32_modrm_map.cpp', | |
| 152 'src/sidestep\ia32_opcode_map.cpp', | |
| 153 'src/sidestep\mini_disassembler_types.h', | |
| 154 'src/sidestep\mini_disassembler.cpp', | |
| 155 'src/sidestep\mini_disassembler.h', | |
| 156 'src/sidestep\preamble_patcher_with_stub.cpp', | |
| 157 'src/sidestep\preamble_patcher.h', | |
| 158 ], | |
| 159 }], | |
| 160 ], | |
| 161 }], | |
| 162 ], | |
| 163 }, | |
| 164 'targets': [ | |
| 165 { | |
| 166 'target_name': 'sandbox', | |
| 167 'type': 'static_library', | |
| 168 'variables': { | |
| 169 'sandbox_windows_target': 1, | |
| 170 }, | |
| 171 'dependencies': [ | |
| 172 '../base/base.gyp:base', | |
| 173 '../base/base.gyp:base_static', | |
| 174 ], | |
| 175 'export_dependent_settings': [ | |
| 176 '../base/base.gyp:base', | |
| 177 ], | |
| 178 'include_dirs': [ | |
| 179 '../..', | |
| 180 ], | |
| 181 }, | |
| 182 { | |
| 183 'target_name': 'sbox_integration_tests', | |
| 184 'type': 'executable', | |
| 185 'dependencies': [ | |
| 186 'sandbox', | |
| 187 'sbox_integration_test_hook_dll', | |
| 188 'sbox_integration_test_win_proc', | |
| 189 '../base/base.gyp:test_support_base', | |
| 190 '../testing/gtest.gyp:gtest', | |
| 191 ], | |
| 192 'sources': [ | |
| 193 'src/address_sanitizer_test.cc', | |
| 194 'src/app_container_test.cc', | |
| 195 'src/file_policy_test.cc', | |
| 196 'src/handle_inheritance_test.cc', | |
| 197 'tests/integration_tests/integration_tests_test.cc', | |
| 198 'src/handle_closer_test.cc', | |
| 199 'src/integrity_level_test.cc', | |
| 200 'src/ipc_ping_test.cc', | |
| 201 'src/lpc_policy_test.cc', | |
| 202 'src/named_pipe_policy_test.cc', | |
| 203 'src/policy_target_test.cc', | |
| 204 'src/process_mitigations_test.cc', | |
| 205 'src/process_policy_test.cc', | |
| 206 'src/registry_policy_test.cc', | |
| 207 'src/restricted_token_test.cc', | |
| 208 'src/sync_policy_test.cc', | |
| 209 'src/sync_policy_test.h', | |
| 210 'src/unload_dll_test.cc', | |
| 211 'tests/common/controller.cc', | |
| 212 'tests/common/controller.h', | |
| 213 'tests/common/test_utils.cc', | |
| 214 'tests/common/test_utils.h', | |
| 215 'tests/integration_tests/integration_tests.cc', | |
| 216 'tests/integration_tests/integration_tests_common.h', | |
| 217 ], | |
| 218 'link_settings': { | |
| 219 'libraries': [ | |
| 220 '-ldxva2.lib', | |
| 221 ], | |
| 222 }, | |
| 223 }, | |
| 224 { | |
| 225 'target_name': 'sbox_integration_test_hook_dll', | |
| 226 'type': 'shared_library', | |
| 227 'dependencies': [ | |
| 228 ], | |
| 229 'sources': [ | |
| 230 'tests/integration_tests/hooking_dll.cc', | |
| 231 'tests/integration_tests/integration_tests_common.h', | |
| 232 ], | |
| 233 }, | |
| 234 { | |
| 235 'target_name': 'sbox_integration_test_win_proc', | |
| 236 'type': 'executable', | |
| 237 'dependencies': [ | |
| 238 ], | |
| 239 'sources': [ | |
| 240 'tests/integration_tests/hooking_win_proc.cc', | |
| 241 'tests/integration_tests/integration_tests_common.h', | |
| 242 ], | |
| 243 'msvs_settings': { | |
| 244 'VCLinkerTool': { | |
| 245 'SubSystem': '2', # Set /SUBSYSTEM:WINDOWS | |
| 246 }, | |
| 247 }, | |
| 248 }, | |
| 249 { | |
| 250 'target_name': 'sbox_validation_tests', | |
| 251 'type': 'executable', | |
| 252 'dependencies': [ | |
| 253 'sandbox', | |
| 254 '../base/base.gyp:test_support_base', | |
| 255 '../testing/gtest.gyp:gtest', | |
| 256 ], | |
| 257 'sources': [ | |
| 258 'tests/common/controller.cc', | |
| 259 'tests/common/controller.h', | |
| 260 'tests/validation_tests/unit_tests.cc', | |
| 261 'tests/validation_tests/commands.cc', | |
| 262 'tests/validation_tests/commands.h', | |
| 263 'tests/validation_tests/suite.cc', | |
| 264 ], | |
| 265 'link_settings': { | |
| 266 'libraries': [ | |
| 267 '-lshlwapi.lib', | |
| 268 ], | |
| 269 }, | |
| 270 }, | |
| 271 { | |
| 272 'target_name': 'sbox_unittests', | |
| 273 'type': 'executable', | |
| 274 'dependencies': [ | |
| 275 'sandbox', | |
| 276 '../base/base.gyp:test_support_base', | |
| 277 '../testing/gtest.gyp:gtest', | |
| 278 ], | |
| 279 'sources': [ | |
| 280 'src/interception_unittest.cc', | |
| 281 'src/service_resolver_unittest.cc', | |
| 282 'src/restricted_token_unittest.cc', | |
| 283 'src/job_unittest.cc', | |
| 284 'src/sid_unittest.cc', | |
| 285 'src/policy_engine_unittest.cc', | |
| 286 'src/policy_low_level_unittest.cc', | |
| 287 'src/policy_opcodes_unittest.cc', | |
| 288 'src/ipc_unittest.cc', | |
| 289 'src/sandbox_nt_util_unittest.cc', | |
| 290 'src/threadpool_unittest.cc', | |
| 291 'src/win_utils_unittest.cc', | |
| 292 'tests/common/test_utils.cc', | |
| 293 'tests/common/test_utils.h', | |
| 294 'tests/unit_tests/unit_tests.cc', | |
| 295 ], | |
| 296 }, | |
| 297 { | |
| 298 'target_name': 'sandbox_poc', | |
| 299 'type': 'executable', | |
| 300 'dependencies': [ | |
| 301 'sandbox', | |
| 302 'pocdll', | |
| 303 ], | |
| 304 'sources': [ | |
| 305 'sandbox_poc/main_ui_window.cc', | |
| 306 'sandbox_poc/main_ui_window.h', | |
| 307 'sandbox_poc/resource.h', | |
| 308 'sandbox_poc/sandbox.cc', | |
| 309 'sandbox_poc/sandbox.h', | |
| 310 'sandbox_poc/sandbox.ico', | |
| 311 'sandbox_poc/sandbox.rc', | |
| 312 ], | |
| 313 'link_settings': { | |
| 314 'libraries': [ | |
| 315 '-lcomctl32.lib', | |
| 316 ], | |
| 317 }, | |
| 318 'msvs_settings': { | |
| 319 'VCLinkerTool': { | |
| 320 'SubSystem': '2', # Set /SUBSYSTEM:WINDOWS | |
| 321 }, | |
| 322 }, | |
| 323 }, | |
| 324 { | |
| 325 'target_name': 'pocdll', | |
| 326 'type': 'shared_library', | |
| 327 'sources': [ | |
| 328 'sandbox_poc/pocdll/exports.h', | |
| 329 'sandbox_poc/pocdll/fs.cc', | |
| 330 'sandbox_poc/pocdll/handles.cc', | |
| 331 'sandbox_poc/pocdll/invasive.cc', | |
| 332 'sandbox_poc/pocdll/network.cc', | |
| 333 'sandbox_poc/pocdll/pocdll.cc', | |
| 334 'sandbox_poc/pocdll/processes_and_threads.cc', | |
| 335 'sandbox_poc/pocdll/registry.cc', | |
| 336 'sandbox_poc/pocdll/spyware.cc', | |
| 337 'sandbox_poc/pocdll/utils.h', | |
| 338 ], | |
| 339 'defines': [ | |
| 340 'POCDLL_EXPORTS', | |
| 341 ], | |
| 342 'include_dirs': [ | |
| 343 '../..', | |
| 344 ], | |
| 345 }, | |
| 346 ], | |
| 347 'conditions': [ | |
| 348 ['OS=="win" and target_arch=="ia32"', { | |
| 349 'targets': [ | |
| 350 { | |
| 351 'target_name': 'sandbox_win64', | |
| 352 'type': 'static_library', | |
| 353 'variables': { | |
| 354 'sandbox_windows_target': 1, | |
| 355 'target_arch': 'x64', | |
| 356 }, | |
| 357 'dependencies': [ | |
| 358 '../base/base.gyp:base_win64', | |
| 359 '../base/base.gyp:base_static_win64', | |
| 360 ], | |
| 361 'configurations': { | |
| 362 'Common_Base': { | |
| 363 'msvs_target_platform': 'x64', | |
| 364 }, | |
| 365 }, | |
| 366 'include_dirs': [ | |
| 367 '../..', | |
| 368 ], | |
| 369 'defines': [ | |
| 370 '<@(nacl_win64_defines)', | |
| 371 ] | |
| 372 }, | |
| 373 ], | |
| 374 }], | |
| 375 ['test_isolation_mode != "noop"', { | |
| 376 'targets': [ | |
| 377 { | |
| 378 'target_name': 'sbox_integration_tests_run', | |
| 379 'type': 'none', | |
| 380 'dependencies': [ | |
| 381 'sbox_integration_tests', | |
| 382 ], | |
| 383 'includes': [ | |
| 384 '../../build/isolate.gypi', | |
| 385 ], | |
| 386 'sources': [ | |
| 387 '../sbox_integration_tests.isolate', | |
| 388 ], | |
| 389 }, | |
| 390 { | |
| 391 'target_name': 'sbox_unittests_run', | |
| 392 'type': 'none', | |
| 393 'dependencies': [ | |
| 394 'sbox_unittests', | |
| 395 ], | |
| 396 'includes': [ | |
| 397 '../../build/isolate.gypi', | |
| 398 ], | |
| 399 'sources': [ | |
| 400 '../sbox_unittests.isolate', | |
| 401 ], | |
| 402 }, | |
| 403 { | |
| 404 'target_name': 'sbox_validation_tests_run', | |
| 405 'type': 'none', | |
| 406 'dependencies': [ | |
| 407 'sbox_validation_tests', | |
| 408 ], | |
| 409 'includes': [ | |
| 410 '../../build/isolate.gypi', | |
| 411 ], | |
| 412 'sources': [ | |
| 413 '../sbox_validation_tests.isolate', | |
| 414 ], | |
| 415 }, | |
| 416 ], | |
| 417 }], | |
| 418 ], | |
| 419 } | |
| OLD | NEW |