【问题标题】:How to make Ubuntu's crypt(3) support Blowfish?如何让 Ubuntu 的 crypt(3) 支持 Blowfish?
【发布时间】:2014-09-18 20:09:10
【问题描述】:

根据crypt(3) 手册,Blowfish(由 $2a$ 前缀表示)是受支持的密码方法之一:

ID  | Method
─────────────────────────────────────────────────────────
1   | MD5
2a  | Blowfish (not in mainline glibc; added in some
    | Linux distributions)
5   | SHA-256 (since glibc 2.7)
6   | SHA-512 (since glibc 2.7)

但是,Blowfish(不在主线 glibc 中;在某些 Linux 发行版中添加) 部分令人困惑且文档不足,所以我有几个问题。

首先,如果“主线”glibc 不支持 Blowfish,那么哪个 glibc 支持? Ubuntu 14.04 使用 glibc 2.19,打包在 libc6 / libc6-dev 包中。假设这是“主线”glibc,则不支持 Blowfish。显然有一个名为 crypt_blowfish 的补丁将 Blowfish 支持添加到 glibc。为什么在 Ubuntu 中默认不启用它?最后但同样重要的是,让 Ubuntu 中的 C crypt() 函数理解 Blowfish 哈希的最简单方法是什么?

【问题讨论】:

    标签: encryption glibc password-encryption blowfish crypt


    【解决方案1】:

    首先,如果“主线”glibc 不支持 Blowfish,那么哪个 glibc 支持?

    由 openwall 页面上列出的发行版构建,例如ALT Linux 和 SUSE。 如果你感兴趣,为什么不在主线,你可以阅读Ulrich Drepper's article

    为什么在 Ubuntu 中默认不启用?

    这里讨论过这个问题:LP#1349252

    最后但同样重要的是,让 Ubuntu 中的 C crypt() 函数理解 Blowfish 哈希的最简单方法是什么?

    可能,如果不构建自己的 glibc 包,就无法实现。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2012-08-10
      • 2014-12-16
      • 2015-11-14
      • 2012-04-07
      • 1970-01-01
      • 2014-06-27
      • 2015-12-10
      • 1970-01-01
      相关资源
      最近更新 更多