Skip to content

Commit e8495fd

Browse files
committed
docs(providers): read AWS STS secret from env, not process arguments
The off-AWS AWS STS refresh example expanded $AWS_SECRET_ACCESS_KEY into a --material argument, exposing the long-lived secret in the host process table (CWE-200). Use --secret-material-env aws_secret_access_key=AWS_SECRET_ACCESS_KEY so the CLI reads the value from its own environment and marks it secret. Signed-off-by: Russell Bryant <[email protected]>
1 parent 6799dcc commit e8495fd

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

‎docs/sandboxes/manage-providers.mdx‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,10 +211,13 @@ openshell provider refresh configure my-aws \
211211
--strategy aws-sts-assume-role \
212212
--material role_arn="arn:aws:iam::123456789012:role/SandboxS3Writer" \
213213
--material aws_access_key_id="$AWS_ACCESS_KEY_ID" \
214-
--material aws_secret_access_key="$AWS_SECRET_ACCESS_KEY" \
215-
--secret-material-key aws_secret_access_key
214+
--secret-material-env aws_secret_access_key=AWS_SECRET_ACCESS_KEY
216215
```
217216

217+
Pass the long-lived secret with `--secret-material-env` so the CLI reads it
218+
from its own environment instead of expanding it into a process argument,
219+
where it would be visible in the host process table.
220+
218221
Use the generic `aws` profile type for multi-service access and scope endpoints
219222
via sandbox network policy. Use `aws-s3` for S3-specific endpoint rules.
220223

0 commit comments

Comments
 (0)