.net - 保护 WPF 应用程序配置设置的最佳实践是什么?
我知道这是一个比首选问题更主观的问题,但我想不出更好的地方或方式来提出这个问题。
我正在开发一个 WPF 应用程序,并且在 App.config 文件中有配置设置。其中一些设置是敏感信息,最好计算机的用户无法直接访问它们(这些设置将在安装或管理员配置期间设置)。
保护 WPF 桌面应用程序的应用程序配置设置的最佳方法是什么?
感谢您的任何帮助。
I am aware that this is a more subjective question than is preferred, but I couldn't think of a better place or way to ask it.
I am developing a WPF application, and I have configuration settings in an App.config file. Some of these settings are sensitive information, and it would be best if the users of the machine could not directly access them (the settings would be set during install or administrator configuration).
What is the best way to protect application configuration settings for a WPF desktop application?
Thanks for any help.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这个问题与WPF本身无关。
.Net 提供了多种加密方法。
对于密码,您确实应该研究像 BCrypt 这样的单向哈希。然后,当您进行身份验证时,您只需对用户输入的内容进行散列(确保也使用盐),然后查看它是否散列到相同的内容。
对于网址等,我建议您查看这个问题。
您可能还会发现此问题与您的问题类似
This question has nothing to do with WPF per se.
.Net offers a wide load of encryption methods.
For passwords, you should really look into one way hash like BCrypt. Then when you authenticate you just hash (make sure you use a salt as well) what the user entered and see if it hashes to the same thing.
For URLs etc I would suggest you check out this question.
You might also find this question similar to yours