C#: Add telemetry query for supported sinks.

This commit is contained in:
Michael Nebel
2022-03-08 10:44:32 +01:00
parent e4f6321851
commit d81e73f9c6

View File

@@ -0,0 +1,17 @@
/**
* @name Supported sinks in external libraries
* @description A list of 3rd party APIs detected as sinks. Excludes test and generated code.
* @kind metric
* @tags summary
* @id csharp/telemetry/supported-external-api-sinks
*/
import csharp
import ExternalAPI
from ExternalAPI api, int usages
where
not api.isUninteresting() and
api.isSink() and
usages = strictcount(Call c | c.getTarget() = api)
select api.getInfo() as info, usages order by usages desc