Posted
by
kdawson
on Thursday April 10, 2008 @11:35AM
from the cultural-values dept.

Stony Stevenson writes "Google presents a big fat target for would-be hackers and attackers. At the RSA conference Google offered security professionals a look at its internal security systems. Scott Petry, director of Google's Enterprise and founder of security firm Postini, explained how the company handles constant pressure and scrutiny from attackers. In order to keep its products safe, Google has adopted a philosophy of 'security as a cultural value.' The program includes mandatory security training for developers, a set of in-house security libraries, and code reviews by both Google developers and outside security researchers."

I was going to say something smart about Microsoft, Mac etc, but then Google do have the advantage that they were founded on the internet, once the benefits but also the threats of networking computers had been fully understood.

I'd be surprised if any from-scratch operating system designed for internet-facing use today, didn't also have 'security as a culture'.

OpenBSD is designed with security in mind. It's so secure that you can't run anything on it! Not running anything? Nothing can be hacked!Seriously, I used to think that OpenBSD was the bees knees, but after struggling with a broken ports system and no supported upgrade path between major versions (the latter coupled with a short support cycle means that you're having to constantly install on new metal, test, deply, and decommission the old server), I'm just not interested any longer.

It's been said that the most secure computer is one that's turned off. So, it would follow that the most secure application is one that won't compile. That'll teach those darn users to compromise system security by daring to run stuff!

In OBSD's defence, they do contribute useful work. SSH and pf are great, and OBSD makes a fine software router and firewall on gigabit sized pipes and smaller. For general purpose server use, it'll work but there's better options.

I can't deny that useful code has come from the OpenBSD team. I generally don't like the idea of using commodity x86 hardware for a router/firewall, though. To me, the usefulness is just too limited. For a home connection, it's really quite a bit of overkill, and for a medium to large number of users, you run into problems servicing customers if too many small packets are coming through. I think in the tests that I've seen, you can get down to about 512 byte packets before you start seeing loss, but of

I don't run OpenBSD, either. But, having followed the project for sometime, I'd say that given how much attention the project pays to security, security is part of their culture.Personally, I run Ubuntu, which I find to be quite flexible and easy enough for my non-techie wife to use on her machine. And it's good enough in the security department -- a competent sysadmin such as myself can easily secure the OS and network from most attacks. At the same time, a total n00b who does nothing more than keep his

Google's security consciousness comes not only from being founded on the Internet, but also from the fact that they know that they have to compete.
Microsoft had itself in a monopoly situation before network security became an issue. MS only takes notice of security when it appears to threaten its monopoly status. Our security people would love to see us go to Linux (granted, still security holes, but they are more controllable). However, we can't because users would whine about noting being able to use

Short timeouts on the captcha and/or using javascript to generate the images might help. I don't know if it's really this bad, but many captchas I've run across virtually never expire (they might expire when the PHP session does, but I've hit a page with a captcha, gone to the restroom and to get a soda, and come back to a still-valid captcha.)If you had a reasonable time limit in which to solve the captcha, it would certainly make it harder to farm out.

Ok. What about a system where the captcha is presented up front with nothing else on the page. Succeed, and you get to the full registration. The page could use Javascript to rotate the captcha image periodically, expiring the previous one each time.There are other ideas that could go along with this. You could use Javascript to send kestrokes in the captcha text box back to the server, which could then use those keystrokes to determine how soon to expire the captcha. If the user types the first letter c

in reply to some of the above topics:my data on one of my web site that I manage might help ( I get posting spam issue all the time )

Captcha life in excess of 1 minute, the odds of it being a real users dies off rather dramatically, reloads typically happen 7 to 12 minutes later if they are real, reload happen within the 1 to 5 minute window are spammers of some sort.

captcha life of 20 seconds or less brought me more trouble and a huge amount of complaint mail. I'm right now leaving it at 45 second for 7 ch

reCAPTCHA [recaptcha.net] has a key system. It makes the user have private and public keys so that no one can simply take your CAPTCHA and use it on their site for others to solve for them. From the API Documentation:

"In order to use reCAPTCHA, you need a public/private API key pair. This key pair helps to prevent an attack where somebody hosts a reCAPTCHA on their website, collects answers from their visitors and submits the answers to your site."

I've had very little spam that actually came from googlemail, maybe two items in a year. I've had a lot of spam that purported to come from googlemail, but examination of the headers quickly revealed it was simply faking the origin.

SPF doesn't stop spam by itself, it's one tool. Ironically, spammers were early adopters of SPF say postini, now owned by google, and valid SPF for an email's origin can actually be an indicator of spam!

This isn't about spam and Google groups. It's about preventing a malicious cracker from accessing the vast quantities of data that Google has about every single Google user [reputation...erblog.com].
These days, a full identity (SSN + bank account) sells on the black market for $14-$18 [washingtonpost.com], depending.
Google has tens of millions of users. Not all of them have their SSNs in their Gmail, but I'll bet that a fair bit have at least one credit card number or bank password in their email archives, their search history, or elsewhere within

The e-mail isn't backscatter. Bounced messages have a delivery failure preamble. These are from a google host according to the header date.

The Usenet stuff isn't forged either. Messages reporting their origin from groups.google.com can be found in Google Groups. The path at that point doesn't appear to be forged. Google has it as having been posted from their system.

Must be a new Google appliance. I'm glad it is preset, and does not need any end-user configuration.

In any case, I commute on the train with Google guys in NY. They use their laptops to work on the train, but have those little wireless security devices that generate random passwords for them when they want to log in, so their connection is fully encrypted.

Speaking from experience, two-factor authentication with a crypto-card type thing is a pain in the ass. I'd be willing to trade some security in exchange for the convenience of not carrying this thing around and having to deal with typing in constant random crap.

The GP responded to a post relating to security of a computer system vs the liberties granted to users of the system. As such I do not think it applies to real world attacks on civil liberties.
The funny part of the post (yes, it is indeed funny) is that he used a famous quote from Franklin dealing with civil liberties, applied it to computers, and reversed it.
The way I see it, it means "if you are willing to sacrifice your security for ease of use [liberty], you deserve neither."

How many buffer overrun exploits have been found in other people's software because the coders are just lazy? Google also tries to prevent this by explicit rules that everyone must follow no matter what: for example, you are not allowed to check in code using sprintf instead of snprintf.

A little thing to be sure... until you realize that it's one of many such rules, and they actually are followed.

Everyone has rules like that, it's enforcing them zealously that actually produces good code by preventing bad code from entering the codebase. It doesn't work if you don't enforce it 100% of the time, because one shady procedure can be the one that is targeted for an attack.

Sorry, no. Rules like "don't use sprintf" don't produce quality or security. There is a difference between a culture of writing secure code and a culture of not writing non-secure code. The former can be successful, the latter is a constant exercise in patching and turd polishing.

You are saying that good coding will not save an insecure overarching design. This is obvious. Just as obvious is the fact that bad coding will ruin a secure design.

Enforcing the use of snprintf instead of sprintf helps prevents the latter from happening. Seems obvious, no? But somehow, plenty of other companies (hello Microsoft) still have problems with this stuff.

MS actually stops these things from getting into the build now, using tools such as FxCops and variations. The issue comes from legacy code that is still part of their newer products (and refactoring such mammoth code bases doesn't happy overnight), on top of deep architectural issues that cannot be caught by simple rules... If they started from scratch enforcing their current policies, it would be much better.

However, the world isn't so simple... so Microsoft has to pay the price.

Exactly. Microsoft has bent over backwards to support backward compatibility across wildly different kernels. Raymond Chen spoke once, I believe, about a SimCity bug that worked fine under DOS as long as you were running only one program, but would crash in Windows. The problem? Memory was freed and then used after it was freed. The solution? Microsoft added a check to see if SimCity was running and fixed the code with a special allocator for only SimCity.Microsoft has done this for decades, and thankfully

I remember that story. I think it was mentioned on The Old New Thing?..Ya know, this is what bugs me about the bum rap that Microsoft gets.True, to professionals in the field, it's often easy to be appalled at what we see as incompetence.

(And I'm not speaking to the management/sales, just the tech side of Microsoft)

But given the same goals, constraints and budgets, I bet that most assembled teams would produce software of no greater quality than what they have produced.

I don't disagree with any of the points you've made, other than the fact that they chose this path in order to keep their dominance. Yes, keeping backwards compatibility for increasingly diverse environments is hard. But they figured it was the easiest way to keep people on their platform. To say that this somehow releases them from the commitment of making their hacks and fixes *work* is another issue entirely.I don't disagree that it's 'hard'. I disagree that there was no choice in going that route. They

What the previous poster was refering to is that serious development shops will use code analysis tools to inforce it: that is, the code will not be allowed to be checked in (or to be integrated to the trunk, or whatever) if the rules are not followed, and they are inforced at the source control level (or something).Variations include having the code analysis tool throw "compiler" warnings, and make the compilation to consider warnings as errors and fail the build.

We ended up getting bitten by bugs like unsynchronized access to static DateFormat object so we wrote used a PMD rule to fail our build if anyone does such a thing. We have other rules that curb the use of IOUtils.copy (instead of copyLarge).

I highly recommend using some sort of static analysis as part of your CI process

How many buffer overrun exploits have been found in other people's software because the coders are just lazy?

Very, very few. As very, very few coders also own the company their coding for.

Seriously, most of the security holes found in software are there because the company won't pay the coders to sit around securing the finished product once it seems to work. I've been on many project where we were told to even use mere QA time to instead add a new feature the client wanted. Were we being "lazy" because we didn't do all that work for them for free later, in our massive amounts of free time?

I've run into a several Google security people at conferences like Blackhat and RSA. They've always struck me as rather arrogant, self absorbed, and poorly informed. One of them actually went on a tirade about how nothing could compare to the risk of an XSS bug in Google's homepage. In the same conversation he also showed a complete failure to grasp how a heap overflow occurs or how process isolation works.I admit, that guy was the worst of the bunch, but but I continue to be unimpressed by their security p

I'd like to see a heap overflow generated by a webpage, please. I know its happened before - way back when IE couldn't parse (or something like that) for instance, but google is (for the most part) totally an online company. The only interaction that most people have with them is via web pages. Surely this would make web page vulnerabilities far more important to them.

I'm a little confused by what this has to do with Google. They aren't getting hacked are they?
It sounds like other random sites are getting hacked and you can still find them on Google search. This doesn't seem too surprising, so perhaps I'm missing something?

Two guys are out camping. They get ready to bed down, and guy is putting on his sneaker before getting into his sleeping bag. The other guy inquires, what's up with that?

The guy says, in case a bear attacks our camp during the night.

The other guy is skeptical. With sneakers or without, there's no way you can out-run a bear.

The guy replies, I don't need to out-run the bear. I just need to out-run you.

I suspect Google security is pretty much the same way, with a twist. Why try to hack Google, when I can use Google to find credit card numbers, unsecured plain text password files, servers running old, unpatched versions of vulnerable software, etc.

I'd think the hacker going after Google would be as popular as the kid who rats out the teacher who buys the kids beer.

In my experience as CTO of a respected software development company (Digital Focus), and since then as a consultant in the field of assurance and methodology, I have found that in general developers are not interested in security. E.g., my book, High-Assurance Design [assuredbydesign.com], which looks at application architecture from a security and reliability perspective, sells in very low numbers, while my Java books sold in very high numbers. "Hacker" books sell well because many developers want a "quick fix" to their apps, w

I find it interesting that people do not recognize the core value of Vista over XP (security).

I recognize that if I want the increased security of Vista over XP that I will need to buy a new PC. My current configuration is an Athlon XP2100, 512MB RAM, and Gforce 2 video card. I have never gotten my pc infected with malware and I've been running XP since it came out. And, with XP, I get the added bonus of being able to listen to an MP3 I've ripped from one of my CDs and not have my network transfers come to a screeching halt.

With Ubuntu HH due out this month, I'm seriously considering repaving my Ub

My Dad's machine is a Athlon XP2400, with 512mb of ram and an AGP Geforce 6100, it runs Vista slowly but it does run Vista. As an expeariment I did try it with 1.5GB of DDR400 and it ran ok and not really much worse than XP, the vista expearence index was 2.3 (2.1 with 512mb of ram). He's since deceided to buy 2GB of DDR ram. The machines still running Vista business 32bit now, personnally I would stick XP back on it but since the other two machines in the house are using Vista he wants that one to as well.

Perhaps they have some way of limiting the number of pings from a specific address setup on their firewalls. Say they allow you to ping 5 times and then they just drop the icmp packets. Just a thought.

C'mon, I know you do it too: when I want to see if my Internet is working, I "ping www.google.com".I still find it surprising that it ICMP_ECHO_REPLYs my ICMP_ECHO_REQUESTs. Why?

I find it surprising that you find it surprising!:)

A lot of sites disable ping because, years ago, The Ping of Death could crash a server by sending maliciously-crafted ping packets.

The "Ping of Death" gained fame because any chump could create one from a totally generic Windows system using the broken ping that Microsoft was shipping at the time. The technique is applicable to any IP protocol, not just ICMP echo. You can make an SMTP of Death fairly trivially. Just fake up a datagram with a total length greater than 65,535 by abusing the fragment offset field of the IP header, and if the target system does not check total length for validity you can overflow memory and hose the system. If that didn't make sense to you, just remember the "Ping of Death" has NOTHING TO DO WITH PING - it's an IP vulnerability that used to exist for ALL protocols in the IP stacks of certain vendors (IBM, Sun, Cisco, etc.) and is now fixed.

And you can DOS a server by flooding it with pings.

And you can do it more easily with practically any other type of packet. If you plan to block all traffic that can be used for DOS, you must block all traffic, period.

Ping is a service we all should provide to our internal networks from individual hosts, and to the Internet at large at the network edge. Configure your routers to respond to pings for your hosts instead of passing them through the firewalls. Ping is how people who need to test their ability to reach your hosts or site can do so. It is a simple tool that consumes a minimal amount of bandwidth to get the job done.

I'd be interested to know just how many pings Google receives, and replies to each day.

They might tell you if you ask. If it ever gets out of hand they'll just respond with normal traffic shaping techniques.

And how many of those are maliciously encoded, only to be defeated by the ub3rh4x0r5 at Google.

There's nothing dangerous about ping. Nothing... you can tell if a network is competently administered just by pinging it, my friend. I'd never hire anyone who had an unpingable net.

Hmmm... where's BadAnalogyGuy when you need him? OK, look, blocking ping is like saying that you've seen a guy killed by an Isuzu truck, so you think you can prevent all fatal accidents by banning Isuzu trucks from the highway. In reality, all you will do is prevent beer deliveries to my house, since my beer distributor uses Isuzus. This will make me hate you, just like people hate clueless firewall admins who block ICMP. Or wait, you saw a guy get bludgeoned to death with a hammer so you will ban all hammers while allowing people with large wrenches, razor knives and screwdrivers to pass without comment. That was pretty bad I think.

Hmmm... where's BadAnalogyGuy when you need him? OK, look, blocking ping is like saying that you've seen a guy killed by an Isuzu truck, so you think you can prevent all fatal accidents by banning Isuzu trucks from the highway.

Ooh, ooh, and turning off all ICMP, hence killing PMTU discovery, is like taking the number off your front door to stop your house getting burgled and then wondering why you aren't receiving as much snail mail as you used to.

turning off all ICMP, hence killing PMTU discovery, is like taking the number off your front door to stop your house getting burgled and then wondering why you aren't receiving as much snail mail as you used to.

What about physical security for Google facilities? Last time I was in Mountain View I took a leisurely stroll right through the middle of the Googleplex, right past the life sized dinosaur skeleton, right past the sand volleyball court and hot tub and right through a couple of their office buildings. I like how the Googleplex is set up like an academic campus, but it's pretty trivial for a bad guy to bypass the card access doors by piggybacking behind somebody else.

Also, the whole place is made out of floor to ceiling glass windows. Would be really simple to shoulder surf somebody's display through a telescopic lens or listen against a windows with a laser mic. There's a reason high security buildings tend to resemble windowless block houses. Hopefully, anybody with a window seat at the Googleplex never processes sensitive data.

I'm a bit down on Postini lately. A few months ago, they started marking my personal e-mails to Postini customers as spam. Which [ncl.ac.uk] is [aol.com] kinda [aol.com] ironic [google.com]. And pretty damned annoying, since my lawyer, my broker, my apartment manager and my chiropractor are all on Postini servers. But hey, that happens. I went over my server with a fine-tooth comb, I set up SPF, DomainKey, DKIM, no luck. I even switched servers. No matter. My e-mail, now digitally signed in triplicate, was still being scored as 90% probable spam.

So I tried to get in touch with their postmaster group. Only they don't have one [postini.com]. And I tried to check their feedback loop [emaillabs.com]. Only they don't have one. As a shareholder, I even wrote to Investor Relations [google.com]. No response. In the process, I found out that they have a universally awful reputation among the mail delivery community.

In the end, all they could tell me was that their system decided my mail was spam because - I kid you not - their system had, previously, decided my mail was spam. Which, of course, increases my spamminess score. And so on, and so on, until we're all using the same shampoo.

So, to recap: The guy in charge of keeping Google secure, Scott Petry, is the guy who invented a system that bit-buckets your e-mail, with absolutely no accountability, no sanity checks, no industry best practices... because of guilt by association WITH YOURSELF.

In security circles it is well known that security through obfuscation or obscurity is no security at all. By publishing their security internals Google is setting a good example for the industry at large which still lacks faith in security-through-transparency.

If Google values security so much, why can't do they anything about their open redirectors [google.com]? After all, this has been abused by spammers and phishing scammers for weeks, so maybe it's time to finally do something about it.