|
KeyboardFocusManager
for
* a particular thread.
* <td>When SecurityManager
is installed, the invoking
* thread must be granted this permission in order to replace
* the current <code>KeyboardFocusManager. If permission
* is not granted, a <code>SecurityException will be thrown.
* </tr>
*
* <tr>
* <td>setAppletStub
* <td>Setting the stub which implements Applet container services
* <td>Malicious code could set an applet's stub and result in unexpected
* behavior or denial of service to an applet.</td>
* </tr>
*
* <tr>
* <td>setWindowAlwaysOnTop
* <td>Setting always-on-top property of the window: {@link Window#setAlwaysOnTop}
* <td>The malicious window might make itself look and behave like a real full desktop, so that
* information entered by the unsuspecting user is captured and subsequently misused </td>
* </tr>
*
* <tr>
* <td>showWindowWithoutWarningBanner
* <td>Display of a window without also displaying a banner warning
* that the window was created by an applet</td>
* <td>Without this warning,
* an applet may pop up windows without the user knowing that they
* belong to an applet. Since users may make security-sensitive
* decisions based on whether or not the window belongs to an applet
* (entering a username and password into a dialog box, for example),
* disabling this warning banner may allow applets to trick the user
* into entering such information.</td>
* </tr>
*
* <tr>
* <td>toolkitModality
* <td>Creating {@link Dialog.ModalityType#TOOLKIT_MODAL TOOLKIT_MODAL} dialogs
* and setting the {@link Dialog.ModalExclusionType#TOOLKIT_EXCLUDE
* TOOLKIT_EXCLUDE} window property.</td>
* <td>When a toolkit-modal dialog is shown from an applet, it blocks all other
* applets in the browser. When launching applications from Java Web Start,
* its windows (such as the security dialog) may also be blocked by toolkit-modal
* dialogs, shown from these applications.</td>
* </tr>
*
* <tr>
* <td>watchMousePointer
* <td>Getting the information about the mouse pointer position at any
* time</td>
* <td>Constantly watching the mouse pointer,
* an applet can make guesses about what the user is doing, i.e. moving
* the mouse to the lower left corner of the screen most likely means that
* the user is about to launch an application. If a virtual keypad is used
* so that keyboard is emulated using the mouse, an applet may guess what
* is being typed.</td>
* </tr>
* </table>
*
* @see java.security.BasicPermission
* @see java.security.Permission
* @see java.security.Permissions
* @see java.security.PermissionCollection
* @see java.lang.SecurityManager
*
*
* @author Marianne Mueller
* @author Roland Schemers
*/
public final class AWTPermission extends BasicPermission {
/** use serialVersionUID from the Java 2 platform for interoperability */
private static final long serialVersionUID = 8890392402588814465L;
/**
* Creates a new <code>AWTPermission with the specified name.
* The name is the symbolic name of the <code>AWTPermission,
* such as "topLevelWindow", "systemClipboard", etc. An asterisk
* may be used to indicate all AWT permissions.
*
* @param name the name of the AWTPermission
*
* @throws NullPointerException if <code>name is null
.
* @throws IllegalArgumentException if <code>name is empty.
*/
public AWTPermission(String name)
{
super(name);
}
/**
* Creates a new <code>AWTPermission object with the specified name.
* The name is the symbolic name of the <code>AWTPermission, and the
* actions string is currently unused and should be <code>null.
*
* @param name the name of the <code>AWTPermission
* @param actions should be <code>null
*
* @throws NullPointerException if <code>name is null
.
* @throws IllegalArgumentException if <code>name is empty.
*/
public AWTPermission(String name, String actions)
{
super(name, actions);
}
}
Here is a short list of links related to this Java AWTPermission.java source code file:
Java example source code file (AWTPermission.java)
The AWTPermission.java Java example source code/* * Copyright (c) 1997, 2013, 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 * particular file as subject to the "Classpath" exception as provided * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ package java.awt; import java.security.BasicPermission; /** * This class is for AWT permissions. * An <code>AWTPermission contains a target name but * no actions list; you either have the named permission * or you don't. * * <P> * The target name is the name of the AWT permission (see below). The naming * convention follows the hierarchical property naming convention. * Also, an asterisk could be used to represent all AWT permissions. * * <P> * The following table lists all the possible <code>AWTPermission * target names, and for each provides a description of what the * permission allows and a discussion of the risks of granting code * the permission. * * <table border=1 cellpadding=5 summary="AWTPermission target names, descriptions, and associated risks."> * <tr> * <th>Permission Target Name * <th>What the Permission Allows * <th>Risks of Allowing this Permission * </tr> * * <tr> * <td>accessClipboard |
... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.