sanitize_config
Strip sensitive values from network configs by redacting passwords, keys, secrets, and hashes; map IPs, MACs, hostnames, and domains to stable placeholder ranges. Get clean text and redaction counts.
Instructions
Scrub a config before it goes anywhere: passwords, secrets, RADIUS/TACACS keys, IPsec PSKs, SNMP communities, MD5 digests, Wi-Fi PSKs, key/certificate blocks and hashes are redacted; IPv4 addresses are mapped consistently to RFC 5737 documentation ranges (same address, same placeholder, so the logic still reads), IPv6 to 2001:db8::, MACs to the RFC 7042 range, hostnames to ROUTER-n, domains and emails to example.com. Subnet and wildcard masks are preserved. Returns the clean text and a count per category.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| config | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |