cloud-iam-deep
하는 일
이 스킬은 자격 증명이 발견된 뒤 클라우드 아이덴티티의 권한을 점검하는 과정을 보안 테스터에게 안내합니다. AWS, Azure, Google Cloud를 다루며, 회사의 클라우드 계정에 대한 승인된 테스트를 위한 것입니다.
사용하는 경우
- ✓승인된 테스트 중 클라우드 액세스 키나 서비스 계정 파일이 발견될 때.
- ✓웹 결함이 클라우드 메타데이터 서비스에 닿을 수 있을 때.
- ✓클라우드 계정에서 아이덴티티가 어떤 권한을 가지는지 확인해야 하는 경우.
스킬 링크
https://github.com/elementalsouls/Claude-BugHunter/blob/main/skills/cloud-iam-deep/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“승인된 테스트 중 AWS 키를 찾았습니다. 이 키가 어떤 권한을 가지고 어디까지 닿는지 확인해 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
에이전트는 자격 증명 유형을 확인한 다음, 클라우드 명령줄 도구로 아이덴티티의 권한과 역할을 나열합니다. 그 결과가 계정 소유자에게 무엇을 뜻하는지 설명합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
When to use
Trigger when:
- A cloud credential surfaces (key, secret, token, JSON file)
- SSRF chain reaches IMDS / metadata endpoint
- APK / git-leak reveals embedded cloud key
- Recon shows public S3/GCS/Azure-blob with permissions you can verify
- A Kubernetes API or service-account token is exposed
- Post-RCE on a cloud-hosted instance — pivot to cloud control plane
Do NOT use for:
- On-prem-only environments (use AD attack skills — but those are out of scope per external-only boundary)
- Web2 vulns that happen to be on AWS — use the relevant
hunt-*skill
Credential identification (first 60 seconds)
# AWS access key patterns
AKIA[0-9A-Z]{16} # IAM user access key (long-term)
ASIA[0-9A-Z]{16} # STS temporary credential
AGPA[0-9A-Z]{16} # IAM group
AIDA[0-9A-Z]{16} # IAM user (user-id)
AROA[0-9A-Z]{16} # IAM role
ANPA[0-9A-Z]{16} # Managed policy
# AWS secret pattern (40-char base64-ish — context required)
[A-Za-z0-9/+=]{40} # AWS secret access key
# Azure
AccountKey=[A-Za-z0-9+/=]{86} # Storage account key
client_secret pattern + UUID # Azure AD app credential
# GCP service account JSON
{
"type": "service_account",
"project_id": "...",
"private_key_id": "...",
"private_key": "-----BEGIN PRIVATE KEY-----..."
}
# K8s SA token (JWT format — decode to confirm)
eyJhbGciOiJSUzI1... # decode kid claim to see issuer
AWS — read-only validation (the safe first step)
# Set credential
export AWS_ACCESS_KEY_ID="AKIA..."
export AWS_SECRET_ACCESS_KEY="..."
# 1. WHO am I?
aws sts get-caller-identity
# Returns: UserId, Account, Arn
# Arn tells you: IAM user vs role, account ID, name
# 2. WHAT can I do? (the privesc question)
# Try common read-only first — failures still inform you
aws iam list-users 2>&1 | head -5
aws iam list-roles 2>&1 | head -5
aws iam list-policies 2>&1 | head -5
aws iam list-groups 2>&1 | head -5
# 3. WHAT policies are attached to me?
aws iam list-attached-user-policies --user-name <self>
aws iam list-user-policies --user-name <self> # inline policies
aws iam list-groups-for-user --user-name <self>
# 4. Service-by-service surface
aws ec2 describe-instances --max-items 1 2>&1 | head
aws s3 ls 2>&1 | head -10
aws lambda list-functions --max-items 5 2>&1 | head
aws rds describe-db-instances --max-items 5 2>&1 | head
aws secretsmanager list-secrets --max-results 5 2>&1 | head
aws ssm describe-parameters --max-results 5 2>&1 | head
# 5. Audit any cross-account / external trust
aws iam list-roles --query 'Roles[?contains(AssumeRolePolicyDocument.Statement[0].Principal.AWS, `arn:aws:iam::`)]' 2>&1 | head -20
AWS privesc patterns (24+ documented — iam_privesc techniques)
Quick lookup — if you have any of these IAM actions, escalate via the listed technique:
| You have | Escalate via |
|---|---|
iam:CreateAccessKey |
Create access key on any user → impersonate |
iam:CreateLoginProfile |
Set a console password on a user → login |
iam:UpdateLoginProfile |
Reset console password on a user |
iam:AttachUserPolicy |
Attach AdministratorAccess to self |
iam:AttachGroupPolicy |
Attach AdministratorAccess to a group you're in |
iam:AttachRolePolicy + sts:AssumeRole |
Attach to a role you can assume |
iam:PutUserPolicy |
Inline AdministratorAccess to self |
iam:PutGroupPolicy |
Inline policy on a group |
iam:PutRolePolicy |
Inline on a role you can assume |
iam:AddUserToGroup |
Add self to admin group |
iam:UpdateAssumeRolePolicy + sts:AssumeRole |
Modify trust to allow self |
iam:CreatePolicyVersion |
Create v2 of an attached policy with admin |
iam:SetDefaultPolicyVersion |
Switch attached policy to admin version |
iam:PassRole + ec2:RunInstances |
Launch EC2 as admin role → use instance creds |
iam:PassRole + lambda:CreateFunction/InvokeFunction |
Run code as admin role |
iam:PassRole + cloudformation:CreateStack |
CF stack creates resources as admin |
iam:PassRole + glue:CreateDevEndpoint |
Notebook runs as admin role |
iam:PassRole + datapipeline |
Pipeline runs as admin role |
iam:PassRole + codestar:CreateProject |
New project gets admin role |
ec2:RunInstances (with admin instance profile already on the AMI) |
Spin instance, exfil creds from IMDS |
lambda:UpdateFunctionCode (function has admin role) |
Replace code → exfil creds |
| `lambda |
자주 묻는 질문
온프레미스 시스템을 위한 것인가요?
아닙니다. 스킬은 온프레미스만 있는 환경은 다른 스킬이 다룬다고 설명합니다.
어떤 클라우드를 지원하나요?
AWS, Azure, Google Cloud와 Kubernetes 서비스 계정 토큰을 다룹니다.
어떤 자격 증명 형식을 알아보나요?
AWS 액세스 키 접두사, Azure 스토리지 키, Google 서비스 계정 JSON 파일 같은 흔한 형식을 알아봅니다.
상세 정보
작성자의 원본 설명
Cloud IAM red-team attack chain across AWS, Azure, GCP — focused on EXTERNAL exploitation paths and post-credential-discovery privilege analysis. Covers IAM enumeration (aws iam, az role, gcloud iam), STS/AssumeRole chaining, Azure Managed Identity abuse (via SSRF/leak), GCP service account JSON abuse, IMDSv1/v2 attacks via SSRF, K8s ServiceAccount token privilege analysis once held (token discovery / cluster exposure is owned by hunt-k8s), role-trust-policy confused-deputy, cross-account assume-role enumeration, IAM privilege escalation patterns (24+ AWS, 8+ Azure, 6+ GCP), and AWS Cognito Id
인기도
- GitHub 스타
- 5.4k
- 순위
- #14889
- 라이선스
- MIT
- 업데이트
- 2026. 11. 2.
댓글
- …
이 저장소의 다른 스킬
apk-redteam-pipeline
5.4k에이전트가 APK 파일을 찾고 디컴파일하는 것부터 노출된 비밀 값을 확인하는 것까지, Android 앱의 보안 약점을 테스트하도록 돕습니다.
bugcrowd-reporting
5.4k에이전트가 올바른 범주를 고르고 범위 밖 이의에 답하며, Bugcrowd 취약점 보고서를 더 잘 쓰도록 돕습니다.
enterprise-vpn-attack
5.4k에이전트가 승인된 테스트 중 Cisco, Fortinet, Citrix 등의 VPN과 원격 접속 장비에서 알려진 약점을 확인하도록 돕습니다.
evidence-hygiene
5.4k에이전트가 버그 보고서에 쓸 스크린샷과 요청 로그를 준비하면서, 쿠키와 개인 정보 같은 민감한 세부 사항을 가리도록 돕습니다.