问题标签 [security-policy]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
javascript - IE10 with disabled JS executes manually entered `onmousedown`
In IE10 I've disabled JS execution by setting maximum security level (IE11 also affected).
Then I add or edit onmousedown
attribute on any element on any site (for example, body
element on www.google.com
).
And so I get an alert when clicking anywhere.
Is it expected behavior or bug?
glassfish - Why would Glassfish generate an incomplete granted.policy file?
Version: GlassFish Server 3.1.2.2 (build 5)
I have an EAR
project which contains a WAR
and a single EAR
.
In the META-INF
folder of the EAR, I have a sun-application.xml
file which maps a selection of roles to groups.
In the default file realm for Glassfish
, I have configured users which map to these groups.
I am not using Default Role to Mapping and I have not actived the Security Manager.
Access works perfectly. This is further proven by removing the deployment descriptor, which causes an Authorization exception when trying to log in without it.
However when trying to access a seemingly random (but consistent) selection of my EJBs, I am greated with the infamous Glassfish "javax.ejb.AccessLocalException: Client not authorized for this invocation
" exception.
I have tried to delete my generated Policy files and redeploy the server, but this does not work.
When I look into the Policy file for my EJB, straight away I notice that the afflicted EJB grants are missing.
It would appear that one or two roles per group as defined in the sun-application.xml file are being missed.
Why would Glassfish fail to generate a complete policy file from a (proven) working sun-application.xml
and (proven) set of @RolesAllowed
definitions?
Here's the deployment descriptor:
For some reason, the roles ResolveGroup1
and ViewAllData
are missing from the EJB granted.policy file, despite appearing in a couple of EJBs:
java - RMI 无法连接到远程服务器
我最近一直在使用 RMI,虽然我设法让它在 locahost 上工作,但在尝试使用远程服务器时遇到了各种各样的问题。这是我要运行的基本代码:
服务器:
远程类接口:
客户:
rmi.policy 文件:
我编译了这些类并为服务器创建了一个存根。然后我将客户端、存根、接口和策略放在我的机器上,将服务器、存根、接口和策略放在远程机器上。远程服务器是一台 Linux 机器,我使所有文件都可执行。我还在本地防火墙上添加了一条允许端口 1099 的规则,并打开了远程机器上的所有端口
在此之后,我导航到远程机器上的服务器目录并插入以下命令:
这没有给我带来问题,所以我回到本地机器并输入
我等待,等待,我收到错误消息:
我昨天整天都在与这些连接错误作斗争,这就是我所得到的。我确信只有一件非常小的事情我仍然做错了,但我就是找不到它是什么。
security - 由于跨域策略导致的黑客攻击?
某些浏览器(如 Chrome 和 Safari)不允许跨域请求,因为用户必须遵守同源安全策略。但允许这样做的真正风险是什么?我的意思是,如果没有同源安全策略,黑客能够进行什么样的攻击?
java - 您需要什么 java 策略来允许 Class.getResource("name")
我正在尝试调用以下内容:
但是,当我打开以下 java 安全策略时,它会失败(返回 null)。我找不到我必须更改的内容才能使其正常工作?
java - 使用主机名而不是 IP 地址实施 java 安全策略?
我目前必须执行以下操作以允许在我们的 java 安全策略中发送邮件。
但是 IP 地址会不时更改,如果有人添加新的 smtp 服务器,我需要确保我们的应用程序不会中断。
是否可以妥协以允许基于主机名而不是 IP 地址的连接?
java - 下载小程序时 Java.net.SocketPermission 错误的含义
在远程客户端上下载小程序时,我看到 Sun Java 控制台中显示以下错误消息:
小程序正确加载。从托管小程序的服务器加载时,不会出现此错误。有谁知道这意味着什么?我需要担心吗?
java - Java RMI 不适用于多个服务器 - 安全
我在 ubuntu 服务器上使用 RMI 在 java 中开发了一个代码。当 RMI 客户端和服务器位于同一台机器上时,它运行良好。当我使用两台机器(一台作为服务器,另一台作为客户端 - 都是 ubuntu)时,它给了我“RMI 连接被拒绝异常”。为了解决这个问题,我尝试使用以下代码覆盖 java 策略文件:
我也在服务器端使用了类似的代码。
客户端和服务器策略文件的内容如下:
现在,我在上面显示的“System.setProperty(....)”行上的客户端出现以下异常。
我不是 java 或 ubuntu 方面的专家,但有人可以帮我解决上述问题吗?
-拉什米
weblogic - 如何在 weblogic 中指定 Web 服务客户端安全策略?
我正在构建一个部署在 Weblogic 12c 中的 Web 服务客户端,作为 Web 应用程序的一部分。我尝试使用的 Web 服务具有以下安全策略:
- wss11_saml_or_username_token_with_message_protection_service_policy
正如我在这里所读到的,在这种情况下,Web 服务客户端必须使用以下两种策略之一:
- oracle/wss11_saml_token_with_message_protection_client_policy
- oracle/wss11_username_token_with_message_protection_client_policy
到目前为止,我已经在我的 weblogic 服务器的信任密钥库中下载并安装了证书链中的所有证书。我使用 Netbeans 生成了一个 Web 服务客户端(使用 JAX-WS RI 2.2.6-1b01)。我设置用户名和密码如下:
我调用了其中一个 Web 服务操作。
不幸的是,在尝试使用 SAML 凭据时,我在运行时遇到涉及 NullPointerException 的错误。这是服务器日志:
我假设 weblogic 正在尝试使用策略“oracle/wss11_saml_token_with_message_protection_client_policy”而不是“oracle/wss11_username_token_with_message_protection_client_policy”来使用 Web 服务。
我已经能够使用 SoapUI、独立客户端和部署在 Apache Tomcat 中的相同战争应用程序成功使用 Web 服务。
我想保持 Web 服务客户端逻辑尽可能简单,即使用基本身份验证发送用户名和密码,而不使用映射凭据提供程序 o saml。
如果您有任何可以帮助我的想法或建议,请告诉我。
spring - 请求不包含安全头,但它是一个错误 CXF STS 服务客户端错误
我收到如下错误:
我在https://github.com/sampleref/CXFSecurity有一些完整的例子 请建议一些输入,因为这对我很重要。也可以在CXF STS 客户端抛出请求不包含安全标头/响应消息不包含 WS-Addressing 属性中找到完整的详细信息
谢谢