CorfedoCorfedoDocs

Credential masking

Keep tokens, private keys and passwords found in your code out of search, file reads and Corfedo AI.

Corfedo masks credentials it finds in your code before it indexes a repository. Search, file reads, MCP clients, the API, the SDKs and Corfedo AI see the masked text. Masking is on for every new workspace.

What is masked

Found in codeWhat you see
A token in a known vendor format, such as ghp_…, AKIA… or xoxb-…The prefix, then * for the rest, for example ghp_************************************
A password in a URL, such as postgres://app:s3cr3t-pass@db.example.com/orderspostgres://app:***********@db.example.com/orders
The body of a private key after -----BEGIN … PRIVATE KEY-----Each body line as *

A masked value keeps its length, so line and column numbers stay the same. Values that are evidently made up, such as AKIAIOSFODNN7EXAMPLE or ${DB_PASS} in a URL, stay visible. A masked value cannot be recovered from Corfedo. Read the file in your code host when you need it.

Turn masking off or on

Change the setting

Open Settings › Privacy and use the Mask credentials in indexed code switch. Turning it off asks you to confirm.

Wait for the repositories to update

Corfedo indexes each repository again at the same commit. Repositories keep their earlier index until they are updated. The Updating repositories line under the switch counts the repositories done, waiting, failed and paused.

Check: the Updating repositories line disappears once every repository is updated.

After you turn masking back on, credentials stay visible in a repository until it is updated.

Require masking for every workspace

Whoever runs Corfedo can require masking for the whole installation, see Platform settings. The switch then shows on and cannot be changed. A workspace that had turned masking off has its repositories indexed again.

Troubleshooting

What you seeWhyWhat to do
A credential is still visible after you turned masking onIts repository is not updated yetWait until Updating repositories no longer counts it
Your installation requires this. under the switchThe installation requires maskingAsk whoever runs Corfedo
Updating repositories counts failed repositoriesIndexing them again failedSelect the count to open Repositories and read the failure
Updating repositories counts repositories as pausedIndexing is off for them, they have no working source connection, or they are too large for this installationTurn indexing on or fix the source connection in Settings › Repositories. For a repository that is too large, ask whoever runs Corfedo.
A credential in a tool result from your own editor or agentResults of tools that run on your side are not maskedRemove the credential from what your tool returns

On this page