Skip to main content
Glama

pentest_ctf_rsa

Analyze RSA challenges by factoring small moduli with trial division, Fermat, or Pollard rho, testing Wiener and perfect-square cases, and decrypting ciphertext when provided.

Instructions

RSA analysis: factor small n (trial/Fermat/Pollard rho), Wiener, perfect square; decrypt if c given.

Integers as decimal or 0x-hex strings to preserve precision.

Input Schema

NameRequiredDescriptionDefault
cNo
eYes
nYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

A3.9/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations at all, the description must carry the full behavioral burden. It does disclose the attack ladder and notes that c triggers decryption, but says nothing about output shape, behavior on unfactorable n (error vs. partial result), runtime limits of Pollard rho, or whether multiple methods are tried in sequence or only one is selected.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences with zero filler, front-loading the capability list and following with the input-format requirement that would otherwise cause silent precision bugs. Nothing could be removed without losing information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a three-parameter, no-annotation, no-output-schema crypto tool, the description covers what it does and how to encode inputs, which is the critical part. It still leaves the return value and failure modes undefined, so an agent cannot predict what it gets back when factoring does not succeed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description has to compensate, and it does the most important part: 'Integers as decimal or 0x-hex strings to preserve precision' explains the expected encoding for n, e, and c, and 'decrypt if c given' clarifies that c is optional and functionally distinct from the other two. It never states that n is the modulus and e the public exponent, leaving those to domain inference.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Names the specific resource (RSA) and enumerates the exact techniques it applies: factoring small n via trial/Fermat/Pollard rho, Wiener's attack, perfect-square detection, and decryption when c is supplied. This is far more specific than the sibling CTF tools (hash_crack, cipher_brute), so an agent can route an RSA problem here unambiguously.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The phrase 'decrypt if c given' tells the agent the one conditional branch it controls (supply c to get plaintext, omit it for pure analysis), and 'small n' implicitly scopes applicability. However, there is no explicit when-not guidance, no mention of what to do when factoring fails, and no reference to alternative siblings for non-RSA problems.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools