So my name is Jason Haddix, and this is Gunnar, and we are hackers. We created a data, I guess, data repository and tooling called... You didn't want that picture in the slides? No, no, no, it's a good picture. That's a great picture, dude. I appreciate it. And so we created some tooling and some data repository stuff for people primarily who are doing application security testing. Okay. So a little bit of history. So about... oh, I don't know. 2016, I spoke at DEF CON on the main stage on this topic. And the talk was called HUNT. It was called HUNT Data-Driven Web Hacking and Manual Testing. Now, HUNT, these fine people at the bottom were the ones who helped me put that talk together. What we're doing today is enhancing it a whole bunch. So let me talk about the problem space we're working in right now. So right now, a seasoned hacker, application security hacker, can kind of look at a website, and for some reason, they've developed, like, a spidey sense. If you've been doing this for 10 years or 15 years, you look at a website and you're like, oh, yeah, that's probably vulnerable to X, right? And that's just, like, something that people talk about all the time. It's like, oh, I don't know really how I hack. I just kind of, you know, I look at the site and I do this thing. That is not helpful for new people getting into application security. Just saying, oh, you'll develop this skill set in 15 years, right? And so a lot of them call it, like, their spidey sense. But really, it's experience and context that are driving these decisions when you look at an application and know where to hack it and how to hack that section of the application. So how do we shortcut experience and context? And in general, you should never do this, right? But in our cases, we're going to try to help new people get some ideas about where to hack certain things in the web application assessment arena. Okay. So this is a URL. Have any of you seen a URL before? Woo! There we go. There we go. All right. So here is a URL. And at the end here, we have ID. And so the whole structure is, like, you have your protocol, and then you have your subdomain and your domain, and then you have your file or resource name, and then you pass that, usually a parameter and a parameter value. Now, our talk and research is all about these things. Parameters, right here. Because they can be used in a sense and fashion to give you the context we're looking for and guide you into what to test. Okay. So in 2016, when we did this research, I mean, I won't call it stole, because I worked for them at the time, but I didn't really get permission, but, you know, whatever. Basically, I went over the dataset of every bug bounty on BugCrowd. Anybody know who BugCrowd is? Yeah. Okay. Cool. So BugCrowd is a bug bounty platform. And at the time, it had over 600 bounties, internal and external. And what I did is I had the data engineers chop off the domain, so I could not identify who the companies were. But they gave me the URL data. And then for every bug that existed on a URL, I parsed out the parameters for that bug class and the bug URL. So that was about two programs... or every program had, on average, about two targets per bug bounty. So targets are like www.defcon.org, forums.defcon.org, media.defcon.org, etc., etc., etc. So each target had about 15 average parameters per application. And many were many, many more. So approximately, we saw about 18,000 parameters with vulnerabilities on them in this dataset. Which is probably the biggest dataset, I think, that's ever been parsed for vulnerability research in web before. Or 18,000. Sorry. So in the 18,000 parameters that we found, that were anonymized, we reduced them to make sure that we got the vulns that we wanted to investigate, the vulnerabilities. So things like cross-site scripting, SQL injection, command injection. Things that you find in AppSec testing, right? So we reduced it to ones we wanted to do research on. And then we also reduced it to only P1s and P2s or high-severity critical vulns. Then we sorted by recurring instances of when that took place. And then we included the 5 to 10 or 15, in some cases, we expanded to, the reoccurring instances per vulnerability category. And then we looked at those and then manually reviewed them and were like, OK, well, I know with my 15 years of context and that team of five people, there's some permutations of this thing that I always want to look at, so I'll add those just off the top of my head. And then we also looked at a whole bunch of repos that include fuzzing data. Which was like PentestDB, FuzzDB, and SecLists, which I run SecLists with Daniel Meisler. So, we made these lists. And what these lists were, were just lists of parameters in websites that were vulnerable ones to a certain class of vulnerability. But because we had seen certain ones so many times, we started to tell our friends, like, every time you see a next parameter, probably you should check it for redirects and LFIs and RFIs and stuff like that. So, this talk, SUS Params, is about releasing the tooling to do that yourself, and jacking up the lists to the nth degree. And analyzing that data. So, SUS Params, obviously SUS and parameters. We did a whole bunch of work with AI, which Gunnar's going to talk about, to actually do the data parsing. And people say that data parsing with AI is impossible. I'm here to tell you it's not. We used it very effectively in this talk, or in this set of tools. We're going to release the lists, and then we're also going to work with a friend of ours, xmlhacker, who will give you a way to implement this in your day-to-day life using his tool. So, I'm going to pass it over to Gunnar as we go. Alright. So, right now, what we started with on this release of the repo and the data, the next target we went for was HackerOne. We don't have any internal digs in HackerOne, right? So, it's all the public data. Anyone who knows HackerOne knows that there's a very long list called the hacktivity that is publicly disclosed data. Perfect. So, we used AI to parse this data, which I'll talk about later. But this is what hacktivity looks like. So, this would be kind of annoying to scrape, and web scraping nowadays with dynamic websites and all that stuff gets very annoying. So, huge shout-out to HackerOne for making this whole list populated by a GraphQL query in the backend. So, you can actually just script the GraphQL query, it's a paginated GraphQL query, and you can get all, I think, 15,000 publicly disclosed reports on every public program on HackerOne. Then, the next thing that's nice about it is normally when you click on one of these, it brings you to a HackerOne report, which is now also stuff that would be very annoying to scrape for text. Well, again, all of the HackerOne reports come in JSON format. If you take the URL of the HackerOne report and tack on .json at the end, it shows up in JSON format, because that's how it gets pulled out of their backend. So, what we did is I went and grabbed all of the report IDs out of the GraphQL endpoint, and then saved all of the JSON format of all those reports, and we ended up with right around 15,000. Again, it's in the repo if you want to see it. I saved all the data from every step, so if you want to reproduce it for some other data set, you can follow the steps and make sure it looks very similar. So, the AI parsing discussion. So, we tried to do a whole bunch of different things with AI to parse this data. As a lot of people know who have messed with AI, I'm not an AI expert myself, but AI output is normally never very uniform. You normally can't get AI to just give you JSON output and only JSON output. You normally can't get it to give you really clean output that you can count on to be the exact same every single time. So, just telling some of the AI, hey, I'm going to let you read this text that I pulled, and then you give me the parameter. Sadly, it doesn't exactly work that way yet. Maybe soon, but not quite yet. So, oh, sorry, misclicked. So, what we did instead was GPT 3.5 Turbo, you can use with the OpenAI API. I messed with that and messed with temperature and all that kind of other stuff, and it works sometimes, doesn't work all the time. You pay the extra 20 bucks and use GPT 4, and it's much, much better at understanding HTTP requests, HTTP URLs, code, JSON, whatever it may be. And we were able to use AI to basically take the mountain of text that you would get from 15,000 bug bounty reports and reduce it down to basically one sentence that either had parameters in quotes, parameters in a bulleted list, or basically something that makes it basically rejectable, which is going to be the next step. So it takes this massive thing of text, reads it, and then will tell you, like, this report has parameters that are vulnerable or not, this is what they are. And since the reports come from HackerOne, already broken into cross-site scripting, command injection, SQL injection, whatever it may be, you don't have to use AI to do that. You just can already split it up as it goes and then ingest it into AI that way. And at the end of all the slides, I'm going to go through the repo, and I'll show you exactly what I did. We used HackerOne, like Jason said. You can use what we did, and we're releasing the scripts, of very few changes. If you have, within your company, your own internal data set of either incidents you've had, or you run your own bug bounty program, and you have your own internal reports, and you want to know, hey, can I make this data set just for my stuff? Absolutely. That's the point of the project. We're releasing our set, our new set of lists, based on Jason's list, and this new data, for bug bounty hunters, solopreneurs, whatever it may be. But we're also releasing the scripts, and we're going to explain how we did it. That way, if you have something very similar that you would like to generate your own honed list of SUS params for, you can also do it. So, as Jason mentioned, we have a buddy who goes by xnailhacker on Twitter, who makes a burp extension called GAP. GAP originally would collect, as stuff goes through your proxy, it will collect links, and it will collect parameters, yes? Yep. From anything that flows through your proxy. It does it automatically, and then there's a GAP tab in your burp suite that you can click on and read through them all and filter them all and highlight and all that stuff. He was nice enough to work with us and implement the list that we created into GAP. So the new version that's releasing today with GAP will now do, is not only will it collect parameters, but if you check a little box in the config, it will create burp issues, just little burp issues for you, for all your parameters that show up in the SUS params list. So if you have a parameter that shows up in a URL, it will automatically put it in the list for you. You can go to GAP, pull down the list of burp issues, and you can see all your parameters that show up in SUS params. So we'll show that to you in a screenshot. Yep. So this is part of what it looks like. Is there two? Oh, no. Okay. So there's just the one. So this is kind of what it looks like. So when it, you can basically pull the list and it'll say like, okay, so it found an ID parameter. Like people in the past have tested that for XSS, IDOR, SQLI, SSTI, whatever it may be. That kind of thing. You can turn it off and on, but this is basically what Jason was talking about, where if you're maybe newer to the scene, or you maybe are doing a fast, you know, you're doing a fast engagement or something like that, this is something to really help you kind of narrow it down and maybe get to stuff that might be vulnerable a little quicker. Okay. Did I miss anything before the demo? Yeah. Cool. Where's the escape key? There we go. Okay. So I'll leave it up at the end, but this is the repo for the project. I was going to say, can we zoom in? I wasn't allowed to use my Mac, so... So this is a repo for the project. Again, at the top, anyone who knows it is TomNoNone, correct, is GF? Yes. So there's a tool that some people use in automation just called GF. So there's GF patterns for the list at the top, too, if you use that tool. And then as we go down... So this query I saved. This was the original query that I pulled. This is your GraphQL query. So if you want to try and pull hacktivity a little bit different than I do, this is the GraphQL query that you start with. So that's just thrown into a text file just in case, you know, so you don't have to hunt it down. That kind of thing. After that, HackerOne and BugCrowd, we did try and pull BugCrowd data publicly. The CrowdStream is much smaller than hacktivity. So size of dataset-wise, the hunt dataset is vastly larger, obviously, than what is on the CrowdStream. Whereas HackerOne has much bigger... Hacktivity is just much bigger. So HackerOne.py, that file, will basically run... It does take a little bit, because it's paginated GraphQL queries, and there's quite a bit of JSON files. But what it will do is it will save them in this volns.json. Again, I'm not going to try and open it, because it's very big. But this is the last pull that we did, if you're interested. Otherwise, just running that HackerOne.py will make a new JSON for you, and you can start over. Because obviously, there's new stuff getting disclosed on Hacktivity all the time. If you want to take this list and not run it, and regenerate the whole list, it's very easy in the query that's in the HackerOne.py file to just add a filter that says from X date to X date. So you can be like, ah, just grab the last month. So you don't have to run through all 18,000 that there will be at some point. Next, this POC.py, this is our proof of concept for how we did AI. Again, this will change depending on what type of text you're putting in, what type of data you're putting in, etc. What we did is I took the JSON file and there was just one of the strings was just all the text that was in the description of the report. So it was pretty easy. You just take the text and you put it into OpenAI. So how we did that is you just put in your OpenAI token at the top. Again, GPT-4 for this use case worked way better than GPT-3. Someone out there who is more of an AI wizard than I am, play with it. If you get it to work, let me know. But GPT-4 does it basically out of the box. This GPT conversation function that you see at the top is basically the out-of-the-box conversation API call that they would recommend you make using GPT-4. So the one thing I did play with that you can either turn off and on if you want to change the script, is this is using the chat completion part of the API, which technically speaking will save a chat if you want it to. I clear the chat every time because I'm doing 18,000 pieces of text. And if you keep trying to hand OpenAI an 18,000 thing long conversation, it will very quickly hit the token limit and you can't do it anymore. If you want to do something with conversations and keep some back-end data, you can probably play with that and actually use a tokenizer. I use TickToken. You can use a tokenizer and probably keep the back half of the conversation if you wanted to and maybe enrich the data even further. But what I did is I did one piece of text in a conversation, had OpenAI handle it, and started over with a fresh conversation. Just throwing that out there. Then all it's doing is, again, there's going to be a function for each one. I split it into functions that way if you want to just rip the function and do it for whatever your own thing is. This goes through the JSON and does all the XSS, all the SSRF, and we'll show the categories at the end. But this is basically just for every category there's a function for it. So... What? Okay, yeah. These are just... and all the functions are very similar. And then again, this is the conversation that will grab the conversation and print it out to the, as you can see here, to the volumetype-file in the test. So this test directory, this is what I was talking about, and this one I can open. This is not too big, hopefully. So this is what I was talking about. Data parsing in AI is interesting, and the output is never uniform. But, if you even look at these top couple things, you'll notice there's pretty obvious patterns in the output. First of all, 90% of those parameters that it gave me, it says the vulnerable parameter is, and then the vulnerable parameter is normally in some kind of quotation. So I can use regex on this dataset, which is now much smaller than the mountains of text that I just was putting into OpenAI. And it now also eliminated any report that it read and didn't find the parameter in the report. If it didn't find any parameter names in the report, those are now eliminated. So not only did I eliminate a huge amount of reports, but I lowered the amount of text to much lower where you can easily regex through this and it happens instantly. And we regex for any type of quotation, any type of list, anything that comes after a colon, a whole bunch of things. That is in... Oop, wrong one. This one, sorry. So these, again, this file here, when you look at it, and again, this is something you can play with too. If your data looks a little bit different, this one you can play with too. But this, I put little comments in the Python so you can know what each of the regex does. Thanks to ChadGPT for making my regexes, by the way, to look through its own data. So, like I said, there's stuff for quotes, there's stuff for single quotes, the dashes, there's stuff for REST API endpoints that lands inside two backslashes, colons, everything else. Like the list goes on and on. Then what it does is it takes, as it goes through the regexes, those regexes create their own list of data that they parsed out of the much smaller text, you combine all those files for each category, and you end up in here where now you actually have sorted, counted parameters from the output. And from here is how we then basically turned it into categories and lists. So, I think... Alright. So, let's look at the categories. Okay. So, we looked at file inclusion. What parameters when you do web application testing are most likely vulnerable to file inclusion of some sort. So, that is something like the parameter name lang, type, text domain, name, token, URL, path, etc., app, platform, resource type, file, default language, directory, API path name. So, if you've ever written an application, you probably use one of these keywords to reference how you handle a file or anything, right? And so in the English language, in my 15 years of testing web applications, I don't see any on here that I haven't found a file inclusion button on. I've found at least one on all of these parameters. We also did insecure direct object reference. So, of all of those two datasets, which at this point encompasses over 32,000 vulnerable parameters, out of all of those, out of all of the IDORs that existed there, these are the most statistically likely ones that have IDOR. The ID parameter, the user ID, username, email, extended data, username, data ID, etc. We also did redirect vulnerabilities. So, redirect, very common, has a high score in URL. The parameter next, redirect, return, host, you can see that redirect and return appear multiple times under permutations. So, it makes sense, right? A redirect vulnerability lies in these parameters. Now, one thing is that we looked at parameter data, but if your application uses RESTful URLs, you can just substitute these keyword terms for parameters instead. You could just look for them in the path instead of parameters. So, we also did SQL injection. Obviously, the biggest offender in SQL injection, because it fits the database nomenclature as ID, then email, refer, limit, search, token, username, password. Pro bounty tip, always try SQL injection in the refer, keep a blind SQL injection payload in your refer at all times. Hit that one many, many, many times. Server-side request forgery, we did the same thing here. Same thing, URL, source, start, host, those make a lot of sense for server-side request forgery. Server-side template injection, we didn't get great data for this, so we just... So, the GF patterns have more together. Okay, so hold on, we do have some stuff for server-side template injection. And then cross-site scripting. So, yeah. So these are the places where you're most likely to find vulnerable parameters. And the GF, so when you go up to the GF patterns, the GF patterns, so that was the output for only HackerOne, right? So HackerOne actually didn't have, at least that we found, using the parsing methods we found, didn't have anything for SSTI. Maybe it's not as common, maybe, you know, there's a possibility we missed it, either way. But, there's still old data from Hunt, that's still, like, it's old, but it's still very useful, and it's still the same parameters that are being used. So the GF patterns that we made are the full list of both, right? That's where they both come together, and same thing, the SUS parameters, if you use the SUS parameters list on XNL Hacker's GAP extension, that will be both data sets put together, right? So the GF patterns are basically the end product of Jason's old research, with the five people that were at the bottom, and our research this time, put together, and basically the goal of this is, A, to close the gap in experience, but again, I really want to reiterate, you can do this with anything. There's CVE data out there, there's XSS data out there, we will probably do that at some point, as we continue to play with the repo and bring in the database. Again, if you have internal data that's, you know, pertaining only to your company, make your own lists. The scripts are supposed to be out there, and the repo is public. Specifically so that this can maybe generate some other folks out there, to make maybe some different kind of lists for stuff that you would also want to see. This is kind of an opportunity, hopefully, to again close the experience gap in more fields than just vulnerable parameters. So we had planned to do CVE stuff, and we put it in the abstract for the talk. The problem we ran into is that many CVEs are like what I like to call ghost CVEs. They're CVEs that people say the bug class, and they put it out on CVE details or some other place, but they don't actually give you any exploitation data, right? They just said X product, how to cross-site scripting, whatever. And then the ones that do have proof of concepts, which include URL data, which we need to do this, are often on blogs. And so we have to do two steps of crawling, and we're close to figuring out all that. And so when we get that done, we'll probably try to tackle this data set. And we figured the last five years would be relevant. That's what we had planned for the talk. So we got stymied a little bit on this data set, but we really want to include it in the list as well. The other one we wanted to do was XSS.com, which if you've ever seen that site, it's purely XSS proof of concepts. Oh my god. So this is XSS.com. It's a hacker website where gray hat hackers post a bunch of XSS vulnerabilities, usually when they don't get paid through a bug bounty. So they have a total of 45,000 total XSS proof of concepts on XSS.com. So that one would specifically enrich the XSS data. Some other ones that we might look at in the future is actually looking at instead of looking at the bugs that come through HackerOne or BugCrowd, we could look at researcher lists. We could figure out a way to scrape their blogs and look at their personal research and see where they find cross-site scripting vulnerabilities, which was actually the first iteration of anything like this when stuff like this happened in 2014 or 2012 or something like that. So the possibilities are endless for us to keep enriching the lists. We think that this project will help a lot of people. And I think that's all we have. So last thing, I will say for people curious about cost, because the few people I've talked to about the talk before we gave it, that was the first question that came up. I parsed all of the HackerOne reports on a personal OpenAI token, and it was right around $30. So it's not, you know, not too bad. Any questions? Kind of talk fast. No? Cool. Thank you very much. Oh, wait, we got one. Sorry. Sorry, I killed you guys. Yeah. Oh, yeah. Oh, yeah. With every model. It will do it sometimes. Let me repeat the question. So the question was, did we try prompt engineering to change the prompt to pull out the data in the format that we wanted? If we said, give us the parameters this one way, did we try more specification in what we wanted? Did we change it to say different words? And the answer is yes. So we tried a lot of that with a lot of the different models. Even, because obviously it will definitely struggle to give you a JSON output or something like that. But even just trying to beg it to be like please just always put it in quotes. Like no matter what the extra stuff is, just please use double quotes. It'll do it. It looks almost identical. It's immensely frustrating. Was there any other questions? Yes, sir. Boom. Yeah. You could try. I feel so bad for your open AI token. Like I guess I never just like let it fully exhaust itself into infinity. But I tried doing retries. I even tried going to the quoted version, and then taking the quoted version, like slowly going downhill, and it still is... Yeah, it has a really hard time creating structured output like JSON. It just doesn't work. I don't know why, but it hallucinates formats, it adds extra characters. It's just because it's trained on next characters, right? It just doesn't create structured JSON very well. Not saying it can't be improved. Again, I'm not saying I'm the expert. This is just like what we've tried. Again, that is probably if you play with this project, that is probably one of the areas to play with, right? Yeah, I mean we wanted that to work. We really did want that to work. Yep, yep. So I actually counted... so with the regex I actually counted how many lines I was actually catching with the regex versus how many I was just like dropping. And the regex was able to catch like 98%. Right? So I mean there's like 2% there that probably still had malformed data or whatever, but like that was as close as I could get. Without literally making like a whole list of like 80 regexes for every single... at that point you're just manually going through the file anyway. And I... why even script it, right? So, yeah. So this is the repo and you guys can use it. Any other questions? Yes. ... That's actually a really great question. So the question was, could you subcategorize these into parameters that were most likely vulnerable on an industry vertical? Like finance or banking or automotive or something like that. You could with the HackerOne data I believe because they... I think they reference the vertical, don't they? So you can with the HackerOne data if you're going to go deep into it because they always reference the target. The publicly disclosed reports always say a target. So if you're willing to make a master list of like for instance the HackerOne targets and say okay this target is financial, this target is like XYZ or gaming or whatever it may be. You could probably do that with AI pretty easily. Yeah. So it is possible. Yep. Any other questions? Okay. Now you guys can clap for Gunnar. Thanks guys.