Skip to content

Commit 66c9cfa

Browse files
RasmusWLtausbn
andauthored
Python: Apply suggestions from code review
Co-authored-by: Taus <[email protected]>
1 parent 8353992 commit 66c9cfa

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

python/ql/src/Security/CVE-2018-1281/BindToAllInterfaces.ql

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,7 @@ DataFlow::Node vulnerableHostname(string hostname) {
5454
/** Gets a reference to tuple containing a hostname as the first element, that can be used to bind to all interfaces. */
5555
private DataFlow::LocalSourceNode vulnerableAddressTuple(DataFlow::TypeTracker t, string hostname) {
5656
t.start() and
57-
exists(Tuple tup |
58-
tup.getElt(0) = vulnerableHostname(hostname).asExpr() and
59-
result.asExpr() = tup
60-
)
57+
result.asExpr() = any(Tuple tup | tup.getElt(0) = vulnerableHostname(hostname).asExpr())
6158
or
6259
// Due to bad performance when using normal setup with `vulnerableAddressTuple(t2, hostname).track(t2, t)`
6360
// we have inlined that code and forced a join

0 commit comments

Comments
 (0)