mirror of
https://github.com/github/codeql.git
synced 2025-12-24 04:36:35 +01:00
C#: remove previous uses of isUninteresting
This commit is contained in:
@@ -14,8 +14,7 @@ private predicate getRelevantUsages(string namespace, int usages) {
|
||||
usages =
|
||||
strictcount(Call c, ExternalApi api |
|
||||
c.getTarget().getUnboundDeclaration() = api and
|
||||
api.getNamespace() = namespace and
|
||||
not api.isUninteresting()
|
||||
api.getNamespace() = namespace
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
@@ -12,11 +12,8 @@ private import semmle.code.csharp.dataflow.internal.FlowSummaryImpl as FlowSumma
|
||||
private import ExternalApi
|
||||
|
||||
private predicate relevant(ExternalApi api) {
|
||||
not api.isUninteresting() and
|
||||
(
|
||||
api.isSupported() or
|
||||
api instanceof FlowSummaryImpl::Public::NegativeSummarizedCallable
|
||||
)
|
||||
api.isSupported() or
|
||||
api instanceof FlowSummaryImpl::Public::NegativeSummarizedCallable
|
||||
}
|
||||
|
||||
from string info, int usages
|
||||
|
||||
@@ -10,10 +10,7 @@ private import csharp
|
||||
private import semmle.code.csharp.dispatch.Dispatch
|
||||
private import ExternalApi
|
||||
|
||||
private predicate relevant(ExternalApi api) {
|
||||
not api.isUninteresting() and
|
||||
api.isSink()
|
||||
}
|
||||
private predicate relevant(ExternalApi api) { api.isSink() }
|
||||
|
||||
from string info, int usages
|
||||
where Results<relevant/1>::restrict(info, usages)
|
||||
|
||||
@@ -10,10 +10,7 @@ private import csharp
|
||||
private import semmle.code.csharp.dispatch.Dispatch
|
||||
private import ExternalApi
|
||||
|
||||
private predicate relevant(ExternalApi api) {
|
||||
not api.isUninteresting() and
|
||||
api.isSource()
|
||||
}
|
||||
private predicate relevant(ExternalApi api) { api.isSource() }
|
||||
|
||||
from string info, int usages
|
||||
where Results<relevant/1>::restrict(info, usages)
|
||||
|
||||
@@ -10,10 +10,7 @@ private import csharp
|
||||
private import semmle.code.csharp.dispatch.Dispatch
|
||||
private import ExternalApi
|
||||
|
||||
private predicate relevant(ExternalApi api) {
|
||||
not api.isUninteresting() and
|
||||
api.hasSummary()
|
||||
}
|
||||
private predicate relevant(ExternalApi api) { api.hasSummary() }
|
||||
|
||||
from string info, int usages
|
||||
where Results<relevant/1>::restrict(info, usages)
|
||||
|
||||
@@ -12,7 +12,6 @@ private import semmle.code.csharp.dataflow.internal.FlowSummaryImpl as FlowSumma
|
||||
private import ExternalApi
|
||||
|
||||
private predicate relevant(ExternalApi api) {
|
||||
not api.isUninteresting() and
|
||||
not api.isSupported() and
|
||||
not api instanceof FlowSummaryImpl::Public::NegativeSummarizedCallable
|
||||
}
|
||||
|
||||
@@ -16,7 +16,6 @@ private import Telemetry.ExternalApi
|
||||
from Call c, ExternalApi api
|
||||
where
|
||||
c.getTarget().getUnboundDeclaration() = api and
|
||||
not api.isUninteresting() and
|
||||
not api.isSupported() and
|
||||
not api instanceof FlowSummaryImpl::Public::NegativeSummarizedCallable
|
||||
select c, "Call to unsupported external API $@.", api, api.toString()
|
||||
|
||||
Reference in New Issue
Block a user