CVE-2025-13353

5.5 MEDIUM

📋 TL;DR

A vulnerability in gokey versions before 0.2.0 causes passwords derived from seed files to use only 28 bytes of entropy instead of the intended 240 bytes. This allows attackers with access to the seed file to recover all passwords generated from that seed without needing the master password. Only users who generated passwords/secrets using the -s option with seed files are affected.

💻 Affected Systems

Products:
  • gokey
Versions: All versions < 0.2.0
Operating Systems: All platforms running gokey
Default Config Vulnerable: ✅ No
Notes: Only affects password/secret generation when using the -s option with seed files. Master password-only generation is not affected.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete compromise of all passwords/secrets generated from a seed file if an attacker obtains the seed file, enabling unauthorized access to all systems using those credentials.

🟠

Likely Case

Reduced entropy in generated passwords making them more susceptible to brute-force attacks, with potential credential compromise if seed files are exposed.

🟢

If Mitigated

Limited impact if seed files are properly secured and access controlled, though generated passwords still have lower entropy than intended.

🌐 Internet-Facing: MEDIUM - Risk depends on whether seed files are exposed to internet-accessible systems or repositories.
🏢 Internal Only: MEDIUM - Internal attackers with access to seed files could compromise all derived credentials.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: LIKELY
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires access to the seed file. The vulnerability is in deterministic password generation logic.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 0.2.0 and above

Vendor Advisory: https://github.com/cloudflare/gokey/security/advisories/GHSA-69jw-4jj8-fcxm

Restart Required: No

Instructions:

1. Upgrade gokey to version 0.2.0 or higher. 2. Regenerate all passwords/secrets that were created using seed files with the -s option. 3. Rotate these new credentials in all systems.

🔧 Temporary Workarounds

Stop using seed files

all

Generate passwords using master password only without -s option until patched

gokey -m "master_password" generate

🧯 If You Can't Patch

  • Secure all seed files with strict access controls and encryption
  • Assume all passwords generated from seed files are compromised and plan for credential rotation

🔍 How to Verify

Check if Vulnerable:

Check gokey version: if version < 0.2.0 and you've used -s option with seed files, you're vulnerable

Check Version:

gokey --version

Verify Fix Applied:

After upgrading to 0.2.0+, regenerate passwords from same seed file - they should be different from previous versions

📡 Detection & Monitoring

Log Indicators:

  • Unauthorized access attempts using potentially compromised credentials

Network Indicators:

  • Suspicious authentication patterns from unexpected locations

SIEM Query:

Search for authentication failures followed by successes with same credentials, or multiple systems accessed with same credential in short timeframe

🔗 References

📤 Share & Export