[detector]
id = "etherscan-api-key"
name = "Etherscan API Key"
service = "etherscan"
severity = "high"
keywords = ["etherscan", "ETHERSCAN", "ETHERSCAN_API_KEY", "etherscan_api_key", "etherscan.io", "api.etherscan.io"]
[[detector.patterns]]
regex = "(?:ETHERSCAN|etherscan)[_\\-\\.]?(?:API[_\\-\\.]?KEY|api[_\\-\\.]?key)[=:\\s\\\"']+([a-f0-9]{32})"
description = "Etherscan API key with context anchor"
group = 1
[[detector.patterns]]
regex = "apikey[=:\\s\\\"']+([a-f0-9]{32})"
description = "Etherscan API key in apikey parameter"
group = 1
[detector.verify]
method = "GET"
url = "https://api.etherscan.io/v2/api?chainid=1&module=stats&action=ethprice&apikey={{match}}"
[detector.verify.auth]
type = "none"
[detector.verify.success]
status = 200