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

Issue 10826093: Create a LinuxSandbox class (Closed)

Created:
8 years, 4 months ago by jln (very slow on Chromium)
Modified:
8 years, 4 months ago
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam, agl, jln+watch_chromium.org, Chris Evans
Visibility:
Public.

Description

Create a LinuxSandbox class. The LinuxSandbox class aims to become the central place for Linux sandboxing inside content/. For now, this refactors mostly code from the Zygote. BUG= NOTRY=true Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=149692

Patch Set 1 : #

Total comments: 7

Patch Set 2 : Address first round of comments from Markus. #

Total comments: 12

Patch Set 3 : #

Total comments: 4

Patch Set 4 : Address Jorge's comments. #

Total comments: 16

Patch Set 5 : Address Antoine's remarks. #

Patch Set 6 : Always pre-initialize before calling SeccompLegacy. #

Patch Set 7 : Only include the sandbox_bpf.h header on supported architectures. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+332 lines, -161 lines) Patch
M content/browser/renderer_host/render_sandbox_host_linux.cc View 2 chunks +2 lines, -1 line 0 comments Download
M content/common/OWNERS View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M content/common/child_process_sandbox_support_impl_linux.cc View 1 chunk +1 line, -1 line 0 comments Download
M content/common/child_process_sandbox_support_impl_shm_linux.cc View 1 chunk +1 line, -1 line 0 comments Download
M content/common/sandbox_init_linux.cc View 3 chunks +2 lines, -18 lines 0 comments Download
A content/common/sandbox_linux.h View 1 2 3 4 1 chunk +94 lines, -0 lines 0 comments Download
A content/common/sandbox_linux.cc View 1 2 3 4 5 6 1 chunk +184 lines, -0 lines 0 comments Download
D content/common/sandbox_methods_linux.h View 1 chunk +0 lines, -24 lines 0 comments Download
M content/common/seccomp_sandbox.h View 2 chunks +0 lines, -24 lines 0 comments Download
M content/content_common.gypi View 1 2 3 4 5 1 chunk +2 lines, -1 line 0 comments Download
M content/public/common/sandbox_linux.h View 1 2 3 4 1 chunk +6 lines, -4 lines 0 comments Download
M content/zygote/zygote_linux.h View 3 chunks +1 line, -11 lines 0 comments Download
M content/zygote/zygote_linux.cc View 3 chunks +5 lines, -17 lines 0 comments Download
M content/zygote/zygote_main_linux.cc View 1 2 3 4 4 chunks +14 lines, -55 lines 0 comments Download
M sandbox/linux/suid/client/setuid_sandbox_client.h View 3 chunks +5 lines, -1 line 0 comments Download
M sandbox/linux/suid/client/setuid_sandbox_client.cc View 3 chunks +11 lines, -2 lines 0 comments Download
M sandbox/linux/suid/client/setuid_sandbox_client_unittest.cc View 1 chunk +3 lines, -0 lines 0 comments Download

Messages

Total messages: 15 (0 generated)
jln (very slow on Chromium)
This is one of the many steps to centralize our Linux sandboxing. The LinuxSandbox class ...
8 years, 4 months ago (2012-08-01 05:47:18 UTC) #1
Markus (顧孟勤)
lgtm https://chromiumcodereview.appspot.com/10826093/diff/18/content/common/sandbox_linux.cc File content/common/sandbox_linux.cc (right): https://chromiumcodereview.appspot.com/10826093/diff/18/content/common/sandbox_linux.cc#newcode22 content/common/sandbox_linux.cc:22: inline bool IsSeccompLegacyDesired() { Do we ever explicitly ...
8 years, 4 months ago (2012-08-01 22:09:19 UTC) #2
jln (very slow on Chromium)
https://chromiumcodereview.appspot.com/10826093/diff/18/content/common/sandbox_linux.cc File content/common/sandbox_linux.cc (right): https://chromiumcodereview.appspot.com/10826093/diff/18/content/common/sandbox_linux.cc#newcode22 content/common/sandbox_linux.cc:22: inline bool IsSeccompLegacyDesired() { On 2012/08/01 22:09:19, Markus (顧孟勤) ...
8 years, 4 months ago (2012-08-01 22:21:53 UTC) #3
jln (very slow on Chromium)
jam@: do you mind approving as owner of content ? For things that I don't ...
8 years, 4 months ago (2012-08-01 22:26:23 UTC) #4
Jorge Lucangeli Obes
https://chromiumcodereview.appspot.com/10826093/diff/14003/content/common/sandbox_linux.cc File content/common/sandbox_linux.cc (right): https://chromiumcodereview.appspot.com/10826093/diff/14003/content/common/sandbox_linux.cc#newcode58 content/common/sandbox_linux.cc:58: if (!instance->setuid_sandbox_) { Do we use braces around one-line ...
8 years, 4 months ago (2012-08-01 22:37:50 UTC) #5
jln (very slow on Chromium)
https://chromiumcodereview.appspot.com/10826093/diff/14003/content/common/sandbox_linux.cc File content/common/sandbox_linux.cc (right): https://chromiumcodereview.appspot.com/10826093/diff/14003/content/common/sandbox_linux.cc#newcode58 content/common/sandbox_linux.cc:58: if (!instance->setuid_sandbox_) { On 2012/08/01 22:37:50, Jorge Lucangeli Obes ...
8 years, 4 months ago (2012-08-01 22:48:11 UTC) #6
Jorge Lucangeli Obes
LGTM but please fix the second comment. https://chromiumcodereview.appspot.com/10826093/diff/19/content/common/OWNERS File content/common/OWNERS (right): https://chromiumcodereview.appspot.com/10826093/diff/19/content/common/OWNERS#newcode1 content/common/OWNERS:1: # For ...
8 years, 4 months ago (2012-08-01 22:53:57 UTC) #7
jln (very slow on Chromium)
https://chromiumcodereview.appspot.com/10826093/diff/19/content/common/OWNERS File content/common/OWNERS (right): https://chromiumcodereview.appspot.com/10826093/diff/19/content/common/OWNERS#newcode1 content/common/OWNERS:1: # For sandbox_*_linux.* On 2012/08/01 22:53:57, Jorge Lucangeli Obes ...
8 years, 4 months ago (2012-08-01 22:57:36 UTC) #8
jln (very slow on Chromium)
Antoine: jam@ seems to be OOO according to his calendar. Do you mind approving this? ...
8 years, 4 months ago (2012-08-02 03:33:41 UTC) #9
piman
mostly nits https://chromiumcodereview.appspot.com/10826093/diff/12009/content/common/sandbox_linux.cc File content/common/sandbox_linux.cc (right): https://chromiumcodereview.appspot.com/10826093/diff/12009/content/common/sandbox_linux.cc#newcode51 content/common/sandbox_linux.cc:51: delete setuid_sandbox_; That calls for scoped_ptr https://chromiumcodereview.appspot.com/10826093/diff/12009/content/common/sandbox_linux.cc#newcode57 ...
8 years, 4 months ago (2012-08-02 17:31:20 UTC) #10
jln (very slow on Chromium)
Thanks, PTAL! https://chromiumcodereview.appspot.com/10826093/diff/12009/content/common/sandbox_linux.cc File content/common/sandbox_linux.cc (right): https://chromiumcodereview.appspot.com/10826093/diff/12009/content/common/sandbox_linux.cc#newcode51 content/common/sandbox_linux.cc:51: delete setuid_sandbox_; On 2012/08/02 17:31:20, piman wrote: ...
8 years, 4 months ago (2012-08-02 18:25:22 UTC) #11
piman
lgtm https://chromiumcodereview.appspot.com/10826093/diff/12009/content/common/sandbox_linux.h File content/common/sandbox_linux.h (right): https://chromiumcodereview.appspot.com/10826093/diff/12009/content/common/sandbox_linux.h#newcode53 content/common/sandbox_linux.h:53: void PreinitializeSandbox(); On 2012/08/02 18:25:22, Julien Tinnes wrote: ...
8 years, 4 months ago (2012-08-02 18:29:55 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jln@chromium.org/10826093/15004
8 years, 4 months ago (2012-08-02 18:52:32 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jln@chromium.org/10826093/4060
8 years, 4 months ago (2012-08-02 20:37:13 UTC) #14
commit-bot: I haz the power
8 years, 4 months ago (2012-08-02 20:38:06 UTC) #15
Change committed as 149692

Powered by Google App Engine
This is Rietveld 408576698