如何将新密码安全地发送到服务器
我的客户端代码调用 REST WCF 服务来更改密码。我定义了changePassword,将“UriTemplate”设置为“?user={userName}&oldPwd={oldHashPwd}&newPwd={newEncryptPwd}”
我的问题是:如何在客户端加密新密码,以便我们能够成功在服务器端解密?请具体说明。谢谢。
My client-side code calls the REST WCF service for changing passwords. I defined changePassword with "UriTemplate" set to "?user={userName}&oldPwd={oldHashPwd}&newPwd={newEncryptPwd}"
My question is: how to encrypt the new password on the client side so that we can successfully decrypt it on the server side ? Please be specific. Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
使用HTTPS。如果整个通信都是加密的,您甚至不需要单独加密/解密密码。
Use HTTPS. If the whole communication is encrypted, you won't even need to encrypt/decrypt the password individually.
除了 HTTPS 之外,您还可以在客户端使用安全的加盐密码哈希。这意味着即使拦截 URL 也是安全的 - 拥有哈希值将允许有效的“所有权证明”,但不能发现密码。
Beyond HTTPS, you could use a secure, salted password hash on the client side. That would mean even interception of the URL would be safe - having the hash would allow efficient "proof of ownership", but not discovery of the password.
银芳。您无需担心从客户端加密您的密码,该密码只能在服务器端解密。如今,您可以通过多种渠道来保护您的个人数据(例如密码)。一种方法是检查您是否使用“HTTPS”进行浏览,因为它将为您提供安全通道,将信息从一个地方发送到另一个地方。
另一方面,您可以获得 VPN 连接。通过它,您的所有信息都会被加密,并提供安全通道将您的个人敏感数据从客户端传递到服务器。市场上有很多 VPN 连接提供商,如 PureVPN、Hidemyass、switchvpn 等。如果您希望所有信息加密且安全,您可以使用这些有用的信息。
Yinfang. You don't need to be worry to encrypt your password from client side that would only be decrypted on the server side. Now a days, there are so many channels through which you can protect you personal data like your passwords. One way is to check that whether yo use "HTTPS" for your browsing because it will provide you secure channel to send you information from one place to another.
On the other hand you can get VPN connection. Through which all of your information gets encrypted and provided secure channel to pass your personal sensitive data from client side to server. There are so many providers of VPN connection are available in the market like PureVPN, Hidemyass,switchvpn etc etc. If you want all of your information encrypted ans secure you can use these useful information.
希望这能有所帮助。我使用
Rijndael
来加密数据
示例代码在这里:
加密
您可以在后端创建逻辑并供客户端用于加密和解密数据。
Hope this could help. I use to encrypt data using
Rijndael
Sample code here:
Cryptography
You can create logic on backend side and be used by the client side for encrypting and decrypting data.
您有 2 个选项可以选择“https”或“VPN/代理”。在加密网络上的任何内容时,通过“https”不会造成太大影响。我将为您提供畅通无阻的上网方式并做您想做的事情。但重点是,如果您想要获得的不仅仅是加密,那么您应该尝试 VPN/代理。如果你可以谷歌一下,你会发现代理并没有那么安全。然而,通过VPN与代理完全相反。 VPN 是用户可以为自己的网络提供的最好、最可靠的功能之一。 VPN 绝对匿名化个人身份,并允许本地 ISP 浏览(加密/解密)用户数据,而不会受到黑客的任何威胁。
You have 2 options to go with either "https" or "VPN/Proxy". Going through 'https' won't hazel much while encrypting anything on the web. I will give you smooth path to surf the web and do whatever you want. But the point is that if you are looking to get something more than just encryption then you should try VPN/Proxy. If you can google around then you will find that proxy is not that much safer. However, going through VPN is completely opposite to proxy. VPN is one of the best and most reliable feature that a user can have for their web. VPN absolutely anonymize one's identity and allow the local ISP to surf (encrypt/decrypt) user data with out any threats from hackers.