通过js调用在小程序中访问智能卡密钥库

发布于 2024-12-06 16:34:36 字数 551 浏览 4 评论 0 原文

我正在尝试通过小程序通过 js 调用访问智能卡密钥库。
我正在寻找最佳实践,并希望有一个指导,注意安全问题。
我可以在其中做什么和不能做什么?
仅仅使用 doPrevileged 就足够了吗?
小程序在这些方面有哪些限制?
应该使用 JApplet 还是 Applet?

我确实需要一些指导。

我只有一个请求:我不想使用外部库。

谢谢

补充: 看起来,sun 文档解释说:

签名小程序

签名的小程序没有施加的安全限制 在未签名的小程序上,可以在安全沙箱之外运行。

注意:

JavaScript 代码被视为未签名代码。 小程序是通过 HTML 页面中的 JavaScript 代码访问的,小程序是 在安全沙箱内执行。这意味着签署的 小程序本质上的行为就像未签名的小程序。

但我遇到过其他小程序,尽管它们的方法是在 js 中调用的,但使用 JDialog 以便用户启动操作。

I am attempting to access the smartcard keystore, by an applet, through a js call.
I am searching for best pratices, and hopefully a guide, minding the security issues.
What I can and cannot do in it?
Just the use of doPrevileged is enough?
What are the limitations that an applet has in those matters?
Should use a JApplet or an Applet?

I really do need some directions.

I just have one request: I don't want to make use of outside libraries.

Thanks

Addendum:
as It seems, the sun documentation explains that:

Signed Applets

Signed applets do not have the security restrictions that are imposed
on unsigned applets and can run outside the security sandbox.

Note:

JavaScript code is treated like unsigned code. When a signed
applet is accessed from JavaScript code in an HTML page, the applet is
executed within the security sandbox. This implies that the signed
applet essentially behaves likes an unsigned applet.

But I have come to other applets that, although their methods are called in js, use JDialog so the user starts the action.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

得不到的就毁灭 2024-12-13 16:34:36

智能卡是一个宽泛的术语,即使使用所谓的加密卡(区别是智能卡可以托管应用程序,而加密卡仅提供固定的加密功能集)也可以。这里有一个关于此主题的新系列(虽然看起来只有两部分):http://rostislav-matl.blogspot.com/2011/09/using-smart-card-as-keystore-in-java.html

您可能会发现找到不太昂贵且多平台的解决方案并不容易。

Smartcard is a wide term, you will be fine even with so called cryptocard (the difference is smartcard can host applications while cryptocard provides only fixed set of cryptography functions). There is a new serie (looks it will have only two part though) about this topic here: http://rostislav-matl.blogspot.com/2011/09/using-smart-card-as-keystore-in-java.html .

You'll probably find that finding not too expensive and multiplatform solution is not easy.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文