Evaluating LLM Generated Detection Rules in Cybersecurity
This paper introduces an open-source evaluation framework and benchmark metrics designed to assess the effectiveness of LLM-generated cybersecurity detection rules by comparing them against human-generated rules using a holdout set methodology.
Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer
Imagine the internet as a massive, bustling city where every email is a letter traveling through the mail system. In this city, there are bad actors trying to sneak in fake letters, scams, and viruses disguised as friendly notes. To stop them, we employ "detectives" who write specific rules to spot these troublemakers. For example, a rule might say, "If a letter comes from a suspicious address and has a weird attachment, flag it!" These rules are the security guards of our digital city.
For a long time, only human detectives could write these rules. They studied thousands of letters, learned the tricks of the trade, and wrote precise instructions to catch the bad guys. But recently, a new kind of detective has arrived: Artificial Intelligence (AI). These AI agents are like super-fast apprentices who can read instructions and write their own rules in seconds. The big question on everyone's mind is: Can these AI apprentices actually do the job? Or are they just writing rules that sound smart but fail to catch the real criminals, or worse, start yelling "Fire!" at innocent people? This is the puzzle a team of researchers at Sublime Security set out to solve. They wanted to see if an AI could write security rules as well as a human expert, and if so, how much it would cost to keep that AI working.
The paper introduces a new way to test these AI detectives, focusing on a specific AI agent named ADÉ (pronounced "Ah-Day"). ADÉ is designed to look at a single malicious email and write a rule to catch similar bad emails in the future. The researchers didn't just ask, "Did it work?" They built a detailed scoring system to measure three things: how well the rule catches bad emails (accuracy), how likely the rule is to break if a hacker changes a tiny detail (robustness), and how much money it costs to get the AI to write a working rule (economic cost).
To test ADÉ, the researchers played a tricky game of "hide and seek" with human-written rules. They took a list of excellent, human-made rules from Sublime Security's collection and secretly hid one from ADÉ's memory. Then, they showed ADÉ a single bad email that the hidden rule was supposed to catch and asked, "Can you write a rule to catch this?" After ADÉ wrote its rule, the researchers compared it to the original human rule using a massive database of 45,000 emails.
The results were a mix of impressive skills and understandable limitations. When it came to writing rules that were hard to trick (robustness), ADÉ performed surprisingly well, scoring almost as high as the human experts. For instance, in tests involving emails with hidden JavaScript code, ADÉ's rules were just as tough to bypass as the human ones. However, ADÉ was much more cautious. While human experts wrote broad rules designed to catch thousands of bad emails based on years of experience, ADÉ wrote very narrow rules based only on the single email it was shown. As a result, ADÉ caught fewer total bad emails (True Positives) but also made far fewer mistakes by flagging good emails (False Positives). In fact, for some tests, ADÉ's rules had zero false alarms, whereas human rules sometimes flagged a few innocent messages.
The study also looked at the "cost" of using AI. Writing a rule isn't free; every time the AI tries to write code and fails, it costs money to run the computer. The researchers found that ADÉ usually needed only 1 to 3 attempts to write a rule that passed the technical checks. This translated to a very low cost, ranging from about $1.51 to $5.13 per successful rule, depending on the complexity of the task. Interestingly, the AI tended to write much more detailed comments explaining its logic than human authors did, making the rules easier to read.
Ultimately, the paper suggests that AI agents like ADÉ are becoming capable of writing high-quality security rules, especially when it comes to avoiding false alarms and staying within budget. However, they aren't quite ready to replace human experts entirely. Because the AI only sees one email at a time, it struggles to write the broad, sweeping rules that humans create after studying thousands of cases. The researchers conclude that while AI is a powerful tool that can handle specific tasks efficiently, the best security likely comes from a partnership where AI handles the heavy lifting of rule-writing, and human experts guide the strategy to ensure the rules catch the widest net of threats.
Drowning in papers in your field?
Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.