95 points · by ricksta · 14y ago · 28 comments
[W]rite access to sensitive data should be limited to the maximum extent practical. A suitable first step would be to disable mass assignment, which should always be turned off in a public-facing Rails app. The Rails team presumably keeps mass assignment on by default because it saves many lines of code and makes the 15-minute blog demo nicer, but it is a security hole in virtually all applications.
http://queue.acm.org/detail.cfm?id=1964843
This doesn't justify the Bad Guys abusing third-party sites with this, but the Good Guys did everything right and did not achieve a fix as a result of doing so.
For another, there exist many, many applications against which one could demonstrate a bug in Rails or Ubuntu or SSL or just the finding "Lol, P=NP." Pragmatically, would you like that to be your application? I would very, very much not like someone to do one of these to my sites. It would cause an instant nightmare for me. The happy outcome is I lose thousands of dollars and don't sleep for most of a week. The unhappy outcomes are not upper-bounded by death of my business.
n.b. Busting into Basecamp to make a point about Rails would also be morally irresponsible.
Any company that is paranoid enough to cut their Github contract following a benign intrusion that was resolved in under 24 hours is not a company that would have uploaded code in the first place. This is not the only security vulnerability on Github.
I think you are being excessively dramatic.
This is fascinating to me. It would be great to learn the reasons why it will cost them so much.
(I don't doubt it; quite the contrary. I'm inexperienced and would love the opportunity to learn more about the realities of the modern security industry.)
this stunt will cost Github five to six figure
It will cost its customers a lot more to reaudit all their commits from the date they migrated to GitHub. How can any one be certain at this stage that there hasn't been a 0-day inserted into their project?The curious twist in this whole tale is that PHP- because of its history of being insecure- actually had a hardened distribution, while Rails didn't.
This type of smugness creates its own karma, as evidenced by the red-faced hack of a premier RoR site.
In other news, I'm not sure why the rails core team was so against this in the first place. Making things safe by default is usually a good idea. This change doesn't seem to add too much additional ceremony, and people had been asking for this for some time.
I'm not sure why the rails core team was so against this in the first place.
Lack of humility.Mass-assignment by-default, with disabling fields you want to protect
vs
Mass-assignment off by default, with enabling fields you want to mass-assign.
It's hardly just outright arrogance.
Security vulnerabilities by default, with the ability to patch the vulnerability on a project-by-project basis.
vs
Security by default, with the ability to allow potentially insecure assignment on fields you want to assign.