Compare commits
1 commit
3a50badb01
...
4f83588a4a
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4f83588a4a |
1 changed files with 1 additions and 1 deletions
|
|
@ -32,7 +32,7 @@ if [ -f "$FACTORY_ROOT/.env.enc" ] && command -v sops &>/dev/null; then
|
|||
# Use temp file + validate dotenv format before sourcing (avoids eval injection)
|
||||
_tmpenv=$(mktemp) || { echo "Error: failed to create temp file for .env.enc" >&2; exit 1; }
|
||||
# Verify SOPS metadata GCM ciphertext tag before decryption (integrity check)
|
||||
if ! sops verify "$FACTORY_ROOT/.env.enc" &>/dev/null; then
|
||||
if ! sops --verify "$FACTORY_ROOT/.env.enc" &>/dev/null; then
|
||||
echo "Error: SOPS verification failed — .env.enc integrity check failed, possible tampering" >&2
|
||||
rm -f "$_tmpenv"
|
||||
exit 1
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue