Skip to content

← Public intelligence

crates.io package

enumflags2

Open actionable advisories and recorded vendor fixes. This public package view has no inventory attached and cannot establish whether your deployment is affected. A vendor fix never resolves your finding; verify your installed version and the source guidance.

Open advisories

1 actionable advisory, newest first. Withdrawn advisories and news are excluded. Coverage is partial.

  1. Unratedcrates.ioPublished

    Adverserial use of make_bitflags! macro can cause undefined behavior

    GHSA-qvc4-78gw-pv8p

    Affected
    • crates.io enumflags2 >= 0.7.0, < 0.7.7
    Fixed in
    0.7.7· Vendor fix available
    Issue
    The macro relied on an expression of the form Enum::Variant always being a variant of the enum. However, it may also be an associated integer constant, in which case there's no guarantee that the value of said constant consists only of bits valid for this bitflag type. Thus, code like this could create an invalid BitFlags<Test, which would cause iterating over it to trigger undefined behavior. As the debug formatter internally iterates over the value, it is also affected.

    Recommended action: Upgrade to 0.7.7 or later, then redeploy and verify.A vendor fix does not resolve your finding until you verify it in your own systems.

    Sources:github.comSource checked Evidence →