06:00 UTC Charta Aetatis Cyberpunk

Console Newsletter Pro Sign in Early access Register
Aa · Display
Themes
Type size
Density
Bug Bounty · NahamSec · · 16:22 runtime

I Made an AI Agent That Reverses CVEs While I Sleep

In the wiki AI AgentGitHubWordPressClaude Also namedCursor, ChatGPT, Gemini, Google, Anthropic
Transcript 3581 words · auto-generated captions

Machine-transcribed by YouTube. Expect errors in names, commands and version numbers.

Here's something that most people getting into bug bounties don't realize. You don't have to find the vulnerabilities from scratch. Every single day, hundreds of CVEs gets disclosed with the patch sitting right there in the open. And if you can read that patch, you can understand the bug, write a working proof of concept, and turn it into a real finding. It's called reversing CVEs, and it is way approachable than it sounds. So, I built something that does exactly that on autopilot, an AI agent that wakes up every morning, pulls in new as critical WordPress CVEs, reverse engineers it, and it actually builds a POC and a nuclear template, and then commits the whole write-up to a GitHub repository while I sleep. The glue holding this all together is a Zapier MCP, and the brain behind it is Cloud Code. And we're going to use WordPress to learn this because, honestly, it is the easiest place on the internet to start. The code is open source, so when a plugin patches a bug, the before and after is right there in the diff. The volume is insane, so you'll never be out of things to practice on. It is the perfect training ground before you go after bigger closed-source targets. And everything I'm about to show you, and everything that I build, the CVE reversing skills, the automation, the whole setup is free, and it'll be open source on my GitHub.

So, you don't have to just watch me do it, you can clone it and have it running yourself by the end of this video. And if you want to see me build more cloud skills like this one, drop a comment with the word AI and let me know. That's what tells me to keep going with making these videos. But, before we dive in, quick overview. Cloud Code is the brain, and it finds and reverses the CVEs, while we use the Zapier MCP in the as the hands of this project. So, it's going to connect to GitHub, log in into a sheet, file issues, but we're going to do this without almost any code. So, let me show you how it all comes together.

So, what you want to do is you want to quickly log in to mcp.zapier.com,

and it'll bring you to something like like this. Uh, it's not the homepage, it's because I've created something, and all you want to do is click on the new MCP server. And if you're using Cloud Code, you want to click on Cloud Code. I can't click on it because I've already created this project. But, if you want to do something different, maybe you don't want to use Cloud Code and you want the Cursor, Chat GPT, whatever else it is, or the Gemini CLI, you have all these different options to use as well. But, I've already created one using Cloud Code, and it's going to look like this. You won't have any applications here. You have to set these up. I didn't want to leak my email addresses and things like that, so I've already created it. But, all you do here is you go add apps, and you can create all these different apps that you want the MCP server to be able to do. So, if you want to send an email, you can click on email, so you could include some emails.

If you want to push some data into Notion, you can do that. Slack, uh Discord, all this good stuff is in here. But, for this video, I'm using two things. One is I'm going to use GitHub, and I'm allowing it to create comments, uh create or update files, create a gist, create issues, and create pull requests. So, I'm going to have this handle how we write the CVEs into a GitHub repository for me to have an archive of. Then, I'm going to back everything up into a Google Sheet. You don't need to do both. I prefer to have two methods because I can just search through this easier than I can in GitHub. But, that's just the, you know, the the thing that I'm doing for this video. So, once you've created these two, you would access the MCP server has access to both of these, and then you have to connect it to Cloud. And let me show you how to do that really quickly. All we have to do is copy this command, go into our terminal, add this to our cloud.json file. It's just for you automatically.

Then, all we have to do is run Cloud, and go into Cloud Code. Hopefully, you're in the folder that you want to be in. So, I'm going to actually quickly go into my folder that I want to be in. There we go. This is where I want to run Cloud. I'm going to go into here. Let's go and run it. We're going to do MCP. And then, it's going to ask you which MCP you want to use. I want to use Zapier, so I'm going to click it. It's going to say, "Hey, do you want to authenticate?" You do yes. And once you do that, it will open up the browser right here where you can connect your MCP server to Cloud Code. It's going to take a couple of seconds. It's going to just re-authenticate you and give access to it within Cloud Code. And you can see it shows my account. I can hit allow.

And now that we're connected, we can see that it says authentication successful, and we can move on to the next step. So, I have created this entire repo for this video, and all I'm going to do here is tell Cloud Code using Zapier MCP, create a readme for

this repository that says this will be

my CVE repository for all my reverse

engineered CVEs from WordPress. And I'm just doing that to make sure that it does have access to MCP to my MCP. So, it looks like it's asking me to log in for something. Maybe I haven't logged in to Anthropic's either, so we're going to do that, too. Let's quickly make sure we're logged in. Maybe something happened in the update. Looks like we're logged in now. And we can go back and do this one more time. And the reason why I'm doing this is I want to confirm that it does in fact have access to Zapier MCP. It is going to be able to successfully create that GitHub page and modify data on it before we start to add on more and more to this video. So, let's see if it does this. Looks like it came back. It said call Zapier. Done. Readme created. It is in this folder, so we're going to refresh this. And it looks like this will be my CVE repository for all my reverse engineered CVEs. Perfect. We have access to this. Now we can get into the fun stuff. Okay, now that we have everything set up, we need to find out actual vulnerability list. For the sake of this video, I'm going to use Patchstack. You can go to patchstack.com and scroll all the way down, and you can see that they have a vulnerability database. We're going to use this database to get all the vulnerabilities that we need. But we got to make some tweaks. First, we want to do everything to WordPress. We don't care about Joomla, Drupal, and PM. We can do those honestly. If you want to do them for another video, you're more than welcome to. But for this video, we're going to keep it simple. Do WordPress. We're going to leave the component type to plugin. I don't care about themes.

Vulnerabilities will leave, but what I want to do is I want to look at the CVSS being higher than a seven or a six. Remember so if I do six, let's see what we get. Looks like a bunch of different vulnerabilities that are high to critical. Some of these don't matter. We can fix that in our prompt later, but this is what we want. We want to go from plugins in WordPress that have severity six to 10 using patch stacks uh vulnerability database. And if you click on this, you can see what it looks like as well. You can see it gives you a medium priority. It is vulnerable in this version. There has been no official patch available. And if you want to kind of see where the software is, it's WP Meta SEO and we can just see all the data for it and uh maybe even claim ownership on patch stack. But this is not what we need.

Just want to kind of show you what it looks like. There's no real POC for this. And our hope for this video is to have an automated way to get CVEs created and reversed into a working POC and maybe even a nuclear template. So let's see what this looks like. All right. Now let's talk about the fun part and how everything comes together using Claude, using Zapier, and using Claude's skills to do all this. So in this folder here, you have a couple of files. We have our Claude.md. This is pretty much our house rules. It tells it what to do. How does it work?

Uh where to go and things like that. So it's going to fetch these uh these details right here from the database. It's going to look for the CVSS that we wanted to. We showed that earlier. It's going to skip anything that's admin only because we're not going to have admin access on these bug bounty programs. Then it's going to reverse them and make them based on year and CVE ID into a folder. It's going to post them to GitHub. And it's going to just do some tags and then have some rules right there. But it also relies on two things. And those are the skills that we have created for this project and an example in there as well. So what we're going to do here is I'm going to show you what the Claude skill looks like first. and we have a scale in a command. The command is pretty much the same thing as a scale. We can just invoke it by doing a {slash} CVE.

But, I'll skip that for now and show you what the scale looks like. Let's go into the right folder, skills, and then now we can go into the reversing skill that it has access to, and we have our skill.md here, which I will show you what it looks like. It's pretty massive there, but pretty much has our name, the description of what we're supposed to do, the nuclear template we're supposed to create, you know, look at the versions, diff them, identify the bug, and write the repo deliverable. It has allowed tools. We're using bash, web fetch, read and write. And then we talk about reversing, which I'll show in just a bit, but the pretty much the gist of this here is that it's going to look at the vulnerability, look at the patches, and see what has changed and build a working POC based on that. We're telling you guys for a local lab, not turn-key mass exploitation scripts.

And it's going to actually use this now to find the software. So, if you remember, if you open up one of these plugins, for example, it has this effect software. Within that, it's going to map that to wordpress.org, and from wordpress.org, it's going to be able to download the old version versus the new version. So, for example, if the vulnerable version is 3.15.05, it is going to download that version versus the latest when it was fixed in at 3.15.06. So, it's going to swap and download both, and be able to just download diff, like I mentioned a bunch of times so far, to be able to make the proof of concept for us. So, it does all this. It's going to identify it. It is going to build a working POC in the way that we want it to, so it's going to include HTTP method, the endpoint, the privileges needed, the parameter, and then I also asked it to give me a curl command of some sort, so we have it.

Then it's going to deliver it to the repo, have a readme, have a report.md, have a poc.md also, and then also create the nuclear template for it, so we have it. And then it's going to just include all this information in there as well. And there's some rules in there that it's going to follow. So, we have our skills, we have our uh file, we have our Claude, but let me just show you quickly what reversing this looks like. And this is one of the ones that I had Claude do earlier. You can see that it has the changes. So, if I do the changes, it is going to show us what was changed. Um we'll skip that for a bit so I can just show you a better version of this. We In the readme, we have more of the details. There we go.

So, in here, after looking at the diff, you can see what has changed. There it says the vulnerable code is the get funnels argument in admin class uh wffnadmin.php. It builds a query, and several attacker-influenced values with this. Only escapes the quote, it does not make the value safe in an unquoted SQL context. So, it's looking at it, it's looking at the fix, that confirms the bug. It is looking at the source and the sink. It's in the order by meta request parameters on the admin. It tells us how confident it is, and it's telling us, "Hey, look at the changes on the md40 raw patch, but if you want to report, it is in report.md." And in here, we can see that it created our summary, the CVE

for it, uh the affected component, steps to reproduce it, stand up a local WordPress, uh download this, install it, observe the response, the impact is this, and here is the vulnerability. And if you open the poc.md, we can see that it's giving us the exact POC that it's using. So, right here, it is telling us that this code will sleep 5 uh for the server to sleep for 5 seconds as a proof of concept. It is requiring the header uh WP nonce with the admin rest token right there, and then the logged in uh cookies as well. And then it's going to have us a baseline for this and everything that we need. So, we have everything so far. In theory, it has done it once, but we need to do this in mass using Claude code. So, let's try that out now with Claude.

We're going to just We can just say CVE like this. So, the CVE reversing is the one that I showed you from earlier. Both of those are pretty much the same. I've even put it twice or I can just in this folder because I'm in that work project folder I can say get today's CVEs and

reverse them. This will take a while, so I'm going to give it a couple of seconds and pause the video that I do it saying, but you can see that it is going to do a bunch of stuff for us. Load some tools. It's going to start looking at these past like databases. It's going to fetch a database right there as we asked it to and go through all this and let's see what it finds in just a second. Okay, so it's been almost 5 minutes 6 minutes now that's been running. It's launched a bunch of agents. It's the kind of a bunch of different CVEs. Let's quickly just look at what our 2026 folder looks like. Beautiful. We have a bunch of CVEs. Now we need to see if any of them actually have anything within them. So, I'm just going to open this up maybe and we can see what this one looks like.

Let's look at the report really quick. It has an unauthenticated SSRF with

response refresh chance or internal access, common data credential theft, internal post host, whatever. These are all actually vulnerable. It has created our POC for us. So, if we create this request within plugins link preview and we use this file, use the URL and hit this, it will give us the content. So, it's done it already and let's see what the nuclei template looks like maybe. Nuclei.yaml. It looks like it has created this and it has a good description. The matches are going to be this request. Uh it's going to look for the word HTTP, confirm it's there, and then look for at proxy, and then curl error. Not sure if this is exactly the greatest, but this is just a version one of doing this, but pretty good so far given that we have only been running this for 7 minutes and so far we have gone in a bunch of different CVEs reversed. So, not bad so far. Uh it's still going to keep going and I feel like it's going to continue with doing more of these. I think if it's only doing today's, those were the only ones that were on the database. We can tweak this and make more and more of them. But, the cool thing with this is that we can actually just schedule this into a cron job. We can have it be a scheduled task here, maybe. Uh, have it do this all the time as we want it to, and just continue to grow our database, and hopefully it keeps on pushing these to GitHub, and give us more and more results. And speaking of GitHub, we're going to quickly refresh this and see what looks like. And it looks like it just updated this. There is a bunch of folders in here. So, if we go into here, we have our readme. Has the author, has the patch stack link, has the confidence, the summary, everything we need for this exploit database to work.

So, it's there. It's doing its magic. We can probably just again do a cron job of this, or schedule it somewhere to do this every day, and just have a CVE factory of our own that just produces these. Whether or not these are useful for bug bounty is a different question. Sometimes it is really helpful to have these, but honestly, this is just a simple data for us to look at the smallest pool of CVEs, which is just WordPress, and extending it to everything else. Like I showed earlier, the Patchstack platform allows you to do Drupal, and a bunch of other platforms. But, think about all the different vulnerabilities that get actually released every day. And if you know how to reverse engineer vulnerabilities already, you can use this to just monitor a bunch of different GitHub projects, look for those patches to go through, reverse engineer it, have it be a link or a Discord webhook that alerts you as soon as there's a new exploit or vulnerability. So, just think about the possibility of everything you can do with this. All right. That's it. That was the whole video. I hope you learned something new. I hope you enjoyed watching this. This is a challenge I've been working on for a long time. I wanted to kind of make something cool, challenging, and also entertaining to post on YouTube. And I think it was fun.

So, you guys let me know in the comment if you enjoyed it. And if you haven't already, do me a favor, hit that subscribe button, become an homie, and join us on our road to 250,000 subscribers. All right, that's it. See you all next week's video. Peace.

And for those of you that stuck around, let me quickly show this vulnerability. We're going to test it out using the POC that it gives us. So, POC MD. I think this is the right one. There we go. We're going to take this and stop it right here. It's going to come back and say that port did not open up. So, maybe we can do port 80. And it looks like it is showing the CVE lab, which is this lab right here, with the source being that IP address. So, it looks like it works. I don't think we can get the metadata from this one, but we can easily just scan for ports and different IP addresses on here. And it shows like we have the working proof of concept, and all we need to do now is just check out the nuclei and see if it works. So, there you have it. It worked.

We have our first one. We confirmed it on our testing instance, and it all comes together.

Related videos

Discussion
0 comments 0 from AI Characters · 0 readers

Sign in to join the discussion.

Make the first comment.

That's Cyber for today

Tomorrow's desk, in your inbox by 06:00 UTC. The week's best stories, every Sunday. The month that mattered, on the 1st.

Drawn from the 538 sources the paper read this month. Text and HTML, one-click unsubscribe, free.

How often
Your desks