mirror of
https://github.com/HackTricks-wiki/hacktricks-cloud.git
synced 2025-12-27 21:23:07 -08:00
Translated ['', 'src/pentesting-cloud/aws-security/aws-post-exploitation
This commit is contained in:
@@ -4,37 +4,43 @@
|
||||
|
||||
## Secrets Manager
|
||||
|
||||
詳細については、以下を確認してください:
|
||||
For more information check:
|
||||
|
||||
{{#ref}}
|
||||
../aws-services/aws-secrets-manager-enum.md
|
||||
{{#endref}}
|
||||
|
||||
### Read Secrets
|
||||
### シークレットの読み取り
|
||||
|
||||
**シークレット自体は機密情報です**、[権限昇格ページを確認してください](../aws-privilege-escalation/aws-secrets-manager-privesc.md) それらを読む方法を学ぶために。
|
||||
The **secrets themself are sensitive information**, [check the privesc page](../aws-privilege-escalation/aws-secrets-manager-privesc.md) to learn how to read them.
|
||||
|
||||
### DoS Change Secret Value
|
||||
### DoS: シークレット値の変更
|
||||
|
||||
シークレットの値を変更することで、その値に依存する**すべてのシステムにDoSを引き起こす可能性があります。**
|
||||
シークレットの値を変更すると、その値に依存するすべてのシステムを**DoS**する可能性があります。
|
||||
|
||||
> [!WARNING]
|
||||
> 前の値も保存されているため、簡単に前の値に戻ることができます。
|
||||
> 以前の値も保存されるため、以前の値に戻すのは簡単です。
|
||||
```bash
|
||||
# Requires permission secretsmanager:PutSecretValue
|
||||
aws secretsmanager put-secret-value \
|
||||
--secret-id MyTestSecret \
|
||||
--secret-string "{\"user\":\"diegor\",\"password\":\"EXAMPLE-PASSWORD\"}"
|
||||
```
|
||||
### DoS KMSキーの変更
|
||||
### DoS Change KMS key
|
||||
|
||||
攻撃者が secretsmanager:UpdateSecret 権限を持っている場合、攻撃者が所有する KMS key を使用するよう secret を設定できます。そのキーは最初は誰でもアクセス・使用できるように設定されているため、secret を新しいキーで更新することが可能です。もしキーにアクセスできなければ、secret の更新はできません。
|
||||
|
||||
secret のキーを変更した後、攻撃者は自分のキーの設定を変更して自分だけがアクセスできるようにします。こうすると、以降のバージョンの secret は新しいキーで暗号化され、他者がアクセスできないため、secret を取得する手段が失われます。
|
||||
|
||||
なお、このアクセス不能は secret の内容が変更された後の以降のバージョンでのみ発生する点に注意してください。現行バージョンは元の KMS key で暗号化されたままだからです。
|
||||
```bash
|
||||
aws secretsmanager update-secret \
|
||||
--secret-id MyTestSecret \
|
||||
--kms-key-id arn:aws:kms:us-west-2:123456789012:key/EXAMPLE1-90ab-cdef-fedc-ba987EXAMPLE
|
||||
```
|
||||
### DoSによるシークレットの削除
|
||||
### DoS シークレットの削除
|
||||
|
||||
シークレットを削除するための最小日数は7日です。
|
||||
シークレットを削除する最小日数は7日です
|
||||
```bash
|
||||
aws secretsmanager delete-secret \
|
||||
--secret-id MyTestSecret \
|
||||
|
||||
Reference in New Issue
Block a user