ASP.Net 3.5 SP1 机器密钥自动解密算法

发布于 2024-07-13 17:58:27 字数 354 浏览 6 评论 0原文

我在理解 machinekey 上的文档时遇到一些困难。 当未设置解密属性时,使用什么算法来加密/解密表单身份验证票证。 我有:

<machineKey validationKey="128CharacterKey" decryptionKey="48CharacterKey" validation="3DES"/>

我发现一些文档说,如果没有专门设置解密属性,它将使用验证属性中的值。 我还发现有人说它会使用 SHA-1。 另一篇文章称这将基于解密密钥中值的大小。

它使用哪种算法?

顺便说一句,现在大多数人使用哪种算法:AES、3DES、SHA1 等?

I am having some trouble understanding the documentation on machinekey. What algorithm is being used to encrypt/decrypt the forms authentication ticket when the decryption attribute is not set. I have:

<machineKey validationKey="128CharacterKey" decryptionKey="48CharacterKey" validation="3DES"/>

I found some documentation saying that if the decryption attribute was not specifically set it would use the value in the validation attribute. I also found something saying it would use SHA-1. Yet another articles said it would be based on the size of the value in the decryptionKey.

Which algorithm is it using?

On a side note, which algorithm are most people using nowadays AES, 3DES, SHA1, etc?

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

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

发布评论

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

评论(2

微凉 2024-07-20 17:58:27

顺便说一句,现在大多数人使用哪种算法:AES、3DES、SHA1 等?

当然,新应用程序应该避免使用 3DES,而使用 AES 进行对称加密。 还应避免使用 SHA1,并至少使用 SHA-256 进行哈希处理。

默认值位于 MSDN 上: AES 和 SHA1(请参阅备注部分)。

On a side note, which algorithm are most people using nowadays AES, 3DES, SHA1, etc?

Certainly new applications should avoid 3DES in favour of AES for symmetric encryption. SHA1 should also be avoided, and use at least SHA-256 for hashing.

The defaults are on MSDN: AES and SHA1 (see Remarks section).

情魔剑神 2024-07-20 17:58:27

您需要阅读“使用 C# 和 VB 进行专业 ASP.NET 3.5 安全性、成员资格和角色管理”的第 6 章。 这里有一个到它的 Google Books 版本的链接,应该足够了...

如果您正在构建一个严肃的应用程序,那么它肯定是您想要修改的东西。

http://books.google.com/books? id=uAnOTcTR8l8C&pg=PA295&lpg=PA295PPA295,M1

You'll want to read Chapter 6 of "Professional ASP.NET 3.5 Security, Membership and Role Management with C# and VB". Here's a link to the Google Books version of it, which should suffice...

It's definetely something you'll want to modify if you're building a serious application.

http://books.google.com/books?id=uAnOTcTR8l8C&pg=PA295&lpg=PA295PPA295,M1

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