New issue
Advanced search Search tips

Issue 915846 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Jan 11
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug

Blocking:
issue 915541



Sign in to add a comment

chromeos_startup should clear +i (immutable) file attribute under /var

Project Member Reported by vapier@chromium.org, Dec 17

Issue description

except for /var/empty, we have no valid users of +i (immutable) file attribute in the /var filesystem.  we should make sure our startup logic clears all such users automatically to avoid accidentally wedging things after a reboot.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Jan 3

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/fe61c18ba119372c2e1c716855d8f66167201c4c

commit fe61c18ba119372c2e1c716855d8f66167201c4c
Author: Mike Frysinger <vapier@chromium.org>
Date: Thu Jan 03 23:04:05 2019

init: new file_attrs_cleaner_tool helper for scrubbing bad file attributes

In case a path accidentally gets bad attributes set (like immutable
bit), make sure we clear all of that out during startup.

This CL doesn't actually enable the new tool, just builds it.

BUG= chromium:915846 
TEST=unittests pass

Change-Id: Iba95eacb49c4664a090a380dd3f6c5aa2388c538
Reviewed-on: https://chromium-review.googlesource.com/1381651
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Allen Webb <allenwebb@google.com>
Reviewed-by: Mike Frysinger <vapier@chromium.org>

[modify] https://crrev.com/fe61c18ba119372c2e1c716855d8f66167201c4c/init/BUILD.gn
[add] https://crrev.com/fe61c18ba119372c2e1c716855d8f66167201c4c/init/file_attrs_cleaner.h
[add] https://crrev.com/fe61c18ba119372c2e1c716855d8f66167201c4c/init/file_attrs_cleaner_test.cc
[add] https://crrev.com/fe61c18ba119372c2e1c716855d8f66167201c4c/init/file_attrs_cleaner_lib.cc
[add] https://crrev.com/fe61c18ba119372c2e1c716855d8f66167201c4c/init/file_attrs_cleaner_tool.cc

Project Member

Comment 2 by bugdroid1@chromium.org, Jan 3

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/6967652ba76eed6118c6b8e67611855645ba6715

commit 6967652ba76eed6118c6b8e67611855645ba6715
Author: Mike Frysinger <vapier@chromium.org>
Date: Thu Jan 03 23:04:05 2019

chromeos-init: install new file_attrs_cleaner tool

BUG= chromium:915846 
TEST=unittests pass
CQ-DEPEND=CL:1381651

Change-Id: If8f18790c509721fa172b1da94af9ea7deb35e98
Reviewed-on: https://chromium-review.googlesource.com/1381671
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>

[modify] https://crrev.com/6967652ba76eed6118c6b8e67611855645ba6715/chromeos-base/chromeos-init/chromeos-init-9999.ebuild

Project Member

Comment 3 by bugdroid1@chromium.org, Jan 8

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/c7911f384548c44f21a61f63d63581dbd362c1c4

commit c7911f384548c44f21a61f63d63581dbd362c1c4
Author: Mike Frysinger <vapier@chromium.org>
Date: Tue Jan 08 03:41:00 2019

init: chromeos_startup: scan /var and /home for bad file attributes

Make sure we don't have any paths under /var or /home that have bad
file attributes (e.g. immutable bit) set.

BUG= chromium:915846 
TEST=precq passes
CQ-DEPEND=CL:1381671

Change-Id: I201f7a762d3d276d0d0752ddfb9d47e4e05a3634
Reviewed-on: https://chromium-review.googlesource.com/1381652
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Tested-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>

[modify] https://crrev.com/c7911f384548c44f21a61f63d63581dbd362c1c4/init/chromeos_startup

Status: Fixed (was: Started)
deployed for R73
Project Member

Comment 5 by bugdroid1@chromium.org, Jan 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/53567b8736d122c4627f8431962f47208dba4581

commit 53567b8736d122c4627f8431962f47208dba4581
Author: Mike Frysinger <vapier@chromium.org>
Date: Fri Jan 11 21:32:20 2019

init: chromeos_startup: drop cryptohome scanning for now

Since cryptohome paths can get to be quite large, and they're still
encrypted at this point, lets drop the file attributes scanning of
those paths.  We'll need to revisit anyways with crbug.com/919486,
but that'll run as part of cryptohome and not in the normal boot
critical path.

BUG= chromium:915846 
TEST=precq passes

Change-Id: I5c104997132603fb139a220edc9e720d619f9be6
Reviewed-on: https://chromium-review.googlesource.com/1405649
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Mattias Nissler <mnissler@chromium.org>

[modify] https://crrev.com/53567b8736d122c4627f8431962f47208dba4581/init/chromeos_startup

Sign in to add a comment