Skip to content

Inconsistent schema validation when using browser mode #16

@SynqlyGabriel

Description

@SynqlyGabriel

I have found that under a certain circumstance the schema compiler will successfully compile normally but fail when compiling in browser mode. This occurs when compiling the schema with an extension that contains an object or event with a field that is named with the _dt suffix and this attribute is not defined in the dictionary. I have added an example of a definition for an object and an event that can each be used to reproduce this issue below.

Example object definition:

{
    "caption": "Example Object",
    "description": "Example object for the purpose of reproducing an OCSF schema compiler issue",
    "extends": "object",
    "name": "example_object",
    "attributes": {
        "created_time": {
            "description": "The time at which the test object was created",
            "requirement": "required"
        },
        "created_time_dt": {
            "description": "The time at which the test object was created",
            "requirement": "required"
        }
    }
}

Example event definition:

{
    "uid": 1,
    "caption": "Example Event",
    "description": "Example event for the purpose of reproducing an OCSF schema compiler issue",
    "extends": "system",
    "name": "example_event",
    "attributes": {
        "created_time": {
            "description": "The time at which the test event was created",
            "requirement": "required"
        },
        "created_time_dt": {
            "description": "The time at which the test event was created",
            "requirement": "required"
        }
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions