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.

Show HN: A simple “stateless” password manager for Chrome

40 pointsby stepstepover 10 years ago

15 comments

a1aover 10 years ago
Please tell me I am missing something. There is no salt. The hashing algorithm is hence vulnerable to a simple dictionary attack. It does not matter if you do a gigazillion rounds. Someone can still pre-calculate a list of common passwords and then test that list against each and every user.
评论 #8809224 未加载
评论 #8809202 未加载
评论 #8809200 未加载
评论 #8809390 未加载
kijinover 10 years ago
As usual, purity is overrated.<p>The #1 benefit of a purely stateless password manager is that there is no password database, so your password database cannot be compromised.<p>The drawback, as others have mentioned, is that it&#x27;s difficult to use strong salts without keeping some sort of database. Changing passwords also becomes a big hassle.<p>But what about a compromise? Keep a database, but only store the salts in the database. Generate the passwords on the fly using the master password and the domain-specific salt. Now you can have your cake and eat it too! If anyone steals your database, all they have is a bunch of salts. You probably won&#x27;t even have to keep it encrypted.<p>Keeping a database will also let you add some of the following features, which I consider essential to any modern password manager:<p>- Remember the username for each website. Some websites ask for my email address, others ask for a simple handle, and I shouldn&#x27;t have to remember which is which.<p>- Manage more than one account for the same domain, each with a different username.<p>- Change the password for only one website, without changing the master password, and without having to use a silly suffix. Just change the salt for that website. (This is one reason why it&#x27;s a bad idea to use the username as the salt. The salt should be random and easily changeable.)<p>- Remember password restrictions for each website. If your bank limits passwords to 12 characters, you can store this setting in the database and automatically truncate the hash to the desired length. If your school doesn&#x27;t allow special characters in the password, also remember this setting and skip non-alphanumeric characters from the auto-generated hash.<p>Until now, most of the features I listed above have only been possible with password databases. But if you think about it, there&#x27;s no reason not to go the hybrid route.
评论 #8813134 未加载
anton_gogolevover 10 years ago
Why do 2^16 rounds of a designed-to-be-fast SHA-256 when there are deliberately slow PBKDF, such as scrypt?
评论 #8809245 未加载
dannysuover 10 years ago
There are many of this type of hash function based generators, but pretty much all use fast hash functions. The no salt thing also makes me uneasy.<p>From another Ask HN[0], I learned about bpasswd[1] which does bcrypt and allows the cost (iterations) to be configured. That looks pretty cool.<p>For me, I chose to go with a hybrid approach and wrote hash0[2] for my less important passwords (important ones live in KeePass). Hash0 does 100,000 iterations of PBKDF2 with salt from CSPRNG unique for each site. It stores the encrypted metadata (just the salt, length, symbol&#x2F;no symbol, etc) at a location of your choosing (I just store it in my Google App Engine).<p>Would love to get more eyes on it and get feedback (See services.js for generation logic).<p>Benefits of hybrid are that:<p><pre><code> - Allows me to use random salt - Allows me to easily change password for individual sites (thanks for random salt) - Allows me to store website&#x27;s preferred password length and whether to use symbols or not - Allows me to create mappings (so say www.twitter.com and account.twitter.com can use the same password) - Allows me to store notes along with the metadata (e.g. what username I used) </code></pre> [0]: <a href="https://news.ycombinator.com/item?id=8753534" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=8753534</a><p>[1]: <a href="http://www.alexhornung.com/code/bpasswd/" rel="nofollow">http:&#x2F;&#x2F;www.alexhornung.com&#x2F;code&#x2F;bpasswd&#x2F;</a><p>[2]: <a href="https://github.com/dannysu/hash0" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;dannysu&#x2F;hash0</a>
jackjeffover 10 years ago
It needs to be improved to be secure<p>- salt. To avoid rainbow table attacks. One could use the login&#x2F;email as salt<p>- key strengthening function. Instead of repeating naively SHA-256 a few times, use PBDKF2 or even better, something which is also memory hard like scrypt.<p>Finally. What happens when the password requires to have upper case, symbols, x number of digits, min or max number of characters... If you think about it, some websites have conflicting requirements.
评论 #8809291 未加载
评论 #8809311 未加载
lqdc13over 10 years ago
Ok, the idea in general isn&#x27;t good because most people won&#x27;t use a good password and also because now there&#x27;s a single point of failure if someone sees your password.<p>However, it might be okay if one can provide their own hashing function. Like a JS function that takes the domain and secret key as parameters.
评论 #8809166 未加载
评论 #8809167 未加载
评论 #8809266 未加载
prohorover 10 years ago
Existing extensions for FF and Chrome using the same idea ; both use the same algorithm so you can share passwords:<p>Firefox: <a href="https://addons.mozilla.org/pl/firefox/addon/password-hasher/" rel="nofollow">https:&#x2F;&#x2F;addons.mozilla.org&#x2F;pl&#x2F;firefox&#x2F;addon&#x2F;password-hasher&#x2F;</a><p>Chrome: <a href="https://chrome.google.com/webstore/detail/pawhash/adgekjfphhgngpdoklolpjenmgneobfg?hl=en-US" rel="nofollow">https:&#x2F;&#x2F;chrome.google.com&#x2F;webstore&#x2F;detail&#x2F;pawhash&#x2F;adgekjfphh...</a>
SwellJoeover 10 years ago
I&#x27;ve been using SuperGenPass for this for years. There is a Chrome extension that is safe (from website snooping of your key) and a browser bookmarklet that is not safe. But, I just use the mobile browser version in another tab and copy paste since I choose to use Firefox. It&#x27;s a little less convenient, but not inconvenient enough that I&#x27;ve spent time trying to figure out how to make a safe extension for Firefox.<p>So, what&#x27;s different about this from the SuperGenPass session Chrome plugin?
评论 #8809313 未加载
laurent123456over 10 years ago
It&#x27;s an interesting idea, but is it really usable? If you ever need to change the master key, you&#x27;ll have to update all the websites you are using, and you won&#x27;t even know on which websites you used the password manager with since there is no database. I just don&#x27;t see how I could ever want this. Or is it assumed that master keys never need to be changed?
评论 #8809304 未加载
MiWDesktopHackover 10 years ago
Use slower &#x2F; heavier hash -- PBKDF2 or better. For lulz use something like Darkcoin Cryptocurrency &#x27;X11&#x27; Proof of Work function - multiple rounds of 11 different hashes. Or more. (X13, X15 and X17 all exist as PoW functions in CryptoCurrencies today).<p>A &lt;$1000 bitcoin (SHA-256) mining ASIC appliance is likely to be doing 1TH&#x2F;s. Makes 2^16 rounds look kinda weak.
评论 #8809214 未加载
dchestover 10 years ago
Here&#x27;s a short analysis of such password generators: <a href="http://crypto.stackexchange.com/a/5691/291" rel="nofollow">http:&#x2F;&#x2F;crypto.stackexchange.com&#x2F;a&#x2F;5691&#x2F;291</a>
moeover 10 years ago
This is why beginners should not design crypto, much less encourage others to use their creations...<p>Do not use this, it&#x27;s a textbook example of how to <i>not</i> do it.
评论 #8809235 未加载
评论 #8809231 未加载
hrvbrover 10 years ago
<a href="http://passwordmaker.org" rel="nofollow">http:&#x2F;&#x2F;passwordmaker.org</a> does the same thing and already has extensions for all browsers.
rnbradyover 10 years ago
This is awesome. Minimal and elegant.
dsegoover 10 years ago
Similar <a href="https://getvau.lt" rel="nofollow">https:&#x2F;&#x2F;getvau.lt</a>