mirror of
https://github.com/github/codeql.git
synced 2025-12-18 01:33:15 +01:00
Optimize concatAndCompareAgainstFullHostRegex
This commit is contained in:
@@ -38,12 +38,8 @@ class LDAPPrivateHost extends StrConst {
|
||||
}
|
||||
|
||||
predicate concatAndCompareAgainstFullHostRegex(LDAPSchema schema, StrConst host) {
|
||||
schema instanceof LDAPSchema and
|
||||
not host instanceof LDAPPrivateHost and
|
||||
exists(string full_host |
|
||||
full_host = schema.(StrConst).getText() + host.(StrConst).getText() and
|
||||
full_host.regexpMatch(getFullHostRegex())
|
||||
)
|
||||
(schema.getText() + host.getText()).regexpMatch(getFullHostRegex())
|
||||
}
|
||||
|
||||
// "ldap://" + "somethingon.theinternet.com"
|
||||
|
||||
Reference in New Issue
Block a user