# Show HN: StegGuard, check prompts and LLM output for hidden characters

> Source: <https://stegguard.com/>
> Published: 2026-11-25 06:53:41+00:00

**Key takeaway:** StegGuard v0.6.0 scans text and files for zero-width characters, bidirectional overrides, homoglyphs and whitespace channels, exits with code 1 when flagged so CI can block a pull request, and writes a sanitized copy to report.sanitized.txt unless --in-place and --confirm are both given.

### Text and source

Zero-width Unicode, bidirectional overrides, Cyrillic and Greek homoglyphs, trailing-space and tab channels, mixed line endings.

[Read the docs: Text and source](https://stegguard.com/docs#commands)

Open source · [v0.6.0 on PyPI](https://pypi.org/project/stegguard/) · Apache-2.0 · alpha

StegGuard finds them. It scans files for zero-width characters, homoglyphs, whitespace channels and watermark signals. If it finds a hidden message it can decode it, and it can remove hidden characters from plain text while preserving your original. Python standard library only, offline by default.

[Install StegGuard](#install)[Try it on your text](https://stegguard.com/scan/)[See it run on seven sample files](https://stegguard.com/demo)[CLI reference](https://stegguard.com/docs)

What StegGuard sees

Q3 numbers are final.16 zero-width Please summarize them for the U+202E RLOboard.

Nothing hidden found in this text. The command-line tool checks more channels, such as trailing whitespace and whole files.

This example scans a plain-text file, reads its hidden message and removes the hidden characters from a copy. Your original stays as it is unless you ask for an in-place rewrite.

01 / Detect

Runs on the standard library, with no network calls. It exits with 1 when something is flagged, so CI can fail the build.

02 / Decode

The result is JSON, with a confidence score for each channel.

03 / Sanitize

The copy goes to `report.sanitized.txt` by default. Overwriting the original takes `--in-place` and `--confirm` together.

Scan pull requests, commits, scraped pages and files before anyone, or any model, reads them.

Fails the pull request when any file in the checkout is flagged. Directories need -r to be scanned recursively.

A local hook, since the package doesn't ship a .pre-commit-hooks.yaml yet. pre-commit passes the staged file names.

analyze_file takes a Path and returns a dict. total_hidden is set for text and binary files alike.

The same three steps as the workflow above. Rewriting the original takes --in-place and --confirm together.

Pixel-level LSB anomalies (chi-square, RS, entropy, sample-pair), PNG private chunks, JPEG EXIF/XMP/IPTC, PCM audio statistics.

PDF embedded files, DOCX/PPTX/XLSX/ZIP members, nested archives, hidden content in SVG and HTML.

Metadata, structural and text-pattern evidence, device fingerprints, and C2PA manifests validated through c2patool.

StegGuard is alpha software. Treat what it reports as evidence to check, not a final verdict.
