New issue
Advanced search Search tips

Issue 836341 link

Starred by 1 user

Issue metadata

Status: Verified
Owner:
Closed: May 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Fuchsia
Pri: 1
Type: Bug



Sign in to add a comment

base_unittests consistently failing under Fuchsia/x64 FYI bot

Project Member Reported by w...@chromium.org, Apr 24 2018

Issue description

See e.g. https://ci.chromium.org/buildbot/chromium.fyi/Fuchsia/16441 failures for base_unittests:


 

Comment 1 by w...@chromium.org, Apr 24 2018

ProcessUtilTest.GetAppOutputWithExitCode
ProcessUtilTest.LaunchProcess
ProcessUtilTest.GetAppOutput
ProcessUtilTest.FDRemappingIncludesStdio

Comment 2 by w...@chromium.org, Apr 24 2018

ProcessUtilTest.FDRemappingIncludesStdio is failing due to lack of /dev/null.

The other tests are failing due to lack of the "sh" command.

Comment 3 by w...@chromium.org, Apr 24 2018

Cc: -kmarshall@chromium.org w...@chromium.org
Components: Internals>PlatformIntegration
Owner: kmarshall@chromium.org
Project Member

Comment 4 by bugdroid1@chromium.org, Apr 25 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b9612d09b3d6879337d0795a8b82011d7cf4eee1

commit b9612d09b3d6879337d0795a8b82011d7cf4eee1
Author: Kevin Marshall <kmarshall@chromium.org>
Date: Wed Apr 25 00:55:18 2018

Fuchsia: Expose /dev/null and /dev/zero to packaged test processes.

Some tests make use of /dev/null and /dev/zero , which was removed
by default as a consequence of turning off the "shell" permission.

This change re-adds those devices to the process' namespaces
by specifying them in the sandbox policy.

Added GN arguments for specifying different sandbox policies in
test and production executables.


Bug:  836341 
Change-Id: If9bf9109e855ec7aa7a07672352be93160252a0c
Reviewed-on: https://chromium-review.googlesource.com/1026394
Reviewed-by: Dirk Pranke <dpranke@chromium.org>
Reviewed-by: Wez <wez@chromium.org>
Commit-Queue: Kevin Marshall <kmarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#553402}
[modify] https://crrev.com/b9612d09b3d6879337d0795a8b82011d7cf4eee1/build/config/fuchsia/build_manifest.py
[modify] https://crrev.com/b9612d09b3d6879337d0795a8b82011d7cf4eee1/build/config/fuchsia/package.gni
[modify] https://crrev.com/b9612d09b3d6879337d0795a8b82011d7cf4eee1/build/config/fuchsia/rules.gni
[add] https://crrev.com/b9612d09b3d6879337d0795a8b82011d7cf4eee1/build/config/fuchsia/testing_sandbox_policy
[modify] https://crrev.com/b9612d09b3d6879337d0795a8b82011d7cf4eee1/testing/test.gni

Project Member

Comment 5 by bugdroid1@chromium.org, Apr 25 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/3a52bf670fb4e7da6832c2cd3e407b42bc2447cf

commit 3a52bf670fb4e7da6832c2cd3e407b42bc2447cf
Author: Wez <wez@chromium.org>
Date: Wed Apr 25 10:02:05 2018

Restore 'shell' feature in test package sandbox policy.

The 'shell' feature removal CL was reverted after the sandbox policy
files had been split into production and test versions, so the revert
did not apply to the new test process policy.

TBR: kmarshall
Bug:  823927 ,  836341 
Change-Id: I9a4c75cb01c255887a4928c31ab199e039d53397
Reviewed-on: https://chromium-review.googlesource.com/1027441
Reviewed-by: Wez <wez@chromium.org>
Commit-Queue: Wez <wez@chromium.org>
Cr-Commit-Position: refs/heads/master@{#553500}
[modify] https://crrev.com/3a52bf670fb4e7da6832c2cd3e407b42bc2447cf/build/config/fuchsia/testing_sandbox_policy

Project Member

Comment 6 by bugdroid1@chromium.org, Apr 26 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5b3d5a34cfaffaed8c6f80d2700b4f34b42c5964

commit 5b3d5a34cfaffaed8c6f80d2700b4f34b42c5964
Author: Kevin Marshall <kmarshall@chromium.org>
Date: Thu Apr 26 00:10:36 2018

Use Chromium-built "test_child_process" for GetAppOutput tests instead of "sh".

GetAppOutput relies on a platform-supplied shell interpreter to
exercise ProcessUtil's output handling codepaths
and the GetAppOutput tests rewritten to use it.

This doesn't work for Fuchsia, as packaged executables aren't
allowed to access other binaries that aren't included
in the package.

This CL defines a trivial test executable "test_child_process",
which behaves similar to "echo", and the GetAppOutput tests
are rewritten to use it.


Bug:  836341 
Change-Id: If681b62f4ecf486a6b62387be0610fec6771ae4e
Reviewed-on: https://chromium-review.googlesource.com/1026796
Commit-Queue: Kevin Marshall <kmarshall@chromium.org>
Reviewed-by: Wez <wez@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: Scott Graham <scottmg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#553835}
[modify] https://crrev.com/5b3d5a34cfaffaed8c6f80d2700b4f34b42c5964/base/BUILD.gn
[modify] https://crrev.com/5b3d5a34cfaffaed8c6f80d2700b4f34b42c5964/base/process/process_util_unittest.cc
[modify] https://crrev.com/5b3d5a34cfaffaed8c6f80d2700b4f34b42c5964/base/test/BUILD.gn
[add] https://crrev.com/5b3d5a34cfaffaed8c6f80d2700b4f34b42c5964/base/test/test_child_process.cc

Project Member

Comment 7 by bugdroid1@chromium.org, Apr 26 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/98ffc41ad2518b62ec32d2c62f8da62ea1571357

commit 98ffc41ad2518b62ec32d2c62f8da62ea1571357
Author: Kevin Marshall <kmarshall@chromium.org>
Date: Thu Apr 26 20:38:53 2018

Fuchsia: remove "shell" capability and add dynamic libraries to packages.

Removing the "shell" capability allows packaged apps to load dynamic
libraries from the package. In addition, it prevents the app from using any
system-provided libraries, in favor of the package supplying all of
its data and dynamic library dependencies.

This CL includes the system libraries from the SDK's "dist" directory
in packages built using the package() GN template.

This reverts commit 2841fb2f7be2c0b91953a86fa0460c4ac94aac24.

Bug:  823927 , 836341 ,  837203 
Change-Id: Iea57853f6c3c4ebc36de4f758f168fffbd4d79ba
Reviewed-on: https://chromium-review.googlesource.com/1027087
Reviewed-by: Wez <wez@chromium.org>
Commit-Queue: Kevin Marshall <kmarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#554129}
[modify] https://crrev.com/98ffc41ad2518b62ec32d2c62f8da62ea1571357/build/config/fuchsia/build_manifest.py
[modify] https://crrev.com/98ffc41ad2518b62ec32d2c62f8da62ea1571357/build/config/fuchsia/config.gni
[modify] https://crrev.com/98ffc41ad2518b62ec32d2c62f8da62ea1571357/build/config/fuchsia/package.gni
[modify] https://crrev.com/98ffc41ad2518b62ec32d2c62f8da62ea1571357/build/config/fuchsia/sandbox_policy
[modify] https://crrev.com/98ffc41ad2518b62ec32d2c62f8da62ea1571357/build/config/fuchsia/testing_sandbox_policy

Status: Verified (was: Started)

Sign in to add a comment