通过网络处理密码验证 [英] Handling Password Authentication over a Network

查看:58
本文介绍了通过网络处理密码验证的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在写一个游戏,要求用户登录他们的帐户才能玩.从客户端到服务器传输密码并存储密码的最佳方法是什么?

I'm writing a game which requires users to log in to their accounts in order to be able to play. What's the best way of transmitting passwords from client to server and storing them?

如果有任何相关性,我正在使用Python和Twisted.

I'm using Python and Twisted, if that's of any relevance.

推荐答案

最好的方法是通过SSL/TLS进行身份验证.最好的存储密码的方法是用一些复杂的哈希(例如,带有盐的sha1(sha1(password)+ salt))加盐对哈希进行哈希存储.

The best way is to authenticate via SSL/TLS. The best way of storing passwords is to store them hashed with some complex hash like sha1(sha1(password)+salt) with salt.

这篇关于通过网络处理密码验证的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆