coreruleset / coreruleset/ftw-tests-schema

Support for "isolated test" flag

Open
#3 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Go
Stars
1
Forks
3
PR merge metrics
No merged PRs in 30d

Description

Definition "isolated test"

An "isolated test" is a test that triggers only the corresponding rule on the paranoia level of the rule and lower paranoia levels.

This means that an isolated test for a rule on PL1 may only trigger the corresponding rule on PL1, but it may also trigger rules on PL2 and higher.

Reasoning

The CRS Status Page depends on isolated tests. Carrying a separate list of isolated tests will lead to redundancy and an outdated list. So the information whether a test is isolated or not, should be kept together with the test.

Implementation

The information is meant to be with the test, next to the description.

Implementation variant 1: New flag next to description
  - test_title: 942100-1
    desc: "Simple SQL Injection"
    isolated: true
    stages:
      - stage:
Implementation variant 2: Create metadata array next to description, add flag to new metadata collection
  - test_title: 942100-1
    desc: "Simple SQL Injection"
    metadata:
      - isolated: true
    stages:
      - stage:
Implementation variant 3: Create metadata array, move description into new metadata collection, add flag to new metadata collection
 - test_title: 942100-1
   metadata:
     - desc: "Simple SQL Injection"
     - isolated: true
   stages:
     - stage:

CAVEAT

For the CI of the rule set it is important to make sure the tests flagged as isolated are really isolated, also when we edit rules. See definition above.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the FTW test schema and the CI for the rule set, focusing on how test descriptions and metadata are represented. Define how isolated-test information is stored beside each test, then ensure the CI can verify the stated isolation rule when rules change.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, yaml
Domain
testing
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.