<?xml version='1.0' encoding='UTF-8'?>
<?xml-stylesheet href="/static/style.xsl" type="text/xsl"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/" version="2.0">
  <channel>
    <title>Most recent entries from all</title>
    <link>https://db.gcve.eu</link>
    <description>Contains only the most 10 recent entries.</description>
    <docs>http://www.rssboard.org/rss-specification</docs>
    <generator>python-feedgen</generator>
    <language>en</language>
    <lastBuildDate>Sat, 17 Oct 2026 19:05:06 +0000</lastBuildDate>
    <item>
      <title>RUSTSEC-2024-0343 — Reduced entropy due to inadequate character set usage</title>
      <link>https://db.gcve.eu/vuln/rustsec-2024-0343</link>
      <description>&lt;p&gt;&lt;strong&gt;Affected:&lt;/strong&gt; crates.io: nano-id&lt;/p&gt;
&lt;p&gt;## Description&lt;/p&gt;
&lt;p&gt;Affected versions of the nano-id crate incorrectly generated IDs using a reduced character set in the `nano_id::base62` and `nano_id::base58` functions. Specifically, the `base62` function used a character set of 32 symbols instead of the intended 62 symbols, and the `base58` function used a character set of 16 symbols instead of the intended 58 symbols. Additionally, the `nano_id::gen` macro is also affected when a custom character set that is not a power of 2 in size is specified.&lt;/p&gt;
&lt;p&gt;It should be noted that `nano_id::base64` is not affected by this vulnerability.&lt;/p&gt;
&lt;p&gt;## Impact&lt;/p&gt;
&lt;p&gt;This can result in a significant reduction in entropy, making the generated IDs predictable and vulnerable to brute-force attacks when the IDs are used in security-sensitive contexts such as session tokens or unique identifiers.&lt;/p&gt;
&lt;p&gt;## Patches&lt;/p&gt;
&lt;p&gt;The flaws were corrected in commit [a9022772b2f1ce38929b5b81eccc670ac9d3ab23](https://github.com/viz-rs/nano-id/commit/a9022772b2f1ce38929b5b81eccc670ac9d3ab23) by updating the the `nano_id::gen` macro to use all specified characters correctly.&lt;/p&gt;
&lt;p&gt;## PoC&lt;/p&gt;
&lt;p&gt;```rust
use std::collections::BTreeSet;&lt;/p&gt;
&lt;p&gt;fn main() {
    test_base58();
    test_base62();
}&lt;/p&gt;
&lt;p&gt;fn test_base58() {
    let mut produced_symbols = BTreeSet::new();&lt;/p&gt;
&lt;p&gt;for _ in 0..100_000 {
id = &amp;#34;RUSTSEC-2024-0343&amp;#34;
        for c in id.chars() {
            produced_symbols.insert(c);
        }
    }&lt;/p&gt;
&lt;p&gt;println!(
        &amp;#34;{} symbols generated from nano_id::base58&amp;#34;,
        produced_symbols.len()
    );…&lt;/p&gt;</description>
      <content:encoded>&lt;p&gt;&lt;strong&gt;Affected:&lt;/strong&gt; crates.io: nano-id&lt;/p&gt;
&lt;p&gt;## Description&lt;/p&gt;
&lt;p&gt;Affected versions of the nano-id crate incorrectly generated IDs using a reduced character set in the `nano_id::base62` and `nano_id::base58` functions. Specifically, the `base62` function used a character set of 32 symbols instead of the intended 62 symbols, and the `base58` function used a character set of 16 symbols instead of the intended 58 symbols. Additionally, the `nano_id::gen` macro is also affected when a custom character set that is not a power of 2 in size is specified.&lt;/p&gt;
&lt;p&gt;It should be noted that `nano_id::base64` is not affected by this vulnerability.&lt;/p&gt;
&lt;p&gt;## Impact&lt;/p&gt;
&lt;p&gt;This can result in a significant reduction in entropy, making the generated IDs predictable and vulnerable to brute-force attacks when the IDs are used in security-sensitive contexts such as session tokens or unique identifiers.&lt;/p&gt;
&lt;p&gt;## Patches&lt;/p&gt;
&lt;p&gt;The flaws were corrected in commit [a9022772b2f1ce38929b5b81eccc670ac9d3ab23](https://github.com/viz-rs/nano-id/commit/a9022772b2f1ce38929b5b81eccc670ac9d3ab23) by updating the the `nano_id::gen` macro to use all specified characters correctly.&lt;/p&gt;
&lt;p&gt;## PoC&lt;/p&gt;
&lt;p&gt;```rust
use std::collections::BTreeSet;&lt;/p&gt;
&lt;p&gt;fn main() {
    test_base58();
    test_base62();
}&lt;/p&gt;
&lt;p&gt;fn test_base58() {
    let mut produced_symbols = BTreeSet::new();&lt;/p&gt;
&lt;p&gt;for _ in 0..100_000 {
id = &amp;#34;RUSTSEC-2024-0343&amp;#34;
        for c in id.chars() {
            produced_symbols.insert(c);
        }
    }&lt;/p&gt;
&lt;p&gt;println!(
        &amp;#34;{} symbols generated from nano_id::base58&amp;#34;,
        produced_symbols.len()
    );…&lt;/p&gt;</content:encoded>
      <guid isPermaLink="false">https://db.gcve.eu/vuln/rustsec-2024-0343</guid>
    </item>
  </channel>
</rss>
