do not limit client type to white list (#442)

This commit is contained in:
Vyacheslav
2024-03-25 13:13:09 +02:00
committed by GitHub
parent 06578717b5
commit b113b56f62

View File

@@ -55,22 +55,12 @@ abstract class BasicEthLabelsDetector(
}
private fun clientType(client: String): String? {
return if (client.contains("erigon", true)) {
"erigon"
} else if (client.contains("geth", true)) {
"geth"
} else if (client.contains("bor", true)) {
"bor"
} else if (client.contains("nethermind", true)) {
"nethermind"
} else if (client.contains("prysm", true)) {
"prysm"
} else if (client.contains("lighthouse", true)) {
"lighthouse"
} else {
val firstSlash = client.indexOf("/")
if (firstSlash == -1) {
log.debug("Unknown client type: {}", client)
null
return null
}
return client.substring(0, firstSlash).lowercase()
}
data class NodeTypeRequest(