TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Ask HN: Why are usernames not secured like passwords?

6 pointsby buzzlightyearover 10 years ago
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 comments

ljoshuaover 10 years ago
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.
lmmover 10 years ago
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.
topherTopherover 10 years ago
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.
iSlothover 10 years ago
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.
chrisxcrossover 10 years ago
Wirting an email to b63954c01ec5069d16b5bfc0cd7c2684317c195c63470ddc8826928beb21909b will get hard...