Skip to content

remove credential literals from shared environment defaults - #1

Open
mertcano wants to merge 1 commit into
getoptimum:mainfrom
mertcano:mertcano-patch-44
Open

remove credential literals from shared environment defaults#1
mertcano wants to merge 1 commit into
getoptimum:mainfrom
mertcano:mertcano-patch-44

Conversation

@mertcano

Copy link
Copy Markdown

This PR resolves a security vulnerability regarding credential exposure in adapter defaults within the DefiLlama-Adapter repository.

** Vulnerabilities & Anti-Patterns Remediated:**

  • Secrets & Configuration / Credential literals in adapter defaults: Previously, API-key-like defaults for services such as Covalent, Ankr, Subscan, Blockfrost, Tatum, CryptoAPIs, Bifrost, and a commented Helius URL were embedded directly in the shared environment helper.
    Fix:
    • All sensitive credential literals and obfuscated key fragments have been removed from the DEFAULTS object[cite: 7].
    • Supported environment names correctly remain in the ENV_KEYS allowlist[cite: 7].
    • Public RPC defaults have been preserved[cite: 7].
    • Runtime credentials must now securely arrive through environment configuration rather than being exposed in source control.

NOTE

Please enable "Allow edits by maintainers" while putting up the PR.


  1. If you would like to add a volume/fees/revenue adapter please submit the PR here.

  2. Once your adapter has been merged, it takes time to show on the UI. If more than 24 hours have passed, please let us know in Discord.

  3. Sorry, We no longer accept fetch adapter for new projects, we prefer the tvl to computed from blockchain data, if you have trouble with creating a the adapter, please hop onto our discord, we are happy to assist you.

  4. For updating listing info Please send a mail to metadata@defillama.com

  5. Please do not add new npm dependencies, do not edit/push pnpm-lock.yaml file as part of your changes


(Needs to be filled only for new listings)

Name (to be shown on DefiLlama):
Twitter Link:
List of audit links if any:
Website Link:
Logo (High resolution, will be shown with rounded borders):
Current TVL:
Treasury Addresses (if the protocol has treasury)
Chain:
Coingecko ID (so your TVL can appear on Coingecko, leave empty if not listed): (https://api.coingecko.com/api/v3/coins/list)
Coinmarketcap ID (so your TVL can appear on Coinmarketcap, leave empty if not listed): (https://api.coinmarketcap.com/data-api/v3/map/all?listing_status=active,inactive,untracked&start=1&limit=10000)
Short Description (to be shown on DefiLlama):
Token address and ticker if any:
Category (full list at https://defillama.com/categories) *Please choose only one:
Oracle Provider(s): Specify the oracle(s) used (e.g., Chainlink, Band, API3, TWAP, etc.):
Implementation Details: Briefly describe how the oracle is integrated into your project:
Documentation/Proof: Provide links to documentation or any other resources that verify the oracle's usage:
forkedFrom (Does your project originate from another project):
methodology (what is being counted as tvl, how is tvl being calculated):
Github org/user (Optional, if your code is open source, we can track activity):
Does this project have a referral program?

This PR resolves a security vulnerability regarding credential exposure in adapter defaults within the `DefiLlama-Adapter` repository.

** Vulnerabilities & Anti-Patterns Remediated:**

*   **Secrets & Configuration / Credential literals in adapter defaults:** Previously, API-key-like defaults for services such as Covalent, Ankr, Subscan, Blockfrost, Tatum, CryptoAPIs, Bifrost, and a commented Helius URL were embedded directly in the shared environment helper. 
    **Fix:** 
    *   All sensitive credential literals and obfuscated key fragments have been removed from the `DEFAULTS` object[cite: 7]. 
    *   Supported environment names correctly remain in the `ENV_KEYS` allowlist[cite: 7].
    *   Public RPC defaults have been preserved[cite: 7]. 
    *   Runtime credentials must now securely arrive through environment configuration rather than being exposed in source control.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant