TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: Why are usernames not secured like passwords?

6 点作者 buzzlightyear超过 10 年前
So we often hear about data breaches, but why are we not encrypting usernames and emails addresses alongside passwords? Is this just because it will require too much computing power and slow down login processes? I just think that a secure login, means a secure username along with a secure password??

5 条评论

ljoshua超过 10 年前
In a secure environment, your password will be hashed (not encrypted), meaning there&#x27;s only one way that the information can flow--toward the hash. This is secure because it allows for matching against the hash without actually knowing the original password.<p>However, usernames have to be displayed, shared, searched, etc. It could in theory be possible to encrypt this, but with the requirement that it be two way (so as to allow display), it is more trouble than it is worth, with minimal security gained. Most security researchers would probably also point out that if you are able to get to a point where you are dumping a database of user credentials and emails, you are probably also going to be able to retrieve the encryption key, rendering all of that encryption moot.
lmm超过 10 年前
If you don&#x27;t need an insecure thing, why bother with a username at all? Just have a secure password with appropriate requirements.<p>I&#x27;ve done similar things and it makes life hard. People need a way to refer to specific accounts, to talk about them, to troubleshoot. And for most sites your username is a public identifier, a way for other people to talk about you.<p>But look at the way AWS credentials work. They&#x27;re generated for you by the system, and no-one refers to someone else&#x27;s login. But they still, very deliberately, split your AWS key into a public part and a secret part. Because it&#x27;s very useful to have a public identity for a credential.
topherTopher超过 10 年前
Often the usernames and email addresses ARE secured, in that all the data at rest is encrypted. But passwords are additionally hashed so that even people with access to the data don&#x27;t know what your password is.
iSloth超过 10 年前
Usernames are an identity or alias that is typically public and matching over a number of services; to increase security you should look at two factor authentication, and not crudely obscuring the username.
chrisxcross超过 10 年前
Wirting an email to b63954c01ec5069d16b5bfc0cd7c2684317c195c63470ddc8826928beb21909b will get hard...