Skip to content

Commit

Permalink
Merge pull request #16154 from hvitved/ruby/redundant-implicit-read
Browse files Browse the repository at this point in the history
Ruby: Remove two redundant `allowImplicitRead` predicates
  • Loading branch information
hvitved authored Apr 9, 2024
2 parents 6f1a9d4 + e6984aa commit 6c9a0e4
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,6 @@ private module UnsafeCodeConstructionConfig implements DataFlow::ConfigSig {

// override to require the path doesn't have unmatched return steps
DataFlow::FlowFeature getAFeature() { result instanceof DataFlow::FeatureHasSourceCallContext }

predicate allowImplicitRead(DataFlow::Node node, DataFlow::ContentSet set) {
// allow implicit reads of array elements
isSink(node) and
set.isElementOfTypeOrUnknown("int")
}
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,6 @@ private module UnsafeShellCommandConstructionConfig implements DataFlow::ConfigS

// override to require the path doesn't have unmatched return steps
DataFlow::FlowFeature getAFeature() { result instanceof DataFlow::FeatureHasSourceCallContext }

predicate allowImplicitRead(DataFlow::Node node, DataFlow::ContentSet set) {
// allow implicit reads of array elements
isSink(node) and
set.isElementOfTypeOrUnknown("int")
}
}

/**
Expand Down

0 comments on commit 6c9a0e4

Please sign in to comment.