< prev index next >

src/java.base/share/classes/java/lang/RuntimePermission.java

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this --- 1,7 ---- /* ! * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this
*** 24,36 **** */ package java.lang; import java.security.*; ! import java.util.Enumeration; ! import java.util.Hashtable; ! import java.util.StringTokenizer; /** * This class is for runtime permissions. A {@code RuntimePermission} * contains a name (also referred to as a "target name") but no actions * list; you either have the named permission or you don't. --- 24,34 ---- */ package java.lang; import java.security.*; ! import java.lang.module.ModuleFinder; /** * This class is for runtime permissions. A {@code RuntimePermission} * contains a name (also referred to as a "target name") but no actions * list; you either have the named permission or you don't.
*** 263,272 **** --- 261,280 ---- * trusted packages like <code>java.security</code> or <code>java.lang</code>, * for example.</td> * </tr> * * <tr> + * <td>defineClass</td> + * <td>Define a class with + * {@link java.lang.invoke.MethodHandles.Lookup#defineClass(byte[]) + * Lookup.defineClass}.</td> + * <td>This grants code with a suitably privileged {@code Lookup} object + * permission to define classes in the same package as the {@code Lookup}'s + * lookup class. </td> + * </tr> + * + * <tr> * <td>accessDeclaredMembers</td> * <td>Access to the declared members of a class</td> * <td>This grants code permission to query a class for its public, * protected, default (package) access, and private fields and/or * methods. Although the code would have
*** 357,366 **** --- 365,382 ---- * This permission ensures trust in classes which provide loggers * to system classes.</td> * <td>See {@link java.lang.System.LoggerFinder java.lang.System.LoggerFinder} * for more information.</td> * </tr> + * + * <tr> + * <td>accessSystemModules</td> + * <td>Access system modules in the runtime image.</td> + * <td>This grants the permission to access resources in the + * {@linkplain ModuleFinder#ofSystem system modules} in the runtime image.</td> + * </tr> + * * </table> * * @implNote * Implementations may define additional target names, but should use naming * conventions such as reverse domain name notation to avoid name clashes.
< prev index next >