栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 面试经验 > 面试问答

Spring 3.0.5-java.awt.HeadlessException-com.trend.iwss.jscan

面试问答 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

Spring 3.0.5-java.awt.HeadlessException-com.trend.iwss.jscan

今天,我面临着类似的问题。我想分享我的研究,也许对某人会有帮助。

症状:

当您使用任何Java软件时,都会弹出“小程序警报”“小程序正在尝试…”,但是您知道您没有使用任何小程序。

如果您在弹出窗口中按“停止小程序”按钮或使用

Djava.awt.headless=true
或其他方式禁止弹出窗口,则您将在日志中看到类似

java.awt.HeadlessExceptionat java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:159)at java.awt.Window.<init>(Window.java:407)at java.awt.frame.<init>(frame.java:402)at java.awt.frame.<init>(frame.java:367)at com.trend.iwss.jscan.runtime.baseDialog.getActiveframe(baseDialog.java:75)at com.trend.iwss.jscan.runtime.AllowDialog.make(AllowDialog.java:32)at com.trend.iwss.jscan.runtime.PolicyRuntime.showAllowDialog(PolicyRuntime.java:325)at com.trend.iwss.jscan.runtime.PolicyRuntime.stopActionInner(PolicyRuntime.java:240)at com.trend.iwss.jscan.runtime.PolicyRuntime.stopAction(PolicyRuntime.java:172)at com.trend.iwss.jscan.runtime.PolicyRuntime.stopAction(PolicyRuntime.java:165)at com.trend.iwss.jscan.runtime.NetworkPolicyRuntime.checkURL(NetworkPolicyRuntime.java:284)at com.trend.iwss.jscan.runtime.NetworkPolicyRuntime._preFilter(NetworkPolicyRuntime.java:164)at com.trend.iwss.jscan.runtime.PolicyRuntime.preFilter(PolicyRuntime.java:132)at com.trend.iwss.jscan.runtime.NetworkPolicyRuntime.preFilter(NetworkPolicyRuntime.java:108)at org.springframework.core.io.support.PropertiesLoaderUtils.loadAllProperties(PropertiesLoaderUtils.java:108)...

要么

ActionServlet - Unable to initialize Struts ActionServlet due to an unexpected exception or error thrown, so marking the servlet as unavailable.  Most likely, this is due to an incorrect or missing library dependency. <com.trend.iwss.jscan.runtime.AppletTrapStopError: Applet disabled by IWSS Javascan site policy.>com.trend.iwss.jscan.runtime.AppletTrapStopError: Applet disabled by IWSS Javascan site policy.    at com.trend.iwss.jscan.runtime.PolicyRuntime.stopApplet(PolicyRuntime.java:300)    at com.trend.iwss.jscan.runtime.PolicyRuntime.stopActionInner(PolicyRuntime.java:254)    at com.trend.iwss.jscan.runtime.PolicyRuntime.stopAction(PolicyRuntime.java:172)    at com.trend.iwss.jscan.runtime.PolicyRuntime.stopAction(PolicyRuntime.java:165)    at com.trend.iwss.jscan.runtime.NetworkPolicyRuntime.checkURL(NetworkPolicyRuntime.java:284)    at com.trend.iwss.jscan.runtime.NetworkPolicyRuntime._preFilter(NetworkPolicyRuntime.java:164)    at com.trend.iwss.jscan.runtime.PolicyRuntime.preFilter(PolicyRuntime.java:132)    at com.trend.iwss.jscan.runtime.NetworkPolicyRuntime.preFilter(NetworkPolicyRuntime.java:108)    at org.apache.commons.digester.Digester.createInputSourceFromURL(Digester.java:1971)    ...

您可以看到弹出窗口是由

com.trend.iwss.jscan.runtime
包中的代码创建的。

原因:

您正在使用通过趋势科技网关讯息安全设备/设备代理从Internet下载的jar。该代理会钩住您从Internet下载的所有jar,因此当它们尝试访问文件时,您会看到“
Applet警报”弹出窗口。

您可以通过

com.trend.iwss.jscan.runtime
打包之前的最后一个堆栈跟踪入口来确定受影响的jar
。(在我的情况下,它
org.apache.commons.digester.Digester
来自commons-
digester.jar,在马什的情况下,它
org.springframework.core.io.support.PropertiesLoaderUtils
来自spring.jar)

解:

您有两种选择:

  • 您可以下载存档的jar文件。因此它们不会受到代理的影响。
  • 您可以配置代理不修改下载的jar文件。

趋势科技网站上的问题描述



转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/507783.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号