| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
| |
We did not set DF_1_GLOBAL flag for LD_PRELOADed
libraries which led to the situation when ld_preloads
where ignored during on dlopen()
Change-Id: I696b3b2506a8ed4c0984ad2c803210a7a4f8e686
(cherry picked from commit f8093a9485402584f75b774ddf2ca051fa9b8aad)
|
|
|
|
|
|
|
|
| |
Relocation packer no longer encodes relocation tables
using unsigned leb128: https://android-review.googlesource.com/147745
Bug: http://b/18051137
Change-Id: I620b7188e5f3dd9d5123431aa1fc7feca76be607
|
|
|
|
| |
Change-Id: I079e6f1dd95fe9cae2135fcd7358c51f8b584ac9
|
|
|
|
|
| |
Bug: http://b/20139821
Change-Id: I64122a0fb0960c20b2ce614161b7ab048456b681
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change adds realpath to soinfo and
extends limit on filenames from 128 to PATH_MAX.
It also removes soinfo::name field, linker uses
dt_soname instead.
Bug: http://b/19818481
Bug: https://code.google.com/p/android/issues/detail?id=80336
Change-Id: I9cff4cb5bda3ee2bc74e1bbded9594ea7fbe2a08
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This flag allows to force loading of the library
in the case when for some reason multiple ELF files
share the same filename (because the already-loaded
library has been removed and overwritten, for example).
Change-Id: I798d44409ee13d63eaa75d685e99c4d028d2b0c1
|
|/
|
|
|
|
|
|
| |
Fix dlsym to look into local group when called with
RTLD_DEFAULT and RTLD_NEXT.
Bug: 17512583
Change-Id: I541354e89539c712af2ea4ec751e546913027084
|
|
|
|
|
|
|
|
| |
This reverts commit cb00add1b382d1e3045876d7e1ccbee2fdce976b.
Bug: 20020312
Bug: 20013628
Change-Id: I8baa3d4b6c7fef50c9e2531257d5b96762099eb3
|
|
|
|
|
| |
Bug: 20013628
Change-Id: Idaf8012f00ee1304d429c3b42f9ebc6b648c55b8
|
|
|
|
| |
Change-Id: I4e1cab488d5b2c8e4289da617350a86e72a4ba12
|
|
|
|
|
|
|
| |
This effectively removes limit on length and count
of LD_LIBRARY_PATH and LD_PRELOAD entries.
Change-Id: Ie7ea34a50d99c4018f9dd1a33aaebc4049a7f424
|
|
|
|
|
|
|
|
|
| |
This CL also fixes SEARCH_NAME hack and resolves
https://code.google.com/p/android/issues/detail?id=6670
once and for all.
Bug: https://code.google.com/p/android/issues/detail?id=6670
Change-Id: I9b8d6a672cd722f30fbfbb40cdee8d9b39cfe56e
|
|
|
|
|
|
|
|
| |
If filename contains a slash, then it is interpreted
as a (relative or absolute) pathname.
Bug: https://code.google.com/p/android/issues/detail?id=6670
Change-Id: Iba57d638301f3089ad47ba083edca2dd36b801ed
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add code to support loading shared libraries directly from within
APK files.
Extends the linker's handling of LD_LIBRARY_PATH, DT_RUNPATH, etc
to allow elements to be either directories as normal, or ZIP
format files. For ZIP, the ZIP subdirectory string is separated
from the path to file by '!'.
For example, if DT_NEEDED is libchrome.so and Chrome.apk is the
Android ARM APK then the path element
/system/app/Chrome.apk!lib/armeabi-v7a
would cause the linker to load lib/armeabi-v7a/libchrome.so
directly from inside Chrome.apk. For loading to succeed,
libchrome.so must be 'stored' and not compressed in Chrome.apk,
and must be page aligned within the file.
Motivation:
Chromium tracking issue:
https://code.google.com/p/chromium/issues/detail?id=390618
Bug: 8076853
Change-Id: Ic49046600b1417eae3ee8f37ee98c8ac1ecc19e7
|
|
|
|
|
|
|
|
| |
Add basic general purpose memory allocator to
linker in order to enable usage of other libraries
like libziparchive.
Change-Id: I4a680ebb36ed5ba67c61249f81dba9f567808434
|
|
|
|
| |
Change-Id: I87d80fbcd4ec26c0ee4f601b9c4c64f600418dd9
|
|
|
|
| |
Change-Id: Ifc08e64b3a85205f072b7abab1149c7ab71e2f75
|
|
|
|
|
|
|
|
|
|
|
| |
Kindle app relies on soinfo's sysv hash
fields while linking native libraries.
This change allows to keep sysv hash fields
intact for the libraries linked with --hash-style=both.
Bug: 19059885
Change-Id: I12528652955638f1a6586bda99e111bb1c8aa7a3
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the kernel executes a program which is setuid, setgid, has
file capabilities, or causes an SELinux domain transition, the
AT_SECURE flag is set. This flag instructs the dynamic linker to
prune any dangerous environment variables passed across security
boundaries.
For SELinux in particular, whether this flag is set depends on the
the "noatsecure" process permission. If that permission does not
exist, then AT_SECURE=1 whenever a domain transition occurs.
In https://android-review.googlesource.com/129971 , Android stopped
using noatsecure when executing init services. In
https://android-review.googlesource.com/130610 , init was flipped
back into SELinux enforcing mode, making ag/129971 active. The
combination of those two changes ensured that AT_SECURE=1 was
set when executing init spawned services.
In particular, AT_SECURE=1 is set when init executes zygote. Due to
the forking nature of zygote, AT_SECURE remains untouched when
executing zygote's children.
This causes problems for the code added in
https://android-review.googlesource.com/48409 . Specifically, if
AT_SECURE=1, an attempt to call android_update_LD_LIBRARY_PATH()
is silently ignored. This causes problems when art tries to adjust
the LD_LIBRARY_PATH for Android apps. Ultimately, apps are unable
to find shared libraries they depend on.
As discussed in bug 7896159, there's no security reason for
preventing an application from updating it's own LD_LIBRARY_PATH.
We only need to prune LD_LIBRARY_PATH when transitioning across
security boundaries, but not when we're entirely within a security
boundary.
Remove the AT_SECURE check within do_android_update_LD_LIBRARY_PATH().
It's unneeded and prevents an application from modifying it's own
LD_LIBRARY_PATH. This allows an application to specify a location
where it's dlopen()ed shared libraries should be loaded from.
There is no change to AT_SECURE handling in
__sanitize_environment_variables(). We continue to honor it there
to prevent using security sensitive environment variables across
an exec boundary.
Bug: 19559835
Change-Id: If4af2ee8e84265aaa0c93de8b281208b20d7942a
|
|
|
|
| |
Change-Id: I796a4ce86d3fccb8361c19889419c96147ee3c9f
|
|
|
|
|
|
| |
Replace rel/rela array with reloc_iterators.
Change-Id: I6165d062e0390b6bc60da2e8279aabbedf828ec9
|
|
|
|
| |
Change-Id: I88827aa07d75d06d606c987e6270fcca3ae6216f
|
|
|
|
|
|
|
| |
load_bias is the delta between a symbols address in memory and the value
contained in the symbol table.
Change-Id: I35c87b69025b64f7e4a1418ca766618f4533fb3e
|
|
|
|
|
|
|
|
|
|
| |
Implement refcounter based data protection guard
to avoid unnecessary calls to mprotect when dlopen/dlclose
is called from a constructor.
Bug: 19124318
Big: 7941716
Change-Id: Id221b84ce75443094f99756dc9950b0a1dc87222
|
|
|
|
|
|
|
|
| |
Handy when looking at strace output for seeing "where does my code start?",
though you'll need to set LD_DEBUG=1 (or greater) and constructors will
already have run (but you can set LD_DEBUG to a higher value to track that).
Change-Id: I82d53a7123b39febf5b2a956de83c8a30f229651
|
|
|
|
|
|
| |
And fix old style casts.
Change-Id: I37e7a3e3fd852528ea76f02d967c7bd8cd5b06c9
|
|
|
|
| |
Change-Id: I712614853e3f0e515f5c2bdd8f0aaa5feeae8e55
|
|
|
|
|
|
| |
Use one relocate for all platforms.
Change-Id: I43e75162c5b29105e651defc11a511e168368736
|
|
|
|
| |
Change-Id: I94dd6256b1b4509b6ea696a3aff17a3991529468
|
|
|
|
|
|
| |
This reverts commit 265a60a0d285a733d9d98f53672bce668803b434.
Change-Id: I6d46db0ac03cda44ed1e20f6084a552e0089eb14
|
|
|
|
| |
Change-Id: I67918a1a926164a38a5a47f2264390632eb42905
|
|
|
|
|
|
| |
Move common relocation types outside of ifdefs
Change-Id: I713800ce123a18178b5ac80c0b3c7bd6b21a02c2
|
|\ |
|
| |
| |
| |
| |
| | |
Bug: 18069809
Change-Id: Ie143d56b0f8f03510dc451649291067e1add1d2f
|
|/
|
|
|
|
| |
Bug: 18931021
Change-Id: Ib6c39a409161b20a10c3485272c73bc2abd4ee4f
(cherry picked from commit d9e211ca1fcf8bb78a1e1de9e54fe7c8d0a01518)
|
|
|
|
|
|
|
|
| |
Position Independent Executables cannot communicate with GDB using DT_MIPS_RLD_TAG.
Hence a new tag DT_MIPS_RLD_MAP2 got introduced to fix the issue.
Change-Id: I77ce3faf1ef2e121003b804ecd291abb25cfbb56
Signed-off-by: Nikola Veljkovic<Nikola.Veljkovic@imgtec.com>
|
|
|
|
|
|
|
|
|
| |
1. Take into consideration that the local_group_root_
is not set for all of not linked libraries.
2. We need to check visited list earlier to avoid double
soinfo_free.
Change-Id: Iabc0a06a97c63f7e6bd4641731f50bb1466fed4f
|
|
|
|
| |
Change-Id: Iddbf06784d19556a55d833e20a68e6ccf5a7c5be
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Count references on the group level to avoid
partially unloading function that might be
referenced by other libraries in the local_group
Bonus: with this change we can correctly unload recursively
linked libraries. is_recursive check is removed.
Also dynamic executables (not .so) with 0 DT_NEEDED libraries
are now correctly linked.
Change-Id: Idfa83baef402840599b93a875f2881d9f020dbcd
|
|/
|
|
|
| |
Change-Id: Id18310811a6d183878a1d4d26cc2498f4fd00c55
Signed-off-by: Alexander Ivchenko <alexander.ivchenko@intel.com>
|
|
|
|
|
|
|
| |
Split d-tor calls and soinfo_free to 2 separate steps
Bug: 18338888
Change-Id: Idbcb7242ade16fa18cba7fe30505ebd8d6023622
|
|
|
|
| |
Change-Id: If68fbe287d3ad954238b1688f71013371f3f7fae
|
|
|
|
| |
Change-Id: I58b01db38ab9a397a8bd77c1296aac12957c21da
|
|
|
|
| |
Change-Id: I171434a587420895feac8a9b1ad2342087197568
|
|
|
|
|
|
|
| |
Bug: 18178121
Bug: 18078224
Change-Id: I5254433d54645db68e9b83d5095dc2bf9d8531bc
|
|\ |
|
| |
| |
| |
| |
| |
| | |
This reverts commit da8e591c3996879e41dc5f70b77d1b0fe6f9c225.
Change-Id: I3fd6f235b18c232af5cc5ecd481851486d7d68f6
|
|\ \
| |/
|/| |
|