Rijndael in class library (package) not available for .NET Core

别说谁变了你拦得住时间么 提交于 2019-12-07 04:02:38

问题


Please help me. Where to find the Rijndael Security Cryptography in .NET Core?

What dependency I must to include in my class library (Package) project?


回答1:


The Rijndael implementation is not (yet) ported to .NET Core. You could use AES (which is a subset of Rijndael) using the System.Security.Cryptography.Algorithms package which targets netstandard1.3:

var aes = System.Security.Cryptography.Aes.Create();

Note: you should only add this package dependency to the netstandard1.3 TFM, as it exists in the core library of the full framework already:

"netstandard1.3": {
  "dependencies": {
    "System.Security.Cryptography.Algorithms": "4.2.0"
  }
}



回答2:


Have you looked in System.Security. You will need to add an assembly reference to this DLL.

System.Security.Cryptography.Rijndael x = System.Security.Cryptography.Rijndael.Create();

Check here:

MSDN



来源:https://stackoverflow.com/questions/35912849/rijndael-in-class-library-package-not-available-for-net-core

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!