diff options
author | Justin DeMartino <jjdemartino@google.com> | 2020-09-21 13:23:58 -0700 |
---|---|---|
committer | Justin DeMartino <jjdemartino@google.com> | 2020-09-21 13:23:58 -0700 |
commit | 7e4fe6a28b718ab97c08811566238af2893ca65b (patch) | |
tree | 5413a5ec890b5a1ac4fbbe4548b5014e41a2591b /tests/dlext_test.cpp | |
parent | dcdcb3fa15004669823a3a118189d9d72ff30852 (diff) | |
parent | ab08b955a34423d53b28a6210e7530e67241af4a (diff) |
Merge SP1A.200921.001
Change-Id: Id2ab019914bb555dadf52c46b8403c0d5fb3c20a
Diffstat (limited to 'tests/dlext_test.cpp')
-rw-r--r-- | tests/dlext_test.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/dlext_test.cpp b/tests/dlext_test.cpp index 4c4a1c3e8..01bf8ab51 100644 --- a/tests/dlext_test.cpp +++ b/tests/dlext_test.cpp @@ -1228,7 +1228,7 @@ TEST(dlext, ns_unload_between_namespaces_missing_symbol_indirect) { dlerror()); } -TEST(dlext, ns_greylist_enabled) { +TEST(dlext, ns_exempt_list_enabled) { ASSERT_TRUE(android_init_anonymous_namespace(g_core_shared_libs.c_str(), nullptr)); const std::string ns_search_path = GetTestlibRoot() + "/private_namespace_libs"; @@ -1237,7 +1237,7 @@ TEST(dlext, ns_greylist_enabled) { android_create_namespace("namespace", nullptr, ns_search_path.c_str(), - ANDROID_NAMESPACE_TYPE_ISOLATED | ANDROID_NAMESPACE_TYPE_GREYLIST_ENABLED, + ANDROID_NAMESPACE_TYPE_ISOLATED | ANDROID_NAMESPACE_TYPE_EXEMPT_LIST_ENABLED, nullptr, nullptr); @@ -1247,26 +1247,26 @@ TEST(dlext, ns_greylist_enabled) { extinfo.flags = ANDROID_DLEXT_USE_NAMESPACE; extinfo.library_namespace = ns; - // An app targeting M can open libnativehelper.so because it's on the greylist. + // An app targeting M can open libnativehelper.so because it's on the exempt-list. android_set_application_target_sdk_version(23); void* handle = android_dlopen_ext("libnativehelper.so", RTLD_NOW, &extinfo); ASSERT_TRUE(handle != nullptr) << dlerror(); - // Check that loader did not load another copy of libdl.so while loading greylisted library. + // Check that loader did not load another copy of libdl.so while loading exempted library. void* dlsym_ptr = dlsym(handle, "dlsym"); ASSERT_TRUE(dlsym_ptr != nullptr) << dlerror(); ASSERT_EQ(&dlsym, dlsym_ptr); dlclose(handle); - // An app targeting N no longer has the greylist. + // An app targeting N no longer has the exempt-list. android_set_application_target_sdk_version(24); handle = android_dlopen_ext("libnativehelper.so", RTLD_NOW, &extinfo); ASSERT_TRUE(handle == nullptr); ASSERT_STREQ("dlopen failed: library \"libnativehelper.so\" not found", dlerror()); } -TEST(dlext, ns_greylist_disabled_by_default) { +TEST(dlext, ns_exempt_list_disabled_by_default) { ASSERT_TRUE(android_init_anonymous_namespace(g_core_shared_libs.c_str(), nullptr)); const std::string ns_search_path = GetTestlibRoot() + "/private_namespace_libs"; |