News for hackers. Stuff that matters.
Re:MtGox account database leaked by drivebyacct2 on Sunday June 19, 2011 @05:12PM (#2671915)
Who wants to team up and replace MtGox?

This is absurd. Anyone with a clue about anything knows better than to use unsalted MD5 or better yet, can imagine better ways to partition security for a system to prevent this, and at the very least can implement measures to prevent mass withdrawl without having to revert to transactional rollback after the fact.

Really sad. Was MtGox first? Why did they have so much volume anyway?

Re:MtGox account database leaked by llambda on Sunday June 19, 2011 @05:30PM (#2671959)
There's still Trade Hill[0] I guess... Although it would be fun.

Edit: And perhaps a good chance to use bcrypt over say MD5 or SHA256. I'm surprised bcrypt wasn't the go-to implementation.

[0] https://tradehill.com/

Re:MtGox account database leaked by Ixiaus on Sunday June 19, 2011 @05:41PM (#2671986)
You would be surprised how few developers know about bcrypt. I didn't learn about it till the Gawker attacks and all of the amazing threads by the tptacek and the other crypto guys that wouldn't stop saying "use bcrypt!*.
Re:MtGox account database leaked by Locke1689 on Monday June 20, 2011 @12:24AM (#2672864)
Bcrypt is nice but anyone attempting to kid themselves that they're creating secure webapps should at least know security standards like PBKDF2. It's in practically every good crypto library, as well.
Re:MtGox account database leaked by llambda on Monday June 27, 2011 @10:14AM (#2701341)
Do you have a good source explaining PBKDF2 and perhaps comparing it with bcrypt in the context of securing web apps?
Re:MtGox account database leaked by drivebyacct2 on Sunday June 19, 2011 @05:49PM (#2672011)
I've got people in IRC telling me that MD5+rot13 is good enough, or to just use some SHA implementation. This was after I'd already espoused how trivial bcrypt was.

Seriously, there are people in here that don't understand the difference between encryption and hashing, don't understand the benefit of salts, think that there (is/should be) one "secure" salt.

The load of just absolutely false security information in here is startling.

Re:MtGox account database leaked by llambda on Sunday June 19, 2011 @06:17PM (#2672089)
Hm, I'd like to know more about why MD5+rot13 is good enough and also why they justify "good enough" over what could be argued as a "good" or perhaps very good solution, e.g. bcrypt?
Re:MtGox account database leaked by burgerbrain on Sunday June 19, 2011 @06:54PM (#2672188)
The only thing MD5+rot13 would have going for it is that you couldn't just trivially google the hashes to get the reversal (as is the case in a disturbing number of cases). Of course this only lasts as long as they don't figure out that it's MD5+rot13.. I'd give that about 5 minutes tops.
[deleted]
Re:MtGox account database leaked by drivebyacct2 on Sunday June 19, 2011 @05:48PM (#2672010)
I'm hearing a LOT of conflicting information. The version I keep hearing is that most are salted MD5, but that some old ones are unsalted.
Re:MtGox account database leaked by wcoenen on Sunday June 19, 2011 @05:51PM (#2672020)
I deleted my reply (where I stated that the passwords were salted).

Apparently the database has a mix of hashing strategies. It started with unsalted MD5 and was improved over time. The format of the PHP crypt output allows you to distinguish between hash types.

Re:MtGox account database leaked by sunchild on Sunday June 19, 2011 @08:14PM (#2672373)
I think the replacement solution needs four key components:

1) Stronger logical security

2) A triggering mechanism for halting suspicious trading

3) Clear rules for halting and rolling back market activity

4) Some measure of coverage for trading loss

I'm no expert in equity markets, but I would imagine someone who is can weigh in on how these specific issues are handled.

Re:MtGox account database leaked by byrneseyeview on Sunday June 19, 2011 @10:31PM (#2672610)
If you guys do work on this, send me an email (email is in the profile).

Halting is not the right way to run an exchange, because it creates "air pockets" of liquidity given sufficiently sophisticated traders. This is what lead to the "flash crash" last year: high-frequency traders didn't want to be caught with illiquid positions in the event of a halt, so they sold as quickly as they could, making a halt more likely. It creates a situation quite similar to a bank run.

(Instead, you might want the people who organize the exchange to also do some market-making, and to stabilize prices in order to grow volume, leading to a more profitable business overall.)

Re:MtGox account database leaked by HockeyPlayer on Monday June 20, 2011 @01:38PM (#2675154)
As a market maker, I do NOT want the exchange also making markets, which puts them in direct competition with me.
Re:MtGox account database leaked by byrneseyeview on Monday June 20, 2011 @03:27PM (#2675605)
For sufficiently fungible products, the "Market Maker as Exchange" model works really well. What you'd basically have is high spreads for retail investors, and lower spreads for institutional investors. So your consumer-facing company would make a spread and then flatten its exposure by trading with other market-makers.

This gives the "Exchange" more flexibility than Mt. Gox has. It can offer more competitive prices when it's worthwhile, and pull back if trading with retail customers gives it too much net exposure. That's better than having a fixed fee for matching people with market-makers.

This is a rough approximation of how forex works.

Re:MtGox account database leaked by Tichy on Sunday June 19, 2011 @05:50PM (#2672016)
Is there even a way to make a server unhackable? I am really not sure :-(

I would try to put the whole thing on Google App Engine, at least then the burden would be on Google for the most part :-/

Re:MtGox account database leaked by ChuckMcM on Sunday June 19, 2011 @06:01PM (#2672044)
"Is there even a way to make a server unhackable? I am really not sure :-("

Its a pretty difficult thing, the simple answer it turn it off :-) however you're second comment is more relevant.

"I would try to put the whole thing on Google App Engine, at least then the burden would be on Google for the most part :-/"

Google does a good job of securing their servers, however the risk is not that the 'server' gets hacked, rather its the application running on the server. So for example someone can't log into your server but they can SQL inject a command to dump your web site's password list and they don't have to log in.

Good secure design would start with really really strong testing around the applications 'mutation' points (which is to say where it changes in response to user input). When I was at Google products had to go through a security audit before being released and those guys were pretty good at their jobs. This is one of those cases where seeing a lot of ways people try to attack services gives you a leg up on looking for common weak points.

Re:MtGox account database leaked by astrodust on Sunday June 19, 2011 @07:50PM (#2672324)
Anything can be hacked if it has information on it. There's even those terrifying "cold hacks" where you yank the memory stick from a machine that's powered off, chill it to preserve lifespan, and plug it into another machine to read it, the thing coughing up the contents like some zombie.

Nothing can ever be fully secure, but you can make it secure for all practical considerations.

Re:MtGox account database leaked by ltamake on Sunday June 19, 2011 @06:01PM (#2672048)
If the MtGox site didn't have a giant hole in it (SQL injection), this would have never happened.
Re:MtGox account database leaked by Tichy on Sunday June 19, 2011 @06:09PM (#2672073)
Sure, but it seems most sites end up having such holes in them. I am pessimistic in that I assume it is next to impossible to prevent.
Re:MtGox account database leaked by m0nastic on Sunday June 19, 2011 @06:50PM (#2672179)
It's definitely not impossible to prevent issues like this, it just requires effort.

Securing a network/host/application is like getting (and staying) in shape. It's a process that requires an ongoing effort. There's nothing you can buy that will take care of it forever.

Most breaches aren't the result of "impossible to prevent" attacks, they're the result of basic due diligence not being followed. You're right though, that it seems some days like that's the rule and not the exception.

While you can't have an "unhackable" site (or an "uncrackable" safe), it's all a matter of risk vs. reward. You can certainly ensure that your site doesn't have any vulnerabilities listed in the OWASP Top 10 (and test it repeatedly over time to make sure it stays that way).

And that's not even getting into a more mature vulnerability management process that involves outside assessments, source code reviews, and threat modeling. All those things are also nice to haves (or may be required, depending on your industry and the type of data you have access to).

It's totally understandable to be a pessimist about the state of security in our industry, but preventing these types of issues is not a Sisyphean task.

Re:MtGox account database leaked by qntm on Sunday June 19, 2011 @06:36PM (#2672152)
SQL injection problems are trivially preventable.
Re:MtGox account database leaked by marshray on Sunday June 19, 2011 @07:26PM (#2672278)
Maybe, but only if your awareness and concern for security is non-trivial.
Re:MtGox account database leaked by mbreese on Sunday June 19, 2011 @08:55PM (#2672446)
If you're running a currency exchange, your concern for security should be quite high.
Re:MtGox account database leaked by Tichy on Monday June 20, 2011 @03:32AM (#2673278)
Sure, but they are not the only possible security problems.
Re:MtGox account database leaked by drivebyacct2 on Sunday June 19, 2011 @05:57PM (#2672034)
Uh, seeing as this was an SQL injection vulnerability, just using GAE wouldn't protect against that at all.

An unhackable server is probably possible, but a non-trivial unhackable server probably isn't. But you can still create sites that are secure, even if hackable. If the hackers had accessed a database of bcrypted passwords and if the site would have locked down when it detected erroneous volume of transactions, there would be no headliner here.

Re:MtGox account database leaked by Tichy on Sunday June 19, 2011 @06:08PM (#2672067)
I am not that worried about writing a web application properly. But I am just an amateur when it comes to administrating a server. I would be more worried about some security hole in some random service that is running on the server by default, that I never even heard about.

GAE doesn't even use SQL, btw. At least last time I checked they didn't - they seem to be planning to support it in the future, though.

However, even if the server is secure, I suppose if it was known that I am the admin of a BitCoin bank, my home computer would become a target, too. If my home computer would be hacked and I logged into the server, I would be screwed, too. It just seems too risky...

Re:MtGox account database leaked by jerf on Sunday June 19, 2011 @07:52PM (#2672332)
"I am not that worried about writing a web application properly.... I would be more worried about some security hole in some random service that is running on the server by default, that I never even heard about."

While the latter can happen and is broadly easier for a script kiddie, believe me, the former is nontrivial and very rarely done correctly. Your average web app is full of vulnerabilities, and while scanning can't quite be fully automated it's definitely something you can use automation to help with, so don't think you're secure-through-obscurity.

Re:MtGox account database leaked by biot on Sunday June 19, 2011 @07:18PM (#2672255)
App Engine uses GQL which is effectively the same as SQL: http://code.google.com/appengine/docs/python/datastore/gqlre...

You can still directly append unescaped user input to your query and execute that against your datastore, though the limited capabilities of GQL does limit the attack surface somewhat.

Re:MtGox account database leaked by omouse on Sunday June 19, 2011 @09:26PM (#2672502)
MtGox was first and they also overcame the barrier of payment processing. Payment processing is ALWAYS a bitch which is why people like bitcoin ;p
Re:MtGox account database leaked by Ixiaus on Sunday June 19, 2011 @07:23PM (#2672271)
I'm thinking about it... In any case, it would be a cool project. This would be a great opportunity to try out Erlang for web app development...
Re:MtGox account database leaked by lwat on Sunday June 19, 2011 @09:48PM (#2672543)
Fun fact: not long ago 'MtGox' meant 'Magic the Gathering online exchange'