mirror of
https://github.com/github/codeql.git
synced 2026-04-24 16:25:15 +02:00
Merge branch 'brodes/cipher_operation' into brodes/elliptic_curves
This commit is contained in:
@@ -573,7 +573,7 @@ module JCAModel {
|
||||
src.asExpr() instanceof CipherGetInstanceCall
|
||||
}
|
||||
|
||||
predicate isSink(DataFlow::Node sink, FlowState state) { none() }
|
||||
predicate isSink(DataFlow::Node sink, FlowState state) { none() } // TODO: document this, but this is intentional (avoid cross products?)
|
||||
|
||||
predicate isSink(DataFlow::Node sink) {
|
||||
exists(CipherOperationCall c | c.getQualifier() = sink.asExpr())
|
||||
@@ -914,7 +914,7 @@ module JCAModel {
|
||||
type instanceof Crypto::TAsymmetricKeyType
|
||||
}
|
||||
|
||||
override DataFlow::Node getOutputKeyArtifact() { result.asExpr() = this }
|
||||
override Crypto::ArtifactOutputDataFlowNode getOutputKeyArtifact() { result.asExpr() = this }
|
||||
|
||||
override Crypto::KeyArtifactType getOutputKeyType() { result = type }
|
||||
|
||||
@@ -1271,7 +1271,7 @@ module JCAModel {
|
||||
result.asExpr() = this.getInstantiation().getIterationCountArg()
|
||||
}
|
||||
|
||||
override DataFlow::Node getOutputKeyArtifact() {
|
||||
override Crypto::ArtifactOutputDataFlowNode getOutputKeyArtifact() {
|
||||
result.asExpr() = this and
|
||||
super.getMethod().getReturnType().hasName("SecretKey")
|
||||
}
|
||||
|
||||
@@ -199,19 +199,5 @@ module ArtifactUniversalFlowConfig implements DataFlow::ConfigSig {
|
||||
|
||||
module GenericDataSourceUniversalFlow = TaintTracking::Global<GenericDataSourceUniversalFlowConfig>;
|
||||
|
||||
/*
|
||||
* class LiteralOrGenericDataSource extends Element {
|
||||
* DataFlow::Node node;
|
||||
*
|
||||
* LiteralOrGenericDataSource() {
|
||||
* node = this.(Crypto::GenericSourceInstance).getOutputNode() or
|
||||
* node.asExpr() = this.(Literal)
|
||||
* }
|
||||
*
|
||||
* bindingset[other]
|
||||
* predicate localFlowsTo(DataFlow::Node other) { DataFlow::localFlow(node, other) }
|
||||
* }
|
||||
*/
|
||||
|
||||
// Import library-specific modeling
|
||||
import JCA
|
||||
|
||||
Reference in New Issue
Block a user