Skip to content
vetkitChecksChangelogDocumentation

vetkit.rust.crypto.hardcoded-key

An encryption key is a byte-string literal compiled into the program.

Last updated:

Suite: Security

rust

An encryption key is a byte-string literal compiled into the program.

Category: SECURITY · Engine rule severity: ERROR

How to fix it

Load the key at runtime from the environment, a key file or a secret manager, and rotate the value that was committed.

References

Source: packages/engine/rules/sast/rust.yml.

Generated from shipped rule definitions at build time. Matching is a review signal, not proof of exploitability. “generic” denotes text matching, not complete language or framework coverage. Runtime configuration and available tools affect whether a rule runs.