mapbox Token

ID

mapbox_token

Severity

low

Vendor

Mapbox

Family

API Token

Description

Mapbox is a provider of custom online maps for websites and applications. The Mapbox web services APIs allow you to programmatically access Mapbox tools and services. You can use these APIs to retrieve information about your account, upload and change resources, use core Mapbox tools, and more. Mapbox APIs are divided into four distinct services: Maps, Navigation, Search, and Accounts.

Security

Any hardcoded Mapbox Token is a potential secret reported by this detector.

Accidentally checking-in the key to source control repositories could compromise your Mapbox account.

Examples

mapbox_secret=sk.eyJ1IjoiZ2FyY2VsIiwiYSI6ImNsOW85ZGhrOTBldWMzb282emNneDV2Y2kifQ.e-K-kgGr0Z_BF5mxUI6gHw

Mitigation / Fix

  1. Remove the credentials from the source code or committed configuration file.

  2. Follow your policy for handling leaked secrets, which typically require revoking the secret in the target system(s). Tokens can be revoked via the API or the Mapbox account.

  3. If under a git repository, you may remove unwanted files from the repository history using tools like git filter-repo or BFG Repo-Cleaner. You may follow the procedure listed here for GitHub.

You should consider any sensitive data in commits with secrets as compromised.

Remember that secrets may be removed from history in your projects, but not in other users' cloned or forked repositories.