.NET: Difference between PasswordDeriveBytes and Rfc2898DeriveBytes

前端 未结 4 1250
时光说笑
时光说笑 2021-02-08 09:32

I\'m trying to understand some C#-code, I have been handed, which deals with cryptography, and specifically uses PasswordDeriveBytes from System.Security.Cryp

4条回答
  •  南旧
    南旧 (楼主)
    2021-02-08 10:13

    PKCS#5 v2.0 defines both PBKDF1 and PBKDF2, the former for reasons of backwards compatibility and also recommends you use PBKDF2 for new applications. I've no idea why the latter is better than the former, but the two .NET classes do seem to use different but interoperable algorithms. (Possibly because only the resulting key is being exchanged, not the inputs + KDF.)

提交回复
热议问题