New abuse primitives that take advantage of legitimate administrative protocols and features are wildly exciting. Why? Because no object is an island. Everything is interconnected, and that interconnectedness can have enormous impact. Thread: 🧵
You may or may not be familiar with the childrens' book, "If You Give a Mouse a Cookie:"
It's a classic children's moral illustrating the slippery slope idea:
If you give a mouse a cookie, it will ask for a glass of milk.
But it's too hard to drink the milk, so now the mouse wants a straw.
The mouse is worried it has a milk mustache, so now it wants a mirror.
etc
The mouse just keeps asking for more and more stuff which, in the context of what it already has, is reasonable:
It's reasonable to give the mouse milk to go with its cookie, a straw with the milk, etc - but the mouse can effectively horse trade up to whatever it wants.
We can understand and model this with math.
"If You Give a Mouse a Cookie" is a graph comprised of vertices and edges:
These discrete connections, when seen in isolation, are reasonable. The same is true in AD: it's reasonable for these particular connections to exist, but together they form an attack path:
Now, back to the original point. Finding new abuse primitives that abuse legit functionality can have extraordinarily high impact. For example, what if we found a new abuse that bypasses this path, connecting Domain Users to Domain Admins instantly?
Or, what if we had disparate, unconnected paths?
Whenever someone finds new abuses, that new abuse is very likely going to be the missing link between disparate paths, connecting Domain Users with Domain Admins:
Mathematically, the impact on the number of paths in a graph grows at a rate of O(n!) - factorial growth. That's a LOT more than even exponential growth:
Why do I say all this? Because when you consider the above, plus the fact that we are still in the infant days of Azure research, you should be excited at the impact your own Azure research can have - it is MUCH greater than you think!
In my @1ns0mn1h4ck talk, I'll try to give you all the context and fundamental building blocks you need to stat finding new abuse primitives. You can register for Insomni'hack here: insomnihack.ch/register/
• • •
Missing some Tweet in this thread? You can try to
force a refresh
Azure App Service Web Apps are yet another #Azure service that supports managed identity assignments.
Here's how attackers can use #BARK to abuse those assignments:
There are at least 3 ways to achieve code execution on an Azure App Service Web App ("Azure Web App" from here on) instance:
1. The Kudu shell execution API endpoints 2. Poison deployment to include a web shell in the app 3. Find a cmd execution vulnerability in the deployed app
We'll focus on #1 - abusing the built-in Kudu shell execution endpoints.
This is the feature the Azure GUI uses as its "Debug Console" and is documented here: github.com/projectkudu/ku…
Defenders and vendors have to play catch-up whenever one of these novel C2 methods becomes popular.
I believe it's possible to proactively, semi-automatically discover these methods in existing and emerging cloud services. We can assess their attractiveness to attackers, vendors can make them less attractive and prioritize their own detection efforts.
Kerberoasting is an incredibly powerful and reliable attack against Active Directory. In some situations it can result in an attacker becoming Domain Admin nearly instantaneously.
Here's how to prevent this attack: 🧵
First we need to identify Active Directory users that are "kerberoastable" - possible targets for the attacker to choose to Kerberoast.
Kerberoast relies on a user having some value in their "serviceprincipalnames" attribute.
Find all of them instantly with no 3rd party tools:
dsquery has been built in to Windows Server since Server 2008. You also get it when installing RSAT.