New issue
Advanced search Search tips

Issue 914896 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Task



Sign in to add a comment

Runtime-verify that the native library name matches the manifest

Project Member Reported by cjgrant@chromium.org, Dec 13

Issue description

Monochrome has a manifest entry for the name of the native library (eg. libmonochrome.so).  These names need to match to facilitate relro sharing for webview.  If they don't match, things still run, but a bunch of memory is wasted.

When initially switching Chrome bundles to use lib<x>_base.so, this was a tripping point.  See https://crrev.com/c/1374734.

We should have the app verify matching libraries on startup.  Or, we should rejig the build such that the manifest automatically picks up the name of the library packaged into the APK/bundle.  Either way, the manual nature of this should be made foolproof.
 
Advice from torne@:

- Would have to skip for component builds because none of this would work in component builds
- Webview at least already fetches its own packageinfo with metadata somewhere (fairly sure chrome does too); that would be a convenient place to check
- Unfortunately the copy of the PackageInfo in the Context object doesn't contain metadata. So you do have to ask PackageManager at some point, at least once.

Sign in to add a comment