pentesting-with-aws-security-agent
An agent skill by aws, from aws/agent-toolkit-for-aws. Tags: cloud, security, testing, validation, web.
What it does
Run an AWS Security Agent penetration test against a live web application — registers and verifies the target domain, exercises the supplied endpoints with the managed Security Agent service, and returns verified runtime findings. Use when the user asks to pentest, run a penetration test, test their app's attack surface, find runtime vulnerabilities, register or verify a target domain, or check pentest status / findings.
Install
With the skills CLI, which installs into Claude Code, Codex, Cursor and other agents:
npx skills add aws/agent-toolkit-for-aws --skill pentesting-with-aws-security-agent
Or copy the skill folder into Claude Code's skills directory by hand (~/.claude/skills for every project, or .claude/skills inside one):
git clone --depth 1 https://github.com/aws/agent-toolkit-for-aws
cp -r agent-toolkit-for-aws/plugins/aws-agents-for-devsecops/skills/pentesting-with-aws-security-agent ~/.claude/skills/pentesting-with-aws-security-agent
Safety box score
Grade C, moderate risk: 39 of 100 risk points, rated 2026-10-15. The grade rates what the skill and its scripts can reach on the machine of whoever installs it, across eight categories from shell execution to secrets access. How the score works.
This skill runs an AWS Security Agent penetration test against a live web application, creating/verifying target domains, starting long-running jobs, polling status, and writing a detailed local report. The main risks are active network testing of arbitrary user-supplied endpoints, use of the caller’s AWS credentials, and persistent writes under `.security-agent/`.
| Category | Level | Why |
|---|---|---|
| Code & shell execution | 2 (moderate) | It drives the machine by issuing shell-style AWS CLI commands and `sleep 900`, but it does not ship or evaluate arbitrary code. |
| Network access | 2 (moderate) | It sends requests to AWS Security Agent and to the target application via `--assets endpoints=[{uri=...}]` and domain verification calls; the traffic is bounded to the verified target and AWS service. |
| Filesystem reach | 1 (low) | It reads and writes only workspace-local files such as `.security-agent/config.json`, `.security-agent/pentests.json`, and `.security-agent/pentest-{pentest_job_id}.md`. |
| Secrets & credentials | 2 (moderate) | It depends on the user’s configured AWS identity and credentials via `aws sts get-caller-identity` and `aws securityagent ... --service-role <role-arn>`; it does not explicitly read secret files. |
| Privilege & persistence | 0 (none) | There is no `sudo`, service installation, shell startup editing, or other OS-level privilege change in the skill text. |
| Instruction hijack surface | 0 (none) | The skill does not ask the agent to ignore its rules, fetch hidden instructions, or skip confirmations; it explicitly says to confirm authorization before starting. |
| Irreversible actions | 3 (high) | It can autonomously create target-domain registrations, start/stop pentest jobs, and poll until completion, which is an active external action against a live target. |
| Transparency | 0 (none) | The skill is plain markdown with visible commands; there are no binaries, minified blobs, or remote/dynamic code fetches. |
Before installing
- Use a dedicated AWS test account or role before letting it run `aws securityagent` commands.
- Review the local write paths: `.security-agent/config.json`, `.security-agent/pentests.json`, and `.security-agent/pentest-*.md`.
- Confirm the target domain verification route is on a non-production copy or a system you explicitly own/are authorized to test.
- Be prepared for long-running active testing traffic against the listed endpoints.
Rated 2026-10-15 by an automated review of 1 file from the skill's repository.
Source
- Repository
- aws/agent-toolkit-for-aws (all skills from this repository)
- Path
- plugins/aws-agents-for-devsecops/skills/pentesting-with-aws-security-agent/SKILL.md
- Branch
- main
- Collection
- aws-agents-for-devsecops
- Updated
- 2026-09-19
Related skills
- scanning-with-aws-security-agent — Run an AWS Security Agent scan on the workspace — uploads the source to AWS, scans it with the managed Security Agent service, and returns ranked.
- agents-harden — Use when preparing your agent for production — IAM scoping, inbound auth (JWT, SigV4), secrets management, cold start optimization, session lifecycle.
- agents-pay — Use when THIS agent needs to pay for x402-protected content at runtime: hitting a paywall mid-task, settling it via AgentCore Payments.
- aws-cloudformation — Authors, validates, and troubleshoots AWS CloudFormation templates.
- aws-iam — Provides verified corrections for IAM behaviors that AI agents frequently get wrong — policy evaluation edge cases, trust policy gotchas, STS session limits.
- aws-networking — Routes AWS networking requests to the correct service skill for implementation.