agents-harden

agents-harden is a skill for Claude Code from aws/agent-toolkit-for-aws. It costs 204 tokens per session (7,300 once invoked), scanned A, original, Apache-2.0.

A checklist workflow for preparing an AWS AgentCore agent for production. It reviews access permissions, authentication, secrets, startup time, sessions, rate limits, input checks, and quotas.

In plain words
What is it for?
Use it to review an AgentCore project configuration, restrict IAM access, configure authentication, manage long-running work, or investigate throttling and quota problems.
Why use it?
It helps identify security, reliability, and scaling issues before an agent is launched or when it encounters operational limits.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Part of the aws-agents plugin — 8 skills shipped together

Good fit Use it to review an AgentCore project configuration, restrict IAM access, configure authentication, manage long-running work, or investigate throttling and quota problems.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/aws/agent-toolkit-for-aws/agents-harden
About the project

Agent Toolkit for AWS is a collection of AWS-supported MCP servers, skills, plugins, commands, and hooks that help AI coding agents build, deploy, and manage applications on AWS. It is used by developers working with AWS services through agents such as Claude Code, Codex, Cursor, and Kiro. The catalogue entries are the toolkit's own agent extensions for AWS development and operations.

aws/agent-toolkit-for-aws · 2,559 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add aws/agent-toolkit-for-aws --skill agents-harden
Clone the repo
git clone --depth 1 https://github.com/aws/agent-toolkit-for-aws

Made for: Claude Code.

Or install aws-agents, the plugin that ships this one along with the rest of its 8 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for agents-harden

README.md
[![agentmods](https://agentmods.dev/badge/skills/aws/agent-toolkit-for-aws/agents-harden/github.svg)](https://agentmods.dev/skills/aws/agent-toolkit-for-aws/agents-harden)
Your own site
<a href="https://agentmods.dev/skills/aws/agent-toolkit-for-aws/agents-harden"><img src="https://agentmods.dev/badge/skills/aws/agent-toolkit-for-aws/agents-harden/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for agents-harden

Your own site · 80×15
<a href="https://agentmods.dev/skills/aws/agent-toolkit-for-aws/agents-harden"><img src="https://agentmods.dev/badge/skills/aws/agent-toolkit-for-aws/agents-harden.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 204 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 7,300 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • Socket pass 7 May 2026
  • Snyk pass 7 May 2026
  • NVIDIA SkillSpector pass 7 Sept 2026
SkillSpector: 1 finding, up to low

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • low Privilege Escalation · line 122
    Skill requests more permissions than appear necessary for its stated functionality. Review if elevated access is justified.
    Fix: Request only the minimum permissions required. Document why each permission is needed. Remove broad permissions like '*' or 'all'.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00204 $0.07300
Opus 5 $0.00102 $0.03650
Sonnet 5 $0.00041 $0.01460
Haiku 4.5 $0.00020 $0.00730

Measured 9d ago against content hash 6207879b9d76, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

agents-harden scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/aws-agents/skills/agents-harden/SKILL.md · 705 lines

How it starts

The opening of the file, as written. The whole thing — 705 lines — stays where its author put it; the contents beside it link to each section on GitHub.

harden

Prepare your AgentCore agent for production — security, reliability, and performance.

When to use

  • You're about to take an agent to production
  • You want a checklist of what to review before launch
  • You want to restrict who can call your agent
  • You want to scope down IAM permissions from the defaults
  • You're hitting throttling or quota errors (loads references/limits.md)
  • You need to tune session lifecycle for your workload
  • You're running long-running background work in your agent

Input

No arguments required. The skill reads your project config and produces a checklist with specific findings for your project.

Process

Step 0: Verify CLI version

Run agentcore --version. This skill requires v0.9.0 or later. If the version is older, tell the developer to run agentcore update before proceeding.

Step 1: Read the project

Read agentcore/agentcore.json to understand:

  • What resources are configured (memory, gateway, credentials, evaluators)
  • What framework is being used
  • What network mode is configured (PUBLIC or VPC)

Step 2: Run through the checklist

Work through each category and report findings specific to the project.


IAM: Scope down permissions

The auto-created execution role has broad Bedrock access (arn:aws:bedrock:*::foundation-model/*). For production, scope it to the specific models your agent uses.

Check the current execution role:

agentcore status --json | jq -r '.runtimes[0].executionRoleArn'

Recommended production Bedrock policy:

{
  "Effect": "Allow",
  "Action": [
    "bedrock:InvokeModel",
    "bedrock:InvokeModelWithResponseStream"
  ],
  "Resource": [
    "arn:aws:bedrock:<REGION>::foundation-model/anthropic.claude-sonnet-4-5-20250929-v1:0"
  ]
}

Replace the resource ARN with the specific model(s) your agent uses.

ECR access: Scope to your specific repository:

{
  "Effect": "Allow",
  "Action": ["ecr:BatchGetImage", "ecr:GetDownloadUrlForLayer"],
  "Resource": "arn:aws:ecr:<REGION>:<YOUR_ACCOUNT_ID>:repository/bedrock-agentcore-<AGENT_NAME>-*"
}

Read the full file on GitHub · 705 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 705 lines · 204 tokens per session scan A 6207879b9d76

Subscribe to this mod's changes

agents-harden is a skill published in the GitHub repository aws/agent-toolkit-for-aws (2,559 stars, last pushed today), licensed Apache-2.0. It adds 204 tokens to every session and 7,300 once invoked, about $0.0010 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

next-cache-components-optimizer

Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…

vercel/next.js · 170 tokens

next-partial-prefetching-adoption

Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…

vercel/next.js · 103 tokens

chronicle

Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…

microsoft/vscode · 72 tokens