Updated
Oct 11, 2021, 12:29:50 PM

{
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "definitions": {
        "cve_id": {
            "pattern": "^CVE-[0-9]{4}-[0-9]{4,}$",
            "type": "string"
        },
        "email_address": {
            "pattern": "^([a-zA-Z0-9_\\-\\.]+)@([a-zA-Z0-9_\\-\\.]+)\\.([a-zA-Z]{2,5})$",
            "type": "string"
        },
        "lang_string": {
            "properties": {
                "lang": {
                    "type": "string"
                },
                "value": {
                    "maxLength": 3999,
                    "type": "string"
                }
            },
            "required": [
                "lang",
                "value"
            ],
            "type": "object"
        },
        "product": {
            "properties": {
                "product_name": {
                    "type": "string"
                },
                "version": {
                    "properties": {
                        "version_data": {
                            "items": {
                                "properties": {
                                    "version_affected": {
                                        "type": "string"
                                    },
                                    "version_value": {
                                        "type": "string"
                                    }
                                },
                                "required": [
                                    "version_value"
                                ],
                                "type": "object"
                            },
                            "minItems": 1,
                            "type": "array"
                        }
                    },
                    "required": [
                        "version_data"
                    ],
                    "type": "object"
                }
            },
            "required": [
                "product_name",
                "version"
            ],
            "type": "object"
        },
        "reference": {
            "properties": {
                "name": {
                    "type": "string"
                },
                "refsource": {
                    "type": "string"
                },
                "tags": {
                    "items": {
                        "type": "string"
                    },
                    "type": "array"
                },
                "url": {
                    "maxLength": 500,
                    "pattern": "^(ftp|http)s?://\\S+$",
                    "type": "string"
                }
            },
            "required": [
                "url"
            ],
            "type": "object"
        },
        "state_id": {
            "type": "string"
        }
    },
    "id": "https://scap.nist.gov/schema/nvd/feed/1.1/CVE_JSON_4.0_min_1.1_beta.schema",
    "properties": {
        "CVE_data_meta": {
            "properties": {
                "ASSIGNER": {
                    "$ref": "#/definitions/email_address"
                },
                "ID": {
                    "$ref": "#/definitions/cve_id"
                },
                "STATE": {
                    "$ref": "#/definitions/state_id"
                }
            },
            "required": [
                "ID",
                "ASSIGNER"
            ],
            "type": "object"
        },
        "affects": {
            "properties": {
                "vendor": {
                    "properties": {
                        "vendor_data": {
                            "items": {
                                "properties": {
                                    "product": {
                                        "properties": {
                                            "product_data": {
                                                "items": {
                                                    "$ref": "#/definitions/product"
                                                },
                                                "minItems": 1,
                                                "type": "array"
                                            }
                                        },
                                        "required": [
                                            "product_data"
                                        ],
                                        "type": "object"
                                    },
                                    "vendor_name": {
                                        "type": "string"
                                    }
                                },
                                "required": [
                                    "vendor_name",
                                    "product"
                                ],
                                "type": "object"
                            },
                            "minItems": 0,
                            "type": "array"
                        }
                    },
                    "required": [
                        "vendor_data"
                    ],
                    "type": "object"
                }
            },
            "required": [
                "vendor"
            ],
            "type": "object"
        },
        "data_format": {
            "enum": [
                "MITRE"
            ]
        },
        "data_type": {
            "enum": [
                "CVE"
            ]
        },
        "data_version": {
            "enum": [
                "4.0"
            ]
        },
        "description": {
            "properties": {
                "description_data": {
                    "items": {
                        "$ref": "#/definitions/lang_string"
                    },
                    "minItems": 0,
                    "type": "array"
                }
            },
            "required": [
                "description_data"
            ],
            "type": "object"
        },
        "problemtype": {
            "properties": {
                "problemtype_data": {
                    "items": {
                        "properties": {
                            "description": {
                                "items": {
                                    "$ref": "#/definitions/lang_string"
                                },
                                "minItems": 0,
                                "type": "array"
                            }
                        },
                        "required": [
                            "description"
                        ],
                        "type": "object"
                    },
                    "minItems": 0,
                    "type": "array"
                }
            },
            "required": [
                "problemtype_data"
            ],
            "type": "object"
        },
        "references": {
            "properties": {
                "reference_data": {
                    "items": {
                        "$ref": "#/definitions/reference"
                    },
                    "maxItems": 500,
                    "minItems": 0,
                    "type": "array"
                }
            },
            "required": [
                "reference_data"
            ],
            "type": "object"
        }
    },
    "required": [
        "data_type",
        "data_format",
        "data_version",
        "CVE_data_meta",
        "problemtype",
        "references",
        "description"
    ],
    "type": "object"
}