gpt4 book ai didi

c - RtlGenRandom/CryptGenRandom 或其他 WinAPI 以生成加密安全随机数(2018 年第一季度)

转载 作者:太空宇宙 更新时间:2023-11-04 05:49:07 33 4
gpt4 key购买 nike

<分区>

我发誓,每次我查看 MSDN 文档时,这似乎都在改变。当我编写可执行文件时,Microsoft 建议使用 RtlGenRandom用于生成加密强度高的随机数的 API。

现在,当我检查 RtlGenRandom 的文档时,那里的注释建议使用 CryptGenRandom反而。但是 CryptGenRandom 的另一个说明是这样的:

Important: This API is deprecated. New and existing software should start using Cryptography Next Generation APIs. Microsoft may remove this API in future releases.

那么有人可以用 C 语言举例说明如何使用那些“Cryptography Next Generation API”来生成 Microsoft 现在推荐的随机数字节数组吗?

33 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com