Merge pull request 'docs(skill): add secure local environment secrets workflow' (#70) from docs/secure-env-secrets-skill into main
Heimdall Gitea / Build and tests (push) Successful in 17m44s
Heimdall Gitea / Publish versioned release (push) Skipped
Heimdall Gitea / Build and scan server image (push) Successful in 5m34s
Heimdall Gitea / Build and scan agent image (push) Successful in 9m7s
Heimdall Gitea / Publish Docker Hub latest tags (push) Canceled after 0s
Heimdall Gitea / Build and tests (push) Successful in 17m44s
Heimdall Gitea / Publish versioned release (push) Skipped
Heimdall Gitea / Build and scan server image (push) Successful in 5m34s
Heimdall Gitea / Build and scan agent image (push) Successful in 9m7s
Heimdall Gitea / Publish Docker Hub latest tags (push) Canceled after 0s
This commit was merged in pull request #70.
This commit is contained in:
commit
5f0f970f65
2 files changed
+18
-17
No files matched your search
@@ -1,28 +1,28 @@
|
||||
---
|
||||
name: secure-env-secrets
|
||||
description: Securely read or store a user-provided secret as a local environment variable outside the repository. Use when the user asks to keep a secret available to local commands or applications; this does not configure CI or remote services.
|
||||
description: Store or retrieve a user-provided secret as a local environment variable outside repositories, without exposing its value in commands or output. Does not configure CI or remote services.
|
||||
---
|
||||
|
||||
# Secure user environment variables
|
||||
# Secure local environment secrets
|
||||
|
||||
Handle only secrets the user supplied or explicitly authorized you to retrieve. Secret values must stay outside every repository. Never repeat a value in commentary, tool output, logs, diffs, command history, process arguments, or a final response.
|
||||
Use this skill only for secrets the user supplied or explicitly authorized you to retrieve. Keep values outside repositories and never repeat them in commentary, tool output, logs, diffs, or a final response.
|
||||
|
||||
## Choose scope and storage
|
||||
|
||||
- Ask only for missing details that affect use: variable name, target application or command, and whether it needs one-command, current-shell, or persistent user-session scope.
|
||||
- Prefer the operating system credential store or an existing user secret manager. Read from it at process launch and pass the value only to the process that needs it.
|
||||
- An environment variable is inherited by child processes and visible to processes running as the same user. It is a delivery mechanism, not encrypted storage.
|
||||
- Do not write secrets to project `.env` files, shell startup files, system-wide environment configuration, Compose files, source code, CI workflows, test fixtures, or synced/shared directories by default.
|
||||
- If a persistent local environment file is specifically needed and no credential store is available, use a user-owned directory outside all involved repositories (for example, `$XDG_CONFIG_HOME/heimdall` or `~/.config/heimdall`). Set the directory to mode `0700` and the file to `0600`. Explain that permissions restrict other accounts but do not encrypt the file. Never commit the file.
|
||||
- Load a persistent file only for the requested process or shell. Do not add automatic loading to shell startup configuration unless the user explicitly requests it.
|
||||
- Prefer the operating system credential store or an existing secret manager, and expose a value only to the process that needs it.
|
||||
- A secret in an environment variable is available to same-user processes and is not a secure store. Do not add secrets to global shell startup files by default.
|
||||
- If the user needs persistence and no credential store is available, use a user-owned directory outside every repository, with directory permissions `0700` and file permissions `0600`. Explain that permissions restrict other accounts but do not encrypt the file. Avoid synced/shared locations unless requested.
|
||||
- Keep a persistent file inert data (for example, base64-encoded values keyed by validated variable names); do not source a file containing arbitrary shell code. Load a requested value only in the shell/process that needs it, without printing it.
|
||||
|
||||
## Read and write without disclosure
|
||||
## Read or write safely
|
||||
|
||||
1. Resolve and verify that the destination is outside the current repository and any other repository involved.
|
||||
2. Before writing, check whether the named variable already exists without displaying its value. Preserve it unless the user explicitly requests replacement. Never silently overwrite or delete credentials.
|
||||
3. Receive new values through a masked prompt or the selected credential store's protected input. Do not embed a secret in a command string, here-document, command argument, URL, environment assignment, or helper variable. If the available interface would record or display the value, have the user enter it locally through a protected prompt instead.
|
||||
4. Avoid shell tracing and commands that dump environment or file contents. Never use `env`, `printenv`, `set`, `echo "$SECRET"`, or `git diff` to inspect a secret.
|
||||
5. Use the value only for the requested operation. Verify only that the variable is present and that the destination permissions are correct; never report its length, prefix, hash, or other value-derived information.
|
||||
6. Report the variable name, scope, storage path or credential-store location, and whether it is set. Do not report the value.
|
||||
1. Establish the variable name, intended scope (one command, one shell, or persistent local use), and destination. Ask only for details that change the safe implementation.
|
||||
2. Before writing, check for an existing value without displaying it. Preserve it unless the user explicitly requests replacement; do not silently delete credentials.
|
||||
3. Accept the secret through a masked prompt or credential-store protected input. Never place it in a command string, here-document, argument, URL, exported helper variable, or ordinary prompt. If the interface would expose input through tool history/output, ask the user to enter it locally and continue with metadata-only checks.
|
||||
4. Resolve and verify the destination is outside all involved repositories. Create owner-only directories and set owner-only file permissions before writing.
|
||||
5. Disable shell tracing and avoid commands that dump environment or variable values. Expose the variable only for the requested operation.
|
||||
6. Verify presence and permissions without printing or deriving information from the value. Report only the variable name, storage scope/path, and set/unset state.
|
||||
|
||||
Do not configure CI, cloud, or remote account secrets under this skill unless the user separately requests that destination and authorizes the remote change. If a secret is exposed in output or committed, stop using it and tell the user it should be rotated. Do not rotate it in an external service without authorization.
|
||||
Never use `env`, `printenv`, `set`, `echo "$SECRET"`, shell tracing, or a diff to inspect secret values. Do not place secrets in project `.env` files, Compose definitions, source code, CI workflows, or test fixtures. This skill does not configure remote CI, cloud, registry, or account secrets.
|
||||
|
||||
If a value appears in output or is committed, stop using it and tell the user it should be rotated. Do not rotate credentials in an external service unless separately authorized.
|
||||
@@ -44,6 +44,7 @@ Ce fichier remplace les rapports de `docs/audits/` et constitue le suivi courant
|
||||
- [ ] **UI groupes #138 / accès #134** Finaliser maquette et validation produit, puis vérifier l'union accès direct/groupe et les priorités dans l'interface.
|
||||
- [ ] **Localisation #142** Extraire tous les textes UI, erreurs, notifications et emails ; persister FR/EN par utilisateur, basculer sans rechargement, garder français par défaut et vérifier les clés des deux ressources.
|
||||
- [ ] **Métriques #14** Les endpoints Prometheus `/metrics` Web et Agent sont mappés. La PR #68 ajoute et valide `heimdall.signalr.connections_by_hub` sur les cinq hubs Web. La jauge de viewers existe, mais aucun producteur WebRTC n'existe avant FEAT-01. Restent la validation de scraping sur un déploiement et l'évolution réelle des mesures.
|
||||
- [x] Ajouter `.agents/skills/secure-env-secrets/SKILL.md` : procédures pour lire/écrire les secrets fournis par l'utilisateur dans l'environnement local, avec stockage persistant optionnel hors dépôt, permissions utilisateur uniquement et sans exposer la valeur. Le skill ne configure pas les secrets des workflows distants.
|
||||
- [ ] Vérifier readiness et alertes pour modèle absent, file pleine, backlog, disque, jobs bloqués, perte de configuration et échec de livraison.
|
||||
- [ ] Actualiser les guides après chaque changement d'infrastructure, routes/API et statut produit ; distinguer implémenté, validé, partiel et prévu. Vérifier une installation depuis la documentation.
|
||||
|
||||
|
||||
Reference in new issue
Block a user