提交 82c6870e 编写于 作者: D denis

6887703: Unsigned applet can retrieve the dragged information before drop action occur

Reviewed-by: uta
上级 7081657d
......@@ -57,6 +57,7 @@ import sun.awt.AppContext;
import sun.awt.SunToolkit;
import sun.awt.datatransfer.DataTransferer;
import sun.awt.datatransfer.ToolkitThreadBlockedHandler;
import sun.security.util.SecurityConstants;
/**
* <p>
......@@ -216,6 +217,18 @@ public abstract class SunDropTargetContextPeer implements DropTargetContextPeer,
throws UnsupportedFlavorException, IOException,
InvalidDnDOperationException
{
SecurityManager sm = System.getSecurityManager();
try {
if (!dropComplete && sm != null) {
sm.checkSystemClipboardAccess();
}
} catch (Exception e) {
Thread currentThread = Thread.currentThread();
currentThread.getUncaughtExceptionHandler().uncaughtException(currentThread, e);
return null;
}
Long lFormat = null;
Transferable localTransferable = local;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册