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

Issue 264923003: Initial implementation of the Mac Bootstrap Sandbox. (Closed)

Created:
6 years, 7 months ago by Robert Sesek
Modified:
6 years, 7 months ago
CC:
chromium-reviews
Visibility:
Public.

Description

Initial implementation of the Mac Bootstrap Sandbox. This adds the implementation for the second-layer sandbox, with tests, but it does not wire it up for use in Chrome. Design document: https://docs.google.com/a/chromium.org/document/d/108sr6gBxqdrnzVPsb_4_JbDyW1V4-DRQUC4R8YvM40M/edit BUG=367863 TEST=Covered by unit tests, manually verified on 10.6.8, 10.7.5, 10.8.5, and 10.9.2. Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=269937

Patch Set 1 #

Total comments: 86

Patch Set 2 : Address comments #

Patch Set 3 : Rebase for new Mach utilities #

Total comments: 27

Patch Set 4 : Address comments #

Total comments: 4

Patch Set 5 : Initialization changes #

Total comments: 5

Patch Set 6 : OWNERS #

Patch Set 7 : Rebase for sandbox_export.h #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1224 lines, -10 lines) Patch
A sandbox/mac/bootstrap_sandbox.h View 1 2 3 4 5 6 1 chunk +108 lines, -0 lines 0 comments Download
A sandbox/mac/bootstrap_sandbox.cc View 1 2 3 1 chunk +127 lines, -0 lines 0 comments Download
A sandbox/mac/bootstrap_sandbox_unittest.mm View 1 1 chunk +269 lines, -0 lines 0 comments Download
A sandbox/mac/launchd_interception_server.h View 1 2 3 1 chunk +96 lines, -0 lines 0 comments Download
A sandbox/mac/launchd_interception_server.cc View 1 2 3 4 1 chunk +273 lines, -0 lines 0 comments Download
A sandbox/mac/os_compatibility.h View 1 1 chunk +45 lines, -0 lines 0 comments Download
A sandbox/mac/os_compatibility.cc View 1 2 3 1 chunk +105 lines, -0 lines 0 comments Download
A sandbox/mac/policy.h View 1 2 3 4 5 6 1 chunk +57 lines, -0 lines 0 comments Download
A sandbox/mac/policy.cc View 1 2 3 1 chunk +44 lines, -0 lines 0 comments Download
A sandbox/mac/policy_unittest.cc View 1 2 3 1 chunk +62 lines, -0 lines 0 comments Download
M sandbox/mac/sandbox_mac.gypi View 1 2 3 4 5 6 1 chunk +38 lines, -2 lines 0 comments Download
D sandbox/mac/temp_test.cc View 1 chunk +0 lines, -8 lines 0 comments Download

Messages

Total messages: 22 (0 generated)
Robert Sesek
6 years, 7 months ago (2014-05-01 15:49:11 UTC) #1
Mark Mentovai
> Affected files (+1156, -9 lines): Ha!
6 years, 7 months ago (2014-05-01 15:54:43 UTC) #2
Mark Mentovai
https://codereview.chromium.org/264923003/diff/1/sandbox/mac/bootstrap_sandbox.cc File sandbox/mac/bootstrap_sandbox.cc (right): https://codereview.chromium.org/264923003/diff/1/sandbox/mac/bootstrap_sandbox.cc#newcode22 sandbox/mac/bootstrap_sandbox.cc:22: TASK_BOOTSTRAP_PORT, sandbox->server_->server_port()); There’s a global extern mach_port_t named bootstrap_port ...
6 years, 7 months ago (2014-05-06 20:51:49 UTC) #3
Robert Sesek
I'll have to wait to rebase to take advantage of mach_logging.h and scoped_mach_vm.h. https://codereview.chromium.org/264923003/diff/1/sandbox/mac/bootstrap_sandbox.cc File ...
6 years, 7 months ago (2014-05-08 20:58:11 UTC) #4
Robert Sesek
On 2014/05/08 20:58:11, rsesek wrote: > I'll have to wait to rebase to take advantage ...
6 years, 7 months ago (2014-05-09 16:22:48 UTC) #5
Mark Mentovai
https://codereview.chromium.org/264923003/diff/1/sandbox/mac/bootstrap_sandbox.cc File sandbox/mac/bootstrap_sandbox.cc (right): https://codereview.chromium.org/264923003/diff/1/sandbox/mac/bootstrap_sandbox.cc#newcode22 sandbox/mac/bootstrap_sandbox.cc:22: TASK_BOOTSTRAP_PORT, sandbox->server_->server_port()); rsesek wrote: > On 2014/05/06 20:51:50, Mark ...
6 years, 7 months ago (2014-05-09 20:11:17 UTC) #6
Avi (use Gerrit)
Semi-drive-by. https://codereview.chromium.org/264923003/diff/60001/sandbox/mac/bootstrap_sandbox.h File sandbox/mac/bootstrap_sandbox.h (right): https://codereview.chromium.org/264923003/diff/60001/sandbox/mac/bootstrap_sandbox.h#newcode64 sandbox/mac/bootstrap_sandbox.h:64: void PrepareToForkWithPolicy(int sandbox_policy_id); The comment talks about returning ...
6 years, 7 months ago (2014-05-09 21:02:06 UTC) #7
Robert Sesek
https://codereview.chromium.org/264923003/diff/1/sandbox/mac/bootstrap_sandbox.cc File sandbox/mac/bootstrap_sandbox.cc (right): https://codereview.chromium.org/264923003/diff/1/sandbox/mac/bootstrap_sandbox.cc#newcode22 sandbox/mac/bootstrap_sandbox.cc:22: TASK_BOOTSTRAP_PORT, sandbox->server_->server_port()); On 2014/05/09 20:11:19, Mark Mentovai wrote: > ...
6 years, 7 months ago (2014-05-09 22:04:03 UTC) #8
Mark Mentovai
https://codereview.chromium.org/264923003/diff/60001/sandbox/mac/launchd_interception_server.cc File sandbox/mac/launchd_interception_server.cc (right): https://codereview.chromium.org/264923003/diff/60001/sandbox/mac/launchd_interception_server.cc#newcode62 sandbox/mac/launchd_interception_server.cc:62: request_buffer_.reset(buffer, kBufferSize); rsesek wrote: > On 2014/05/09 20:11:19, Mark ...
6 years, 7 months ago (2014-05-09 22:20:52 UTC) #9
Robert Sesek
https://codereview.chromium.org/264923003/diff/60001/sandbox/mac/launchd_interception_server.cc File sandbox/mac/launchd_interception_server.cc (right): https://codereview.chromium.org/264923003/diff/60001/sandbox/mac/launchd_interception_server.cc#newcode62 sandbox/mac/launchd_interception_server.cc:62: request_buffer_.reset(buffer, kBufferSize); On 2014/05/09 22:20:52, Mark Mentovai wrote: > ...
6 years, 7 months ago (2014-05-09 22:29:45 UTC) #10
Mark Mentovai
LGTM https://codereview.chromium.org/264923003/diff/100001/sandbox/mac/launchd_interception_server.cc File sandbox/mac/launchd_interception_server.cc (right): https://codereview.chromium.org/264923003/diff/100001/sandbox/mac/launchd_interception_server.cc#newcode33 sandbox/mac/launchd_interception_server.cc:33: if (server_source_) Good call. The source code shows ...
6 years, 7 months ago (2014-05-09 22:34:23 UTC) #11
Robert Sesek
Thanks for the review. +jln for sandbox OWNERS
6 years, 7 months ago (2014-05-09 22:38:23 UTC) #12
jln (very slow on Chromium)
Rubberstamp lgtm Do you want to add yourself and another owner (maybe Mark?) to sandbox/mac/OWNERS? ...
6 years, 7 months ago (2014-05-09 23:10:10 UTC) #13
Robert Sesek
On 2014/05/09 23:10:10, jln wrote: > Rubberstamp lgtm > > Do you want to add ...
6 years, 7 months ago (2014-05-09 23:21:19 UTC) #14
Robert Sesek
https://codereview.chromium.org/264923003/diff/100001/sandbox/mac/bootstrap_sandbox.h File sandbox/mac/bootstrap_sandbox.h (right): https://codereview.chromium.org/264923003/diff/100001/sandbox/mac/bootstrap_sandbox.h#newcode36 sandbox/mac/bootstrap_sandbox.h:36: // Clients that which to use the sandbox must ...
6 years, 7 months ago (2014-05-09 23:21:38 UTC) #15
Robert Sesek
The CQ bit was checked by rsesek@chromium.org
6 years, 7 months ago (2014-05-09 23:42:17 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rsesek@chromium.org/264923003/120001
6 years, 7 months ago (2014-05-09 23:43:56 UTC) #17
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). Please consider checking whether the failures are ...
6 years, 7 months ago (2014-05-10 02:45:37 UTC) #18
Robert Sesek
The CQ bit was unchecked by rsesek@chromium.org
6 years, 7 months ago (2014-05-10 03:08:16 UTC) #19
Robert Sesek
The CQ bit was checked by rsesek@chromium.org
6 years, 7 months ago (2014-05-12 20:19:32 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rsesek@chromium.org/264923003/130001
6 years, 7 months ago (2014-05-12 20:20:04 UTC) #21
commit-bot: I haz the power
6 years, 7 months ago (2014-05-13 00:41:01 UTC) #22
Message was sent while issue was closed.
Change committed as 269937

Powered by Google App Engine
This is Rietveld 408576698