RUSTSEC-2022-0017

    Dashboard / Vulnerabilities / RUSTSEC-2022-0017

    RUSTSEC-2022-0017

    Published: 27 Apr 2022Last Modified: 8 Nov 2023

    Summary: `array!` macro is unsound when its length is impure constant

    Details: Affected versions of this crate did substitute the array length provided by an user at compile-time multiple times. When an impure constant expression is passed as an array length (such as a result of an impure procedural macro), this can result in the initialization of an array with uninitialized types, which in turn can allow an attacker to execute arbitrary code. The flaw was corrected in commit [d5b63f72](https://gitlab.com/KonradBorowski/array-macro/-/commit/d5b63f72090f3809c21ac28f9cfd84f12559bf7d) by making sure that array length is substituted just once.

    Affected packages

    Package

    Name: array-macro

    Purl: pkg:cargo/array-macro

    Affected ranges

    Type: SEMVER

    Events:

    Introduced- 2.1.0
    Fixed -2.1.2

    Affected versions

    Common Vulnerability Scoring System

    Attack Vector
    Network
    Adjacent
    Local
    Physical
    Privileges Required
    None
    Low
    High
    User Interaction
    None
    Required
    Scope
    Unchanged
    Changed
    Confidentiality
    None
    Low
    High
    Integrity
    None
    Low
    High
    Availability
    None
    Low
    High
    RUSTSEC-2022-0017 | CVE-DB