Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Firewall Profile Implementation #685

Merged
merged 13 commits into from
Jul 11, 2023
Merged

Firewall Profile Implementation #685

merged 13 commits into from
Jul 11, 2023

Conversation

adplotzk
Copy link
Contributor

@adplotzk adplotzk commented Jul 11, 2023

Firewall Profile Description of Changed:

  1. Adding firewall.json in profiles
  2. Adding firewall_rule.json in objects which extends the rule object for the firewall profile usecase.
  3. Updating http.json in events/network to include the application of the firewall profile in to accommodate WAF events.
  4. Updating disctionary.json to include new attributes from firewall.json profile and firewall_rule.json object, as well as adding additional disposition_id options to reflect possible firewall actions.

The following is an example AWS WAF log conforming to the firewall profile as applies to 4002.

{
    "activity_id": 1,
    "activity_name": "Get",
    "category_name": "Network Activity",
    "category_uid": 4,
    "class_name": "HTTP Activity",
    "class_uid": 4002,
    "type_name": "HTTP Activity: Get",
    "type_uid": 400503,
    "time": 1576280412771,
    "disposition": "Block",
    "disposition_id": "2",
    "time": 1576280412771,
    "metadata": {
        "product": {
            "name": "AWS WAF",
            "vendor_name": "AWS"
        },
        "feature": {
            "uid": "arn:aws:wafv2:ap-southeast-2:111122223333:regional/webacl/STMTest/1EXAMPLE-2ARN-3ARN-4ARN-123456EXAMPLE"
        },
        "log_version": "1",
        "profiles": [firewall],
        "version": "1.0.0-rc.3",
        "labels": [
            {
	            "name": "value"
            }
        ]
    },
    "src_endpoint": {
        "ip": "1.1.1.1",
        "location": {
            "country": "AU"
        }
    },
    "http_request": {
        "args": "",
        "version": "HTTP/1.1",
        "method": "GET",
        "uid": "rid",
        "user_agent": "curl/7.61.1",
        "url": {
            "hostname": "localhost:1989",
            "path": "/myUri",
            "url_string": "localhost:1989/myUri"
        },
        "headers": [
            {
	            "name": "Accept",
	            "value": "*/*"
            },
            {
	            "name": "x-stm-test",
	            "value": "10 AND 1=1"
            }
        ]
    },
    "rule": {
        "uid": "STMTest_SQLi_XSS",
        "type": "REGULAR",
        "condition": "SQL_INJECTION",
        "sensitivity": "HIGH",
        "location": "HEADER",
        "matched_data": [
            "10",
            "AND",
            "1"
        ]
    },
    "unmapped": {
        "httpSourceName": "APIGW",
        "httpSourcId": "-"
    }
}

…he firewall profile

Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
…o include the attributes for a firewall_rule

Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
…ount for the firewall profile

Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
…ass for WAF events

Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
Copy link
Contributor

@floydtree floydtree left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Specific comments inline.

General - as I mentioned in the closed PR -

I would also recommend to edit the PR description and highlight what exactly has been changed, added, removed etc. This would help in generating clearer & cleaner release notes.

objects/firewall_rule.json Outdated Show resolved Hide resolved
dictionary.json Show resolved Hide resolved
objects/firewall_rule.json Outdated Show resolved Hide resolved
dictionary.json Outdated Show resolved Hide resolved
objects/firewall_rule.json Outdated Show resolved Hide resolved
objects/firewall_rule.json Show resolved Hide resolved
dictionary.json Outdated Show resolved Hide resolved
Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
…nary

Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
dictionary.json Outdated Show resolved Hide resolved
objects/firewall_rule.json Outdated Show resolved Hide resolved
rroupski
rroupski previously approved these changes Jul 11, 2023
mikeradka
mikeradka previously approved these changes Jul 11, 2023
Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
@adplotzk adplotzk dismissed stale reviews from mikeradka and rroupski via b668c97 July 11, 2023 20:13
Signed-off-by: Adam P. <106110648+adplotzk@users.noreply.github.com>
@adplotzk adplotzk requested a review from floydtree July 11, 2023 20:16
@rroupski rroupski merged commit ed86f1c into ocsf:main Jul 11, 2023
1 check passed
@Aniak5 Aniak5 added the v1.1.0 Changes marked for v1.1.0 of OCSF label Jan 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
v1.1.0 Changes marked for v1.1.0 of OCSF
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants