【问题标题】:My Deployment Rule set is ignored我的部署规则集被忽略
【发布时间】:2014-03-07 16:07:58
【问题描述】:

我正在尝试为某些内部应用程序配置部署规则集,但其中一个出现问题。

RuleSet.xml:

 <ruleset version="1.0+">
  <rule>
   <id location="machine1.domain.net" />
   <action permission="run" />
  </rule>
 <rule>
   <id />
    <action permission="block">
    <message>Blocked by corporate</message>
    </action>
 </rule>
</ruleset>

JNLP 文件:

  <title>Virtual KVM Client</title>
   <vendor>IBM</vendor>
   </information>

   <security>
   <all-permissions/>
   </security>

  <resources>
   <j2se version="1.6+ 1.5+ " />
   <jar href="/aessrp/avctIBMViewer.jar"/>
  </resources>

  <resources os="Windows">
   <nativelib href="/aessrp/avctKVMIOWin32.jar"/>
  </resources>

 <resources os="Linux">
   <nativelib href="/aessrp/avctKVMIOLinux.jar"/>
 </resources>

 <application-desc main-class="com.avocent.ibmc.kvm.Main">
  <argument>ip=machine1.donain.net</argument>
  <argument>helpurl=https://machine1.domain.net.net/aessrp /help/contents.html</argument>
  <argument>user=?????</argument>
  <argument>passwd=</argument>
   <argument>apcp=1</argument>
   <argument>version=2</argument>
   <argument>kmport=3900</argument>
   <argument>vport=3900</argument>
   <argument>title=machine1.domain.net-Video Viewer</argument>
 </application-desc>
</jnlp>

应用程序的 URL:

https://machine1.domain.net/

规则集文件对其他 URl“位置”工作正常,但是对于这个我总是会得到相同的错误 Blocked by corporate

你能看出这段代码有什么问题吗? Https 和 JNLP 文件有什么特殊含义吗?

【问题讨论】:

    标签: java java-web-start ria jnlp


    【解决方案1】:

    最后问题出在 JNLP 文件中,因为代码库 espcification 本身并没有引用 JNLP 文件位置。

    [http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/deployment_rules.html]

    没有 href 字段的 JNLP 文件将被忽略并应用默认规则。

    替代方案:

    使用 href 寻址 JNLP 文件本身创建 JNLP。

    创建没有代码库的 JNLP 文件,然后 JNLP 的名称将用作 href(未测试)。

    通过哈希证书进行过滤,更安全,但维护起来有点困难。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2023-03-25
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-12-11
      • 2013-04-09
      相关资源
      最近更新 更多