#4773·hashcat

`sha256_hmac_init`: 如果 `len < 64`, 可能会读取未初始化的数据

作者: LukeSerne创建于 2026年8月12日更新于 2026年9月5日
标签bug

我找不到任何有关此问题的 GitHub 问题,也没在 FAQ 中提到过此问题。 **描述错误** 在编写使用 `sha256_hmac_init` 的自定义内核时,很容易得到错误的结果。这是因为即使 `sha256_hmac_init` 也接受了传入缓冲区的长度作为参数(`len`),但 `sha256_hmac_init` 的实现假定此 `len` 至少为 64 个字节。 **要重现此错误** 1. 编写一个自定义内核,其中包含以下代码片段:

内容来源: hashcat/hashcat