How do I use SecureString securely?

后端 未结 2 1678
暖寄归人
暖寄归人 2021-02-04 00:17

All of the examples I have seen end up converting a SecureString back to a standard string before using it, defeating the object. What\'s a good way of using a secure string wit

2条回答
  •  栀梦
    栀梦 (楼主)
    2021-02-04 00:35

    This link includes a lot of helpful information, including how to get an unmanaged memory block for passing the string to native code (that is presumably also secure), a BCL class that uses it, and links to a couple examples:

    http://bartdesmet.net/blogs/bart/archive/2006/03/31/3851.aspx

    The main thing is that it's not really used that much yet, but you are free to make your own libraries that rely on it.

提交回复
热议问题