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

Issue 692593002: Fallback library loading when SELinux blocks EXEC permission. (Closed)

Created:
6 years, 1 month ago by Anton
Modified:
6 years, 1 month ago
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Fallback library loading when SELinux blocks EXEC permission. It this case copying out into a file does not work, so we have to copy it into memory. This is the initial approach which is simplistic in that you get a copy per process (however, that is still better than not working at all). BUG=390618 Committed: https://crrev.com/b210e2d62956359840d5c8ea555c3a435cd767f3 Cr-Commit-Position: refs/heads/master@{#302297}

Patch Set 1 #

Total comments: 4

Patch Set 2 : Update for Petr's review #

Patch Set 3 : Rebase and resolve conflicts #

Total comments: 10

Patch Set 4 : Update for Simon's review #

Unified diffs Side-by-side diffs Delta from patch set Stats (+57 lines, -7 lines) Patch
M third_party/android_crazy_linker/README.chromium View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp View 1 2 3 1 chunk +54 lines, -7 lines 0 comments Download

Messages

Total messages: 16 (3 generated)
Anton
6 years, 1 month ago (2014-10-29 16:43:19 UTC) #2
petrcermak
https://codereview.chromium.org/692593002/diff/1/third_party/android_crazy_linker/README.chromium File third_party/android_crazy_linker/README.chromium (right): https://codereview.chromium.org/692593002/diff/1/third_party/android_crazy_linker/README.chromium#newcode53 third_party/android_crazy_linker/README.chromium:53: - Fallback library loading when SELinux blocks EXEC permission. ...
6 years, 1 month ago (2014-10-29 17:22:13 UTC) #3
Anton
https://codereview.chromium.org/692593002/diff/1/third_party/android_crazy_linker/README.chromium File third_party/android_crazy_linker/README.chromium (right): https://codereview.chromium.org/692593002/diff/1/third_party/android_crazy_linker/README.chromium#newcode53 third_party/android_crazy_linker/README.chromium:53: - Fallback library loading when SELinux blocks EXEC permission. ...
6 years, 1 month ago (2014-10-29 17:47:28 UTC) #4
petrcermak
Thanks, LGTM (my first one :-)).
6 years, 1 month ago (2014-10-29 17:52:47 UTC) #5
simonb (inactive)
https://codereview.chromium.org/692593002/diff/40001/third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp File third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp (right): https://codereview.chromium.org/692593002/diff/40001/third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp#newcode309 third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp:309: int prot_flags = PFLAGS_TO_PROT(phdr->p_flags); Could be const. https://codereview.chromium.org/692593002/diff/40001/third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp#newcode316 third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp:316: ...
6 years, 1 month ago (2014-10-31 14:55:09 UTC) #6
Anton
https://codereview.chromium.org/692593002/diff/40001/third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp File third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp (right): https://codereview.chromium.org/692593002/diff/40001/third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp#newcode309 third_party/android_crazy_linker/src/src/crazy_linker_elf_loader.cpp:309: int prot_flags = PFLAGS_TO_PROT(phdr->p_flags); On 2014/10/31 14:55:09, simonb wrote: ...
6 years, 1 month ago (2014-10-31 15:18:59 UTC) #7
simonb (inactive)
lgtm
6 years, 1 month ago (2014-10-31 16:53:16 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/692593002/60001
6 years, 1 month ago (2014-10-31 16:54:46 UTC) #10
commit-bot: I haz the power
Committed patchset #4 (id:60001)
6 years, 1 month ago (2014-10-31 18:58:52 UTC) #11
commit-bot: I haz the power
Patchset 4 (id:??) landed as https://crrev.com/b210e2d62956359840d5c8ea555c3a435cd767f3 Cr-Commit-Position: refs/heads/master@{#302297}
6 years, 1 month ago (2014-10-31 19:00:10 UTC) #12
rmcilroy
We can't do this without knowing how often this is happening in the wild. Please ...
6 years, 1 month ago (2014-11-02 14:08:54 UTC) #14
Anton
On 2014/11/02 14:08:54, rmcilroy wrote: > We can't do this without knowing how often this ...
6 years, 1 month ago (2014-11-03 14:40:17 UTC) #15
rmcilroy
6 years, 1 month ago (2014-11-03 18:15:04 UTC) #16
Message was sent while issue was closed.
On 2014/11/03 14:40:17, Anton wrote:
> On 2014/11/02 14:08:54, rmcilroy wrote:
> > We can't do this without knowing how often this is happening in the wild.
> Please
> > add UMA statistics for this.
> 
> UMA was already added in:
> https://codereview.chromium.org/643803003/
> 
> Are you looking for more than that?

Yes we need more than this.  The UMA that Petr added checks whether we can map
with execute permission on all devices (including those which don't load from
APK).  We also want UMA stats for how often we invoke this fallback on builds
which do load from the APK (e.g., 64bit or L) to ensure that it never happens
when we don't expect it to happen.  I chatted to Petr and he is going to look
into adding this support.

Powered by Google App Engine
This is Rietveld 408576698