--- old/src/hotspot/share/classfile/javaClasses.cpp 2018-10-31 16:55:36.899238023 -0700 +++ new/src/hotspot/share/classfile/javaClasses.cpp 2018-10-31 16:55:36.477219132 -0700 @@ -3786,12 +3786,6 @@ } #endif -bool java_security_AccessControlContext::is_authorized(Handle context) { - assert(context.not_null() && context->klass() == SystemDictionary::AccessControlContext_klass(), "Invalid type"); - assert(_isAuthorized_offset != -1, "should be set"); - return context->bool_field(_isAuthorized_offset) != 0; -} - oop java_security_AccessControlContext::create(objArrayHandle context, bool isPrivileged, Handle privileged_context, TRAPS) { assert(_isPrivileged_offset != 0, "offsets should have been initialized"); // Ensure klass is initialized @@ -3975,13 +3969,6 @@ int java_lang_System::out_offset_in_bytes() { return static_out_offset; } int java_lang_System::err_offset_in_bytes() { return static_err_offset; } - -bool java_lang_System::has_security_manager() { - InstanceKlass* ik = SystemDictionary::System_klass(); - oop base = ik->static_field_base_raw(); - return base->obj_field(static_security_offset) != NULL; -} - int java_lang_Class::_klass_offset; int java_lang_Class::_array_klass_offset; int java_lang_Class::_oop_size_offset; --- old/src/hotspot/share/classfile/javaClasses.hpp 2018-10-31 16:55:38.135293354 -0700 +++ new/src/hotspot/share/classfile/javaClasses.hpp 2018-10-31 16:55:37.722274865 -0700 @@ -1240,8 +1240,6 @@ static void serialize_offsets(SerializeClosure* f) NOT_CDS_RETURN; static oop create(objArrayHandle context, bool isPrivileged, Handle privileged_context, TRAPS); - static bool is_authorized(Handle context); - // Debugging/initialization friend class JavaClasses; }; @@ -1315,8 +1313,6 @@ static int out_offset_in_bytes(); static int err_offset_in_bytes(); - static bool has_security_manager(); - static void compute_offsets(); static void serialize_offsets(SerializeClosure* f) NOT_CDS_RETURN; --- old/src/hotspot/share/classfile/vmSymbols.hpp 2018-10-31 16:55:39.369348595 -0700 +++ new/src/hotspot/share/classfile/vmSymbols.hpp 2018-10-31 16:55:38.961330330 -0700 @@ -549,7 +549,6 @@ template(char_StringBuffer_signature, "(C)Ljava/lang/StringBuffer;") \ template(int_String_signature, "(I)Ljava/lang/String;") \ template(boolean_boolean_int_signature, "(ZZ)I") \ - template(codesource_permissioncollection_signature, "(Ljava/security/CodeSource;Ljava/security/PermissionCollection;)V") \ /* signature symbols needed by intrinsics */ \ VM_INTRINSICS_DO(VM_INTRINSIC_IGNORE, VM_SYMBOL_IGNORE, VM_SYMBOL_IGNORE, template, VM_ALIAS_IGNORE) \ \ --- old/src/hotspot/share/memory/universe.cpp 2018-10-31 16:55:40.669406790 -0700 +++ new/src/hotspot/share/memory/universe.cpp 2018-10-31 16:55:40.246387854 -0700 @@ -105,7 +105,6 @@ oop Universe::_the_min_jint_string = NULL; LatestMethodCache* Universe::_finalizer_register_cache = NULL; LatestMethodCache* Universe::_loader_addClass_cache = NULL; -LatestMethodCache* Universe::_pd_implies_cache = NULL; LatestMethodCache* Universe::_throw_illegal_access_error_cache = NULL; LatestMethodCache* Universe::_do_stack_walk_cache = NULL; oop Universe::_out_of_memory_error_java_heap = NULL; @@ -229,7 +228,6 @@ _finalizer_register_cache->metaspace_pointers_do(it); _loader_addClass_cache->metaspace_pointers_do(it); - _pd_implies_cache->metaspace_pointers_do(it); _throw_illegal_access_error_cache->metaspace_pointers_do(it); _do_stack_walk_cache->metaspace_pointers_do(it); } @@ -271,7 +269,6 @@ f->do_ptr((void**)&_the_empty_instance_klass_array); _finalizer_register_cache->serialize(f); _loader_addClass_cache->serialize(f); - _pd_implies_cache->serialize(f); _throw_illegal_access_error_cache->serialize(f); _do_stack_walk_cache->serialize(f); } @@ -680,7 +677,6 @@ // Metaspace::initialize_shared_spaces() tries to populate them. Universe::_finalizer_register_cache = new LatestMethodCache(); Universe::_loader_addClass_cache = new LatestMethodCache(); - Universe::_pd_implies_cache = new LatestMethodCache(); Universe::_throw_illegal_access_error_cache = new LatestMethodCache(); Universe::_do_stack_walk_cache = new LatestMethodCache(); @@ -934,12 +930,6 @@ "addClass", vmSymbols::class_void_signature(), false, CHECK); - // Set up method for checking protection domain - initialize_known_method(_pd_implies_cache, - SystemDictionary::ProtectionDomain_klass(), - "impliesCreateAccessControlContext", - vmSymbols::void_boolean_signature(), false, CHECK); - // Set up method for stack walking initialize_known_method(_do_stack_walk_cache, SystemDictionary::AbstractStackWalker_klass(), --- old/src/hotspot/share/memory/universe.hpp 2018-10-31 16:55:41.925463016 -0700 +++ new/src/hotspot/share/memory/universe.hpp 2018-10-31 16:55:41.525445110 -0700 @@ -137,7 +137,6 @@ static oop _the_min_jint_string; // A cache of "-2147483648" as a Java string static LatestMethodCache* _finalizer_register_cache; // static method for registering finalizable objects static LatestMethodCache* _loader_addClass_cache; // method for registering loaded classes in class loader vector - static LatestMethodCache* _pd_implies_cache; // method for checking protection domain attributes static LatestMethodCache* _throw_illegal_access_error_cache; // Unsafe.throwIllegalAccessError() method static LatestMethodCache* _do_stack_walk_cache; // method for stack walker callback @@ -322,7 +321,6 @@ static Method* finalizer_register_method() { return _finalizer_register_cache->get_method(); } static Method* loader_addClass_method() { return _loader_addClass_cache->get_method(); } - static Method* protection_domain_implies_method() { return _pd_implies_cache->get_method(); } static Method* throw_illegal_access_error() { return _throw_illegal_access_error_cache->get_method(); } static Method* do_stack_walk_method() { return _do_stack_walk_cache->get_method(); } --- old/test/hotspot/jtreg/runtime/JVMDoPrivileged/DoPrivRunAbstract.jasm 2018-10-31 16:55:43.246522152 -0700 +++ new/test/hotspot/jtreg/runtime/JVMDoPrivileged/DoPrivRunAbstract.jasm 2018-10-31 16:55:42.795501962 -0700 @@ -23,7 +23,7 @@ /* * @test - * @summary Test that JVM_DoPrivilege throws java.lang.AbstractMethodError for an + * @summary Test that AccessController.doPrivileged throws java.lang.AbstractMethodError for an * abstract run() method. * @bug 8183962 * @compile DoPrivRunAbstract.jasm --- old/test/hotspot/jtreg/runtime/JVMDoPrivileged/DoPrivileged.java 2018-10-31 16:55:44.541580124 -0700 +++ new/test/hotspot/jtreg/runtime/JVMDoPrivileged/DoPrivileged.java 2018-10-31 16:55:44.097560248 -0700 @@ -23,7 +23,7 @@ /* * @test - * @summary Test that JVM_DoPrivilege() searches default methods when looking + * @summary Test that AccessController.doPrivileged() searches default methods when looking * for the run() method. * @bug 8183962 * @run main DoPrivileged