CVE-2022-0240

Source
https://cve.org/CVERecord?id=CVE-2022-0240
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-0240.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2022-0240
Downstream
Related
Published
2022-01-17T13:35:10Z
Modified
2026-07-22T01:09:43.979385Z
Severity
  • 6.2 (Medium) CVSS_V3 - CVSS:3.0/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H CVSS Calculator
Summary
NULL Pointer Dereference in mruby/mruby
Details

mruby is vulnerable to NULL Pointer Dereference

Database specific
{
    "cwe_ids": [
        "CWE-476"
    ],
    "cna_assigner": "@huntrdev",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/0xxx/CVE-2022-0240.json"
}
References

Affected packages

Git / github.com/mruby/mruby

Affected ranges

Type
GIT
Repo
https://github.com/mruby/mruby
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed
Fixed
Database specific
{
    "source": [
        "CPE_RANGE",
        "REFERENCES"
    ],
    "cpe": "cpe:2.3:a:mruby:mruby:*:*:*:*:*:*:*:*",
    "extracted_events": [
        {
            "introduced": "0"
        },
        {
            "fixed": "3.2"
        }
    ]
}

Affected versions

1.*
1.0.0
1.1.0
1.2.0
3.*
3.0.0-preview
3.2.0-rc
3.2.0-rc2
3.2.0-rc3
3.2.0-rc4

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-0240.json"
vanir_signatures
[
    {
        "source": "https://github.com/mruby/mruby/commit/31fa3304049fc406a201a72293cce140f0557dca",
        "signature_type": "Function",
        "signature_version": "v1",
        "digest": {
            "function_hash": "210927324186277684094554442999599709031",
            "length": 1039.0
        },
        "id": "CVE-2022-0240-4c0339a5",
        "target": {
            "function": "prepare_singleton_class",
            "file": "src/class.c"
        },
        "deprecated": false
    },
    {
        "source": "https://github.com/mruby/mruby/commit/31fa3304049fc406a201a72293cce140f0557dca",
        "signature_type": "Function",
        "signature_version": "v1",
        "digest": {
            "function_hash": "243804329852572144038442603560103494293",
            "length": 468.0
        },
        "id": "CVE-2022-0240-80df04ba",
        "target": {
            "function": "mrb_singleton_class_ptr",
            "file": "src/class.c"
        },
        "deprecated": false
    },
    {
        "source": "https://github.com/mruby/mruby/commit/31fa3304049fc406a201a72293cce140f0557dca",
        "signature_type": "Line",
        "signature_version": "v1",
        "digest": {
            "line_hashes": [
                "127250216515249212176059722088213024895",
                "65046484168329266562541326136945861373",
                "90515491667773935949452959684367397961",
                "148757349669851346523609320848136781229",
                "180356075579912771970580110694850219793",
                "56049778565867878013645063959732797828",
                "97747634495783163617099420628214467016"
            ],
            "threshold": 0.9
        },
        "id": "CVE-2022-0240-c2fab708",
        "target": {
            "file": "src/class.c"
        },
        "deprecated": false
    }
]
vanir_signatures_modified
"2026-07-22T01:09:43Z"