0

私は単純な HelloWorld アプレットを持っています。それを HTML に埋め込んでいます。うまくいきました。しかし、アプレットを jar に入れて jar に署名しましたが、「自己署名付き jar はサポートできません」と表示されてロードされず、ICA 発行の証明書を使用して署名しています。さらに、1.7.51 バージョンより前は、この問題に直面したことはありませんでした。ところで:パラメータの追加についてOracleドキュメントを調べました

それによると、署名された MANIFEST.MF に次の属性を追加しようとしました: Permissions: サンドボックス、Trusted-Library: true しかし、これも役に立ちませんでした。何かが欠けているかどうかわかりません。

マニフェストは次のようになります。

Manifest-Version: 1.0
Trusted-Library: true
Permissions: all-permissions
Application-Library-Allowable-Codebase: *
Caller-Allowable-Codebase: *
Codebase: *

Created-By: 1.7.0_45 (Oracle Corporation)

Name: HelloWorld$1.class
SHA1-Digest: xcxzcbxzcbxzcbxzcb=

Name: HelloWorld.class
SHA1-Digest: xaadfasfdasdfsafd=

コンソール ログの追加:

com.sun.deploy.security.BlockedException: Your security settings have blocked a self-signed application from running
    at com.sun.deploy.security.SandboxSecurity.showBlockedDialog(Unknown Source)
    at com.sun.deploy.security.TrustDecider.askUser(Unknown Source)
    at com.sun.deploy.security.TrustDecider.validateChain(Unknown Source)
    at com.sun.deploy.security.TrustDecider.isAllPermissionGranted(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.isTrustedByTrustDecider(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.getTrustedCodeSources(Unknown Source)
    at com.sun.deploy.security.CPCallbackHandler$ParentCallback.strategy(Unknown Source)
    at com.sun.deploy.security.CPCallbackHandler$ParentCallback.openClassPathElement(Unknown Source)
    at com.sun.deploy.security.DeployURLClassPath$JarLoader.getJarFile(Unknown Source)
    at com.sun.deploy.security.DeployURLClassPath$JarLoader.access$1000(Unknown Source)
    at com.sun.deploy.security.DeployURLClassPath$JarLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sun.deploy.security.DeployURLClassPath$JarLoader.ensureOpen(Unknown Source)

ここに画像の説明を入力 ありがとう。日

4

2 に答える 2

0

Trusted-Library エントリは、Java 1.7.45 より前にのみ関連します。そのため、その質問に記載されているパラメーターを追加する必要があります。

于 2014-05-07T13:38:25.633 に答える
0

さて、私はこれに対する解決策を見つけました:

以下の3点を確認してください。

1) Certificate has valid chain upto root and CA/ICA are public root.
2) Manifest.MF must have 2 attributes.
  • コードベース: < jar をデプロイする場所/ホスト名>
  • 権限: 2 つの値のいずれか (サンドボックスまたはすべての権限)

詳細はこちらをご覧ください。

于 2014-05-13T11:51:04.833 に答える