Redact secrets from a config file
ENVSHIELDRun a config file, log or .env through ENVSHIELD before you paste it into a bug report, gist or chat. It masks the keys, tokens, passwords and private keys and leaves the readable settings alone.
Free to open and check one file at a time. Saving the result needs a paid plan. PDF Studio’s Privacy Scrubber cleans a batch and lists what it removed.
How it works
ENVSHIELD reads the .env, YAML, JSON or log you paste, in this tab. It masks a value when its name says it is secret (KEY, TOKEN, PASSWORD and the like) or when its shape does (a known key prefix, a PEM block, a password in a connection string, a long random string). The readable settings around them are left alone.
In more detail
What it masks, and how it finds it
Two ways, because neither is enough alone.
- By the name on the left. Anything whose key contains
KEY,TOKEN,SECRET,PASSWORD,PASSWD,AUTH,CREDENTIAL,PRIVATE,SALTorSIGNATURE. This is what catches a house-named variable nothing else would recognize. - By the shape on the right. The prefixes real
services use (
sk_live_,AKIA,ghp_,xox,eyJfor a JWT), a PEM block between itsBEGINandENDlines, a connection string with a password inside the URL, and long high-entropy strings that are not words. This is what catches a secret in a key calledvalue.
It leaves the readable settings alone, which is the point: a config file with every value masked is no use in a bug report. Ports, hostnames, feature flags, log levels and timeouts stay as they are.
What it cannot see
- A secret that looks like an ordinary word. A
password of
correct-horsein a field callednotehas neither a telling name nor a telling shape. - A secret in prose. "I set the admin password to hunter2 last Tuesday" in a log line is a sentence.
- Anything that is sensitive for a reason other than being a secret. Internal hostnames, private IP ranges, S3 bucket names, customer identifiers and the path layout of your servers are all reconnaissance, and none of them is a credential. Read what you are pasting.
Rotate anyway
The important thing, and the thing masking cannot do for you: if a real key has already been in a ticket, a gist, a chat or a screenshot, masking a later copy does not help. It is out. Rotate it. Secret scanners run continuously against public repositories and paste sites, and the interval between a key appearing and being used is frequently measured in minutes.
Use this before the first paste, not after. For a network capture or a curl command rather than a config file, INTERCEPT does the same job on that shape of text.
Questions people ask about ENVSHIELD
How do I share a config file without leaking the secrets?
Replace the values, not the keys. Whoever receives it needs to know which variables exist and what shape their values take; they do not need the live credentials. Keep the names and substitute obvious placeholders, so the file still documents the configuration and carries nothing that works.
I committed an API key to git. Is deleting it enough?
No. A commit that removed the key leaves the earlier commit containing it in the history, and anyone with the repository, or a fork, or a cached copy, can still read it. The only reliable response is to revoke and rotate the key immediately, and treat rewriting the history as tidying up afterwards rather than the fix.
Which values in a config file are actually secret?
Anything that grants access or identifies you: tokens, passwords, private keys, connection strings with credentials in them, webhook URLs, and signing secrets. Hostnames, ports, feature flags and log levels are usually safe, but an internal hostname still tells a stranger about your network, so it is worth a second look.
How does ENVSHIELD decide what to mask?
Three ways. By known secret shapes: AWS, GitHub, PayPal, Slack and Google keys, JWTs, PEM private keys and basic-auth URLs. By secret-looking key names such as password, token, secret and api_key. And by high entropy, for values that look random. Readable settings such as ports, hostnames and flags are left alone.
Is the masked output guaranteed to be clean?
No. ENVSHIELD is a safety net, not a guarantee. Always review the output before sharing it, and rotate any secret that has already been exposed.
Is my config file uploaded?
No. ENVSHIELD runs entirely in your browser and never uploads or transmits your file. The redacted copy is written in the tab for you to copy or download.
Who can see your file
| Who | Can they see it? |
|---|---|
| You | Yes |
| OBSCURA OS | No. Your file never reaches us. |
| Someone who breaks into our servers | No. Your file is not there. |
| Advertisers or partners | No. |
| Anyone using your unlocked computer, or a harmful browser extension | Yes. Keep your device and browser clean. |