Skip to content
Back to skills

Audit Iteration

ASecurity

Analyze concurrent iteration and view consistency guarantees

  • 17,959 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added November 7, 2026
businessnode

Security analysis

A100/100

Scanned November 7, 2026

npx -y skills add ben-manes/caffeine --skill audit-iteration --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Audit Iteration?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Audit Iteration
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/ben-manes-audit-iteration/badge)](https://www.skillsdirectory.com/skills/ben-manes-audit-iteration)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: audit-iteration
description: Analyze concurrent iteration and view consistency guarantees
context: fork
agent: auditor
disable-model-invocation: true
---

Analyze the concurrent iteration and view behavior of the cache.

Assume at least one view operation can observe inconsistent state under
concurrent modification. If your analysis yields zero findings, re-examine
expired-but-present entries and dead/retired node visibility — explain
specifically why no user-observable inconsistency is possible.

View operations to analyze:
- asMap().entrySet/keySet/values() iteration
- asMap().forEach()
- asMap().size()
- asMap().containsValue()
- Snapshot operations (policy().eviction().hottest/coldest)

For each:
1. What consistency guarantee? (Snapshot? Weakly consistent? Sequentially consistent?)
2. Can iteration observe:
   - A retired or dead node?
   - An entry whose key/value has been garbage collected?
   - An expired but not-yet-cleaned-up entry?
   - A node with inconsistent key/value (key from one version, value from another)?
3. Can concurrent put/remove/compute cause the iterator to:
   - Skip an entry that existed for the entire iteration?
   - Return the same entry twice?
   - Throw ConcurrentModificationException?
4. Does wrapping ConcurrentHashMap iterators introduce issues CHM wouldn't have?

For each issue: construct a concrete interleaving and state whether it violates
the documented contract or is expected weakly-consistent behavior.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in business →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.