# Log Redactor

Redact common sensitive fields, private-key blocks, URL credentials, JWT-like tokens, emails, and IPs before manually reviewing logs for sharing.

## URL

https://ilham.dev/tools/log-redactor/

## What It Does

Replace common sensitive patterns with a fixed [REDACTED] marker before sharing log text. Patterns include sensitive-field lines, PEM private keys, URL credentials, JWT-like tokens, common email forms, IPv4, and IPv6. Add case-sensitive exact text for values the automatic patterns miss. Input processing stays in the browser without tool storage or upload.

## Features

- Replace common sensitive-field lines and PEM private-key blocks
- Detect URL credentials, JWT-like tokens, common emails, IPv4, and IPv6
- Add case-sensitive exact-text redactions without regex
- Preview results and overlapping per-category match counts
- Copy or download only the redacted preview

## Input

Log excerpt and optional exact-text entries text input.

## Output

Redacted log with a fixed marker text output.

## Privacy

Processing happens locally in the browser.

No input data is uploaded to ilham.dev.

- Requires login: false
- Requires API key: false
- Stores user data: false


## Examples

- Does the tool guarantee that no secrets remain?
- Why did it remove the rest of a line or the remaining log?
- Are the original logs stored or uploaded?
- Does exact-text matching support regex or ignore case?


## Limitations

- Best-effort pattern detection, not an anonymization or secret-removal guarantee
- Sensitive fields redact the rest of a line and ambiguous values can hide the remaining input
- Output may no longer be valid JSON or logfmt
- No comprehensive encoded-secret, arbitrary multiline, or personal-data detection
- Maximum 500,000 log characters and 20,000 detected matches


## Related Tools

- https://ilham.dev/tools/docker-logs-grep/
- https://ilham.dev/tools/log-parser/
- https://ilham.dev/tools/string-obfuscator/


## Questions

### Does the tool guarantee that no secrets remain?

No. Detection is best-effort and can miss secrets, encoded values, unusual field names, multiline structures, and personal data. Review the output manually before copying or downloading it.

### Why did it remove the rest of a line or the remaining log?

A recognized sensitive assignment hides the rest of its line. If its value is missing, starts with an object or array, or has an unclosed quote, the remaining log is hidden conservatively. An unclosed PEM private-key block also hides the remaining log. This can remove harmless context and break JSON syntax.

### Are the original logs stored or uploaded?

The tool does not upload or save log text or exact-text entries. Originals remain visible in the input area until cleared. Only the redacted preview is used by the copy and download actions.

### Does exact-text matching support regex or ignore case?

Neither. Each non-empty line is a case-sensitive literal match, with spaces preserved. Entries need at least three characters. There can be at most 100 distinct entries and 10,000 characters in the list.

