Hacktoberfest 2026: as issues que os mantenedores marcaram para outubro, abertas e boas para iniciantes. Ver issues do Hacktoberfest

Static HKDF salt "RATLS" with no key versioning

Aberta
#552 2 comentários 0 reações 0 responsáveis Ver no GitHub

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
5/5
Tempo estimado
Mais de uma semana
Facilidade para iniciantes
35/100
Tipo de issue
Bug
Clareza
Razoavelmente clara
Status de atividade
Pouca atividade
Stack de tecnologia
rust

Direção de pesquisa

Comece lendo dstack/kms/src/main_service.rs e o código KDF em kdf.rs:28 para verificar como o salt estático é usado e se o impacto relatado se aplica. A issue propõe versionamento, rotação ou salts aleatórios persistidos, mas não seleciona um design; a conclusão exige uma abordagem acordada de derivação e rotação de chaves com a validação correspondente.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

security security: report security: roadmap

The disk encryption key derivation in dstack/kms/src/main_service.rs uses a hardcoded, empty HKDF salt rather than a per-instance random salt, reducing HKDF's security margin and making all derived keys deterministic given the same input keying material.

Root Cause

The RA-TLS key derivation uses a hardcoded salt b"RATLS" for all HKDF operations. There is no key versioning mechanism and no support for key rotation. If the HKDF input keying material (IKM) is compromised at any point, all historically derived keys are also compromised because the salt is static and publicly known.

// kdf.rs:28
const SALT: &[u8] = b"RATLS";

Attack Path

  1. Attacker compromises the HKDF input keying material (e.g., via a KMS vulnerability)
  2. Because the salt is static and hardcoded, the attacker can re-derive all keys ever produced by this KDF
  3. No key versioning means there is no way to distinguish keys from different epochs
  4. Key rotation requires changing the IKM, but old keys remain derivable from old IKM + static salt

Impact

No forward secrecy in the key derivation hierarchy. Compromise of the IKM at any point reveals all past and future derived keys. The static salt provides no additional entropy or domain separation beyond what the IKM already provides.

Suggested Fix

  1. Include a version number in the salt or info parameter: format!("RATLS-v{}", version)
  2. Support key rotation by allowing the salt to be updated periodically
  3. Consider using a random salt persisted alongside the derived keys

Note: This issue was created automatically. The vulnerability report was generated by Claude and has not been verified by a human.

Linguagem predominante
Rust
Estrelas
551
Forks
97
Merge médio
19h 22min
PRs com merge (30d)
109

Guia de contribuição

Abrir o guia de contribuição

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de Dstack-TEE/dstack

Todas as issues de Dstack-TEE/dstack

Issues semelhantes

Mais issues de Rust

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.