Skip to content
Monitors Github for leaked secrets
Python Dockerfile
Branch: master
Clone or download
Type Name Latest commit message Commit time
Failed to load latest commit information.
commands Initial commit Sep 14, 2019
detectors Initial commit Sep 14, 2019
models Initial commit Sep 14, 2019
notifiers Initial commit Sep 14, 2019
test Initial commit Sep 14, 2019
.gitignore Initial commit Sep 14, 2019 Initial commit Sep 14, 2019
Dockerfile Initial commit Sep 14, 2019
LICENSE Initial commit Sep 14, 2019 Update read me with Docker Pull instruction (#3) Oct 7, 2019 Added Talisman to Sep 25, 2019 Initial commit Sep 14, 2019 Initial commit Sep 14, 2019
config.toml Initial commit Sep 14, 2019 Initial commit Sep 14, 2019 Initial commit Sep 14, 2019 Initial commit Sep 14, 2019
requirements.txt Initial commit Sep 14, 2019 Initial commit Sep 14, 2019


A bridge to help increase your ability to detect secrets shared on Github.

More details on the methodology can be found in our blog post.

How It Works

There are two ways this can operate:

  • Event Polling - In this mode, the script polls the Github Events API for an organization, developer, or set or repositories. This is useful when you may not have control over the thing you're watching.
  • Webhook - In this mode, the script sets up a server which can receive webhook events. This is useful when you have control over the thing you're watching, since it provides data in near real-time.

Once events are received indicating that new code has been pushed, this script executes configured detectors to detect secrets in the changes. At this time, the following detectors are supported:

A more general listing of tools which can be used to detect secrets in Git repositories can be found in

If a secret is found, it is sent upstream to a notifier. At this time, we support notifying both via stdout as well as Slack and Microsoft Teams.


Via Docker

The easiest way to get started is by using our Docker image. You can see how to run the Docker image in the Usage section.

Installation from Source

First, you need to clone the repository:

git clone

Then, install the required dependencies:

pip install -r requirements.txt


Configuration is done through config.toml. In this file, you set your access_token, the organizations, developers, and repositories you want to monitor for secrets, and more.

Setting Up the Access Token

You may wish to avoid having the access token in a file. Instead, you can set this value to env, and put the access token in the GITHUB_WATCHER_TOKEN environment variable.

Setting Up the Monitors

If you're monitoring via event polling (as opposed to using the webhook server), then you can configure what to monitor via the monitors configuration value.

You have the option of configuring one or more Github organization, user, or repository.

Setting Up the Detectors

This tool doesn't actually implement secret detection for Git repositories, since we consider that largely a solved problem. Instead, we handle running various secret detection tools for you in near real-time.

Detectors are configured via the detectors configuration value. Right now, the following values are accepted:

  • detect-secrets
  • git-secrets

Note: It's expected that the detector you use is installed and available on your $PATH. If you are running this via the Docker image, all the required tools are pre-installed.

Setting Up the Notifiers

If a secret is detected, we will notify you using your configured notifiers. Currently, the two notification methods are printing to the console, and notifying via a Slack/Teams webhook.

For webhook notifications, both Slack and Microsoft Teams implementations work identically: the JSON structure used to call the Slack webhook is the same as for Microsoft Teams, the implementation is just currently not updated to reflect this. To configure Teams notifications, follow these same steps but with a Teams Connector.

To configure Slack/Teams notifications, create the following configuration option with the webhook_url provided by Slack:



python --help

  -f, --config PATH  [default: config.toml]
  -v, --verbose      Print verbose debug information
  --help             Show this message and exit.


Running Via Docker

docker run -ti --rm -e GITHUB_WATCHER_TOKEN=your_access_token duolabs/secret-bridge poll

Note that this is the only docker command needed to get the tool up and running. Relevant images will be automatically pulled if they are not found locally.

You can’t perform that action at this time.