pdfnative-mcp: Command for GitHub Copilot

.github/prompts/compliance-audit.prompt.md

compliance-audit is a command for GitHub Copilot from Nizoka/pdfnative-mcp. It costs 32 tokens per session (1,578 once invoked), scanned A, original, MIT.

A security and standards audit procedure for the pdfnative-mcp server, which lets an AI agent use PDF tools. It checks the boundary where model-supplied tool requests enter the server, PDF/A and PDF/X conformance, and repeatable output.

In plain words
What is it for?
Use it to audit JSON-RPC tool handling, error responses, agent-facing documentation, PDF conformance checks, and reproducibility. Each finding includes a severity, reproduction command, and suggested fix.
Why use it?
It turns suspected problems into findings that can be reproduced with a command and traced to specific files and lines. This helps maintainers catch unsafe requests, protocol errors, and non-compliant PDF output before release.

Command for GitHub Copilot

Written for GitHub Copilot: a Copilot chat mode or prompt. Also seen: agent in frontmatter; reads .claude/ paths.

This is Nizoka/pdfnative-mcp's own configuration. It tells GitHub Copilot how to work on pdfnative-mcp itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything pdfnative-mcp configures →

Reuse

Borrowing it

Nothing to install: this file belongs to Nizoka/pdfnative-mcp. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/Nizoka/pdfnative-mcp/main/.github/prompts/compliance-audit.prompt.md
Clone the repo
git clone --depth 1 https://github.com/Nizoka/pdfnative-mcp

Made for: GitHub Copilot.

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 compliance-audit

README.md
[![agentmods](https://agentmods.dev/badge/commands/nizoka/pdfnative-mcp/compliance-audit/github.svg)](https://agentmods.dev/commands/nizoka/pdfnative-mcp/compliance-audit)
Your own site
<a href="https://agentmods.dev/commands/nizoka/pdfnative-mcp/compliance-audit"><img src="https://agentmods.dev/badge/commands/nizoka/pdfnative-mcp/compliance-audit/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 compliance-audit

Your own site · 80×15
<a href="https://agentmods.dev/commands/nizoka/pdfnative-mcp/compliance-audit"><img src="https://agentmods.dev/badge/commands/nizoka/pdfnative-mcp/compliance-audit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 32 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,578 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.
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.00032 $0.01578
Opus 5.5 $0.00013 $0.00631
Sonnet 5.5 $0.00006 $0.00316
Haiku 4.5 $0.00003 $0.00158

Measured 1mo ago against content hash a06edec2b3f3, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

compliance-audit 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 1mo 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.

.github/prompts/compliance-audit.prompt.md · 101 lines

How it starts

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

Compliance Audit

Perform a compliance audit of pdfnative-mcp. The server is the untrusted-input boundary around the pdfnative engine: every argument of every tools/call comes from a model. Every finding is reproduced with a command — a test, a script, or a request sent to the built server (node dist/cli.js, after npm run build) — and cited with file:line. Report findings with a severity (blocker / major / minor / note), the reproduction command and the recommended fix; a finding without a reproducible command is not a finding.

Audit Areas

1. Protocol contract (docs/AGENT_CONTRACT.md, docs/API_STABILITY.md)

  • On stdio, stdout carries JSON-RPC frames only; every log goes to stderr (gate steps smoke and dist-probe, tests/cli-stdio.test.ts)
  • Both protocol eras are served by the same binary: MCP 2026-07-28 (server/discover) and the 2025-era initialize handshake, on stdio and on Streamable HTTP
  • A tool failure is an isError result carrying one documented ToolError code; an unknown tool name is JSON-RPC -32602 [UNKNOWN_TOOL]. No failure is uncoded (tests/engine-surface.fuzz.test.ts, tests/error-codes.test.ts)
  • structuredContent validates against the advertised outputSchema on the default, verbosity: 'summary' and fields paths (tests/schema-conformance.test.ts)
  • tools/list is a superset of the published 1.5.0 catalogue (tests/catalogue-superset.test.ts); default responses are byte-identical unless the release notes declare the change

2. Input boundary

  • Every object schema is Zod .strict(), at every nesting level, and agrees with the JSON Schema advertised for it — send a value at the edge of each new input
  • pdfBase64, DER and ICC inputs go through src/base64.ts; images through src/image.ts (magic bytes, PNG IHDR, 24 MiB per-call budget)
  • Size bounds hold: 50 MiB output, 8 MiB ICC / watermark image, 100 000-char svg, 50 000 engine blocks, 256 MiB frame; the inflate cap is operator-set
  • No __proto__ / constructor / prototype key reaches an object the server builds; Object.prototype is untouched after the fuzz suite
  • Hostile PDF bytes end in PDF_PARSE_FAILED / PASSWORD_REQUIRED / ENCRYPTION_UNSUPPORTED, never an uncoded failure, a stack overflow or a hang

Read the full file on GitHub · 101 lines

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. 1mo ago First seen · 101 lines · 32 tokens per session scan A a06edec2b3f3

Subscribe to this mod's changes

compliance-audit is a command published in the GitHub repository Nizoka/pdfnative-mcp (2 stars, last pushed 7d ago), licensed MIT. It adds 32 tokens to every session and 1,578 once invoked, about $0.0001 per session on Opus 5.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-09-26.