I'm going to take a guess that reading files like /etc/shadow are 'tripwires', which trigger a review by an engineer.
With seccompbpf it's pretty simple to have systemwide tripwires on certain files/syscalls/network operations. Even if the attacker gains root, your tripwire will probably alert you before they can disable it.
The other way to see it, is that it took them 8 days to notice a full compromise of the hosting OS and an open access to Google’s internal docker image repository URL.
So this blog post is missing any information about what the actual vulnerabilities were. What was the "gap"? What was the misconfiguration? Also missing is whether access to the host VM exposes meaningful secrets. Does this actually risk customers' sensitive data?
I was part of the Cloud SQL team when putting databases in VMs was designed (previously the MySQL process was run in a sandbox).
I am sure Cloud SQL is far more advanced since then (9 years ago), but security in depth was something we thought about a lot. Running in a VM for each database rather than a multi-tenant system was for security more than anything else. We could have multi-tenanted just as easily implementation-wise.
"With access to the operating system, we managed to find some internal Google URLs related to the docker image repository. We could also access the internal repo which later was fixed and the access from non internal IPs was blocked."
Fascinating how sloppy some people are when they set up infrastructure even though this may be down to bad defaults.
The vulnerability sounds like it's inherent to SQL Server, and that cloud providers haven't been successful in blocking the underlying problem due to its proprietary nature.
Presenting it as a Cloud SQL problem is disingenuous.
> we identified a gap in GCP’s security layer that was created for SQL Server. This vulnerability enabled us to escalate our initial privilege and add our user to the DbRootRole role, a GCP admin role.
So Google took proprietary software not designed for this use-case and built their own security layer on top of it and ended up with bugs.
Of course that's an issue with the service. Presenting it as anything else than an issue in Cloud SQL seems disingenuous.
Remember that MS SQL server isn't Google code... Any vulnerabilities it may contain they might be powerless to fix.
Considering that, Google probably has an extensive monitoring system running in the VM, looking for things happening that shouldn't happen... And they have probably also built a filtering infrastructure between the users and the SQL server so that if any vulnerability is found, they can at least filter attempts to exploit it while a fix is being made.
According to the blog post, the vulnerability is not within SQL Server itself, the vulnerability is in the security layer that Google built on top of SQL Server in order to offer it as a managed service on GCP.
And what would that accomplish? Knowing the contents of /etc/shadow of a random (virtual) machine that belonged to someone else that you could not access, one that most likely already ceased to exist.
As the article says, the vulnerability was fixed in April and the people who discovered it have already been rewarded under Google's Vulnerability Reward Program. Google also proactively detected the problem before being notified by the researchers.
It's already been resolved by Google and is not exploitable, so yes hopefully sysadmins using SQL Server on CloudSQL will indeed have an actually fun long weekend.
jimmyl02|2 years ago
londons_explore|2 years ago
With seccompbpf it's pretty simple to have systemwide tripwires on certain files/syscalls/network operations. Even if the attacker gains root, your tripwire will probably alert you before they can disable it.
belter|2 years ago
jorams|2 years ago
ec109685|2 years ago
VWWHFSfQ|2 years ago
First, we did a privilege escalation.
How? They don't say.
Next, we did another privilege escalation.
And how?? They don't say.
what's the point of this
lima|2 years ago
Getting access to the host OS won't give you much other than some internal binaries and config.
cflewis|2 years ago
I am sure Cloud SQL is far more advanced since then (9 years ago), but security in depth was something we thought about a lot. Running in a VM for each database rather than a multi-tenant system was for security more than anything else. We could have multi-tenanted just as easily implementation-wise.
tidbitruminator|2 years ago
"Our research began when we identified a gap in GCP’s security layer that was created for SQL Server."
It would have been interesting to see how they identified that security gap.
Havelock|2 years ago
breakingcups|2 years ago
jalk|2 years ago
belter|2 years ago
https://bughunters.google.com/about/rules/6625378258649088/g...
londons_explore|2 years ago
Who knows - if Google hadn't detected the intrusion, this attack might be on the black market by now.
AtNightWeCode|2 years ago
Fascinating how sloppy some people are when they set up infrastructure even though this may be down to bad defaults.
mcstafford|2 years ago
Presenting it as a Cloud SQL problem is disingenuous.
nitrammm|2 years ago
> we identified a gap in GCP’s security layer that was created for SQL Server. This vulnerability enabled us to escalate our initial privilege and add our user to the DbRootRole role, a GCP admin role.
So Google took proprietary software not designed for this use-case and built their own security layer on top of it and ended up with bugs.
Of course that's an issue with the service. Presenting it as anything else than an issue in Cloud SQL seems disingenuous.
londons_explore|2 years ago
Considering that, Google probably has an extensive monitoring system running in the VM, looking for things happening that shouldn't happen... And they have probably also built a filtering infrastructure between the users and the SQL server so that if any vulnerability is found, they can at least filter attempts to exploit it while a fix is being made.
drewda|2 years ago
Alien2|2 years ago
[deleted]
speedgoose|2 years ago
kccqzy|2 years ago
redwood|2 years ago
dub|2 years ago
coderintherye|2 years ago
yafbum|2 years ago