Skip to content

← Public intelligence

crates.io package

rust-embed

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

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

  1. Unratedcrates.ioPublished

    RustEmbed generated get method allows for directory traversal when reading files from disk

    GHSA-cgw6-f3mj-h742

    Affected
    • crates.io rust-embed < 6.3.0
    Fixed in
    6.3.0· Vendor fix available
    Issue
    When running in debug mode and the debug-embed (off by default) feature is not enabled, the generated get method does not check that the input path is a child of the folder given. This allows attackers to read arbitrary files in the file system if they have control over the filename given. The following code will print the contents of your /etc/passwd if adjusted with a correct number of ../s depending on where it is run from. The flaw was corrected by canonicalizing the input filename and ensuring that it starts with the canonicalized folder path.

    Recommended action: Upgrade to 6.3.0 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 →
  2. High, CVSS 7.5crates.ioPublished

    Path Traversal in rust-embed

    CVE-2021-45712 · GHSA-xrg3-hmf3-rvgw

    Affected
    • crates.io rust-embed < 6.3.0
    Fixed in
    6.3.0· Vendor fix available
    Issue
    When running in debug mode and the debug-embed (off by default) feature is not enabled, the generated get method does not check that the input path is a child of the folder given. This allows attackers to read arbitrary files in the file system if they have control over the filename given. The following code will print the contents of your /etc/passwd if adjusted with a correct number of ../s depending on where it is run from.

    Recommended action: Upgrade to 6.3.0 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 →