Live data from Hacker News

A Really Good Article on How Easy it Is to Crack Passwords

schneier.com

41–50 of 76 posts

Re: A Really Good Article on How Easy it Is to Crack Passwords

#41
post #20
post #17

Why not force the user to have strong login credentials? I'm creating an online system that will store users' sensitive financial data. When setting up an account, the user will have to choose a password as normal, but will also be given a passphrase of the form "correct horse battery staple" that they must write down . To log in, the user will need to enter (a) username; (b) password; and (c) passphrase. It is effec…

The passphrase looks to be very weak if it is just something like 4 english words. And fails on the convenience test.

Correct horse battery staple comes from https://xkcd.com/936/

Re: A Really Good Article on How Easy it Is to Crack Passwords

#42

Passwords are broken and I really wish we would all move away from them. Persona is a nice idea with regards to privacy and control, but it's still a password that you need to remember, which can be cracked. Also, people generally don't use strong passwords. What irks me is that every OS in use today has support for strong cryptography and browser vendors could easily integrate that. We would no longer register for a…

> What irks me is that every OS in use today has support for strong cryptography and browser vendors could easily integrate that. We would no longer register for a website, we would simply upload our "Online Identity" or whatever we called it. This of course is just an id_rsa.pub with maybe name and email in the comment. The remote site stores the public key and the browser authenticates using the private key, stored securely in the keychain.

Like SSL client certificates?

Re: A Really Good Article on How Easy it Is to Crack Passwords

#43
post #7

Earlier quoted context omitted.

bcrypt is not bad and you're definitely better off with that than with MD5, but scrypt performs better for these sort of things. There was an article on HN a week or so ago about this.

One of the problems of scrypt is a lack of language bindings. There's no officially blessed language binding for PHP, there's a ruby gem that only works on MRI but doesn't support jruby. Bcrypt on the other hand is widely supported, simple and easy to use implementations exist for devise and activerecord for example. I'd pick the slightly worse but widely supported algorithm and rather tune the work factor than being…

> there's a ruby gem that only works on MRI but doesn't support jruby

Works as well as any other MRI extension, which is to say pretty well:

    jruby-1.7.4 :001 > require 'scrypt'  
     => true   
    jruby-1.7.4 :002 > SCrypt::Password.create("bla")  
     => "400$8$2d$096ac4e8a120a4f9$d1e13bbfa387196d68f116d76ae23d0d3ffa39c891192a56832db0a1d8f6a8ec"
Yay for ffi.

Re: A Really Good Article on How Easy it Is to Crack Passwords

#44
post #24

Earlier quoted context omitted.

What makes you think he misunderstands it? For the cracker it's not about entropy per se, it's a game to come up with algorithms that crack more passwords for less compute power. The XKCD comic got a lot of mindshare so it makes sense to target algorithms towards that type of password. I think Schneier's suggestion of reducing it to the first letter of each word is vastly preferable because it packs the majority of e…

The algorithm is not targeted against the type of password which the XKCD comic suggests. The algorithm is designed to exploit common human behavior, which is similar to the XKCD method but not identical. The significant difference is that human behavior in picking words is not random, while the XKCD method requires the word selection process to be truly random. The "iloveyousomuch" example by Steube is unlikely to b…

Where are you guys getting this? All I read was this:

> Steube was able to crack "momof3g8kids" because he had "momof3g" in his 111 million dict and "8kids" in a smaller dict.

> "The combinator attack got it! It's cool," he said. Then referring to the oft-cited xkcd comic, he added: "This is an answer to the batteryhorsestaple thing."

It sounds to me like he's combining words randomly, not "exploiting common human behavior".

Re: A Really Good Article on How Easy it Is to Crack Passwords

#46
post #38

Earlier quoted context omitted.

I think you need to analyze the risks more specifically. You should rate-limit login attempts on the live site. Even allowing only one login attempt per second kills any brute-forcing attack if your passwords have even mediocre complexity. Password cracking is only really a threat is the bad guys get your database. And if they do, it's not much more difficult to crack two passwords than one. The point of true two-fac…

Yes you are right that it is not 'true' two-factor authentication. It would certainly be more secure if all my users were able and willing to use something like Google Authenticator. However, I suspect that most of my users (who are not especially computer literate) would prefer the simplicity of writing down 4 words over having to install and configure an two-factor app on their phone. You say, "it's not much more d…

Why not just require your users to set a 4-word passphrase as their password? You'll capture more variations than you would working from a fixed 5,000 word dictionary, and your users can still choose to write the words down if they want--or they can use the password management features of their browsers if they want. Plus it would be more simple to build and maintain, which is a plus when it comes to security.

Re: A Really Good Article on How Easy it Is to Crack Passwords

#47
post #43

Earlier quoted context omitted.

One of the problems of scrypt is a lack of language bindings. There's no officially blessed language binding for PHP, there's a ruby gem that only works on MRI but doesn't support jruby. Bcrypt on the other hand is widely supported, simple and easy to use implementations exist for devise and activerecord for example. I'd pick the slightly worse but widely supported algorithm and rather tune the work factor than being…

> there's a ruby gem that only works on MRI but doesn't support jruby Works as well as any other MRI extension, which is to say pretty well: jruby-1.7.4 :001 > require 'scrypt' => true jruby-1.7.4 :002 > SCrypt::Password.create("bla") => "400$8$2d$096ac4e8a120a4f9$d1e13bbfa387196d68f116d76ae23d0d3ffa39c891192a56832db0a1d8f6a8ec" Yay for ffi.

Well, C-Extension support in jruby is wonky at best. It works for some and doesn't for others and is sometimes scheduled to be removed. Granted, this one works, I stand corrected. There's a full java implementation for scrypt as well. However, my point still stands: There's no integration in devise, none in rails. No PHP implementation.

It's all fairly easy to change, but nobody has done so :)

Re: A Really Good Article on How Easy it Is to Crack Passwords

#48

Earlier quoted context omitted.

Just use bcrypt :-p

http://www.unlimitednovelty.com/2012/03/dont-use-bcrypt.html

That article was simply wrong. The chart at the top of it was added after it was pointed out that PBKDF2 is worse than bcrypt as a password hash, and the chart refutes the article.

Re: A Really Good Article on How Easy it Is to Crack Passwords

#49
post #43

Earlier quoted context omitted.

> there's a ruby gem that only works on MRI but doesn't support jruby Works as well as any other MRI extension, which is to say pretty well: jruby-1.7.4 :001 > require 'scrypt' => true jruby-1.7.4 :002 > SCrypt::Password.create("bla") => "400$8$2d$096ac4e8a120a4f9$d1e13bbfa387196d68f116d76ae23d0d3ffa39c891192a56832db0a1d8f6a8ec" Yay for ffi.

Well, C-Extension support in jruby is wonky at best. It works for some and doesn't for others and is sometimes scheduled to be removed. Granted, this one works, I stand corrected. There's a full java implementation for scrypt as well. However, my point still stands: There's no integration in devise, none in rails. No PHP implementation. It's all fairly easy to change, but nobody has done so :)

Devise: https://github.com/capita/devise-scrypt PHP: http://pecl.php.net/package/scrypt

So not quite "none", though granted being some random third party addon might as well be for many people (and possibly a good attitude to take for something security-critical).

Re: A Really Good Article on How Easy it Is to Crack Passwords

#50
post #49

Earlier quoted context omitted.

Well, C-Extension support in jruby is wonky at best. It works for some and doesn't for others and is sometimes scheduled to be removed. Granted, this one works, I stand corrected. There's a full java implementation for scrypt as well. However, my point still stands: There's no integration in devise, none in rails. No PHP implementation. It's all fairly easy to change, but nobody has done so :)

Devise: https://github.com/capita/devise-scrypt PHP: http://pecl.php.net/package/scrypt So not quite "none", though granted being some random third party addon might as well be for many people (and possibly a good attitude to take for something security-critical).

ok, my original statement regarding PHP was:

> There's no officially blessed language binding for PHP.

And judging from https://github.com/DomBlack/php-scrypt/issues/9 that's going to stay like that a while. There's a pure PHP implementation that falls back to the pecl package, so that's probably your best bet atm.

Post reply on HN