Cloudant Keys

ID

cloudant_iam

Severity

high

Vendor

IBM Cloud

Family

API Token

Description

Cloudant is an IBM software product, which is primarily delivered as a cloud-based service. Cloudant is a non-relational, distributed database service of the same name based on the Apache-backed CouchDB project and the open source BigCouch project.

It provides and API to access the service with two possible authentication mechanisms:

  • The first one referred as legacy in the documentation consists in username and password.

  • The second one referred as IAM authentication in the documentation consists in username and APIKey.

Security

Any hardcoded Cloudant API Key is a potential secret reported by this detector.

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

Examples

<key>cloudantApikey</key>
<string>AMzxmGE-enRxe8o0P3R0w1ZhTztFEJpmLjYbm5y6RAZB</string>

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). Go to the IBM Cloudant dashboard in the Service credentials tab to revoke the API Key.

  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.