用户输入的密码如何解锁TrueCrypt创建的主密钥?

发布于 2024-11-17 03:48:54 字数 572 浏览 5 评论 0原文

我是一名学生,试图了解开源加密软件的机制 http://www.truecrypt.org/ .在 TrueCrypt 中,有一个用户创建的密钥和/或密钥文件,以及一个程序生成的主密钥。我想要一个链接或更好的半技术解释,说明该用户创建的密码如何解锁头文件。我已阅读 TrueCrypt 文档 http://www.truecrypt.org/docs/? s=technical-details ,[我会发布更多内容,但新用户只允许两个链接],以及真正的 crypt 文档的其余部分。我想要一个关于密码如何解锁头文件的高级解释,以及作为侧边栏的盐如何帮助防止彩虹攻击。

很抱歉如此频繁地添加问题,但我意识到问题的核心是这样的。我想弄清楚如何更改密码。为此,我需要了解标头密钥与主密钥的关系,因为您可以更改标头密钥,但只有某些标头密钥可以与您的主密钥配合使用。标头密钥必须用于创建主密钥,但您可以选择任意密码来创建也可与主密钥一起使用的标头密钥。

I am a student attempting to understand the mechanisms of the Open Source cryptography software http://www.truecrypt.org/ . In TrueCrypt there is a user created key, and/or keyfile, as well as a program generated master key. I would like a link to or a better semi technical explanation of how this user created password unlocks the header file. I have read the TrueCrypt docs at http://www.truecrypt.org/docs/?s=technical-details , [I would post more but new users are only allowed two links] , and the rest of the true crypt documentation. I would like an explanation at a High level of how the password unlocks the header files, and as a sidebar, how the salt helps to prevent rainbow attacks.

Sorry for adding to the question so frequently, but I realize the main heart of the question is this. I am trying to figure out how the password is changeable. To do this, I need to understand how header key relates to the master key, because you can change the header key, yet only certain header key's will work with your master key. The header key must be used to create the master, yet you can choose an arbitrary password that will create a header key that will also work with the master key.

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

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

发布评论

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

评论(1

初见终念 2024-11-24 03:48:54

Truecrypt 获取您的密码并通过 PBKDF2 传递它。它类似于哈希函数,但需要更长的时间,并且速度更慢 - 以减慢暴力攻击。类似的密码推导算法有 bcrypt 和 scrypt。当涉及到“散列”密码时,这三个是“三大” - 任何其他密码,例如简单的 SHA-1 或 MD5 密码通常都太快而不够安全。攻击者可以非常快速地对 SHA-1 等简单哈希进行暴力攻击。 PBKDF2、bcrypt 和 scrypt 慢得多。

但是,理论上您可以使用所使用的参数(每个参数都有一些可选参数)针对 PBKDF2、bcrypt 和 scrypt 制作一个彩虹表。 Truecrypt 使用的盐就是为了防御这种情况而设计的。

http://www.truecrypt.org/docs/header-key-derivation是这方面的主要参考。

更具体地说,PBKDF2 和 salt 之后的标头密钥 == 是用户密钥吗?

我相信密码派生密钥用于解密包含主密钥的标头。这样,您只需使用新密码重新加密主密钥即可更改密码。

truecrypt.org/docs/?s=header-key-derivation 说盐未加密?将未加密的盐添加到彩虹表中并重试真的那么困难吗?

构建彩虹表很困难,我认为像暴力破解一样困难,但我不确定。但他们在同一个球场。因此,您正在考虑的威胁模型是“我应该加密我的盐!”并没有真正发挥作用。另外,您需要盐来导出密钥、解密块、获取盐。先有鸡还是先有蛋。

我不确定添加盐如何转化为“使用 512 位盐,这意味着每个密码有 2^512 个密钥。”

他们的意思是“password”的密码实际上有2^512个组合:password0000001、password0000002、password0000003等等。

Truecrypt takes your password and passes it through PBKDF2. It's like a hash function, but takes much longer, and is slower - to slow down brute force attacks. Similar password-derivation algorithms are bcrypt and scrypt. These three are the 'big three' when it comes to 'hashing' passwords - anything else, like a simple SHA-1 or MD5 of a password is generally too fast to be safe. Attackers can run brute force attacks against simple hashes like SHA-1 very quickly. PBKDF2, bcrypt, and scrypt are much slower.

But, theoretically you could make a rainbow table against PBKDF2, bcrypt, and scrypt with the parameters used (Each has some optional parameters). The salt Truecrypt uses is designed to defend against that.

http://www.truecrypt.org/docs/header-key-derivation is the main reference for this.

More specifically is the header key == to the user key after PBKDF2 and salt?

I believe the derived-from-password key is used to decrypt the header, which contains the master key. This way you can change your password just by re-encrypting the master key with a new password.

truecrypt.org/docs/?s=header-key-derivation says that the salt is unecrypted? Is it really that difficult to add the unencrypted salt to your rainbow table and try again?

Building a rainbow table is difficult, I think difficult as brute-forcing but I'm not sure. They're in the same ballpark though. So the threat model you're thinking of "I should encrypt my salt!" doesn't really come into play. Plus, you need the salt to derive the key, to decrypt the block, to get the salt. Chicken and the Egg.

I'm not sure how adding the salt translates to if "512-bit salt is used, which means there are 2^512 keys for each password."

They mean a password of "password" actually has 2^512 combinations: password0000001, password0000002, password0000003 and so on.

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