diff --git a/python/ql/lib/semmle/python/dataflow/new/internal/DataFlowPublic.qll b/python/ql/lib/semmle/python/dataflow/new/internal/DataFlowPublic.qll index 90ce60ea415..0593ba85e70 100644 --- a/python/ql/lib/semmle/python/dataflow/new/internal/DataFlowPublic.qll +++ b/python/ql/lib/semmle/python/dataflow/new/internal/DataFlowPublic.qll @@ -614,7 +614,7 @@ newtype TContent = // instead we use a qltest to alert if we write a new summary in QL that uses an // attribute -- see // python/ql/test/experimental/dataflow/summaries-checks/missing-attribute-content.ql - none() // to be filled out in next commit + attr in ["re", "string", "pattern"] or // // 2) summaries in data-extension files diff --git a/python/ql/test/experimental/dataflow/summaries-checks/invalid-spec.expected b/python/ql/test/experimental/dataflow/summaries-checks/invalid-spec.expected index 4227247f366..bc342d8091a 100644 --- a/python/ql/test/experimental/dataflow/summaries-checks/invalid-spec.expected +++ b/python/ql/test/experimental/dataflow/summaries-checks/invalid-spec.expected @@ -1,14 +1,2 @@ -| compiled re.Match | Argument[self].Attribute[pattern] | Attribute[pattern] | -| compiled re.Match | ReturnValue.Attribute[re].Attribute[pattern] | Attribute[pattern] | -| compiled re.Match | ReturnValue.Attribute[re].Attribute[pattern] | Attribute[re] | -| compiled re.Match | ReturnValue.Attribute[string] | Attribute[string] | | compiled re.subn | ReturnValue.TupleElement[0] | TupleElement[0] | -| re.Match | ReturnValue.Attribute[re].Attribute[pattern] | Attribute[pattern] | -| re.Match | ReturnValue.Attribute[re].Attribute[pattern] | Attribute[re] | -| re.Match | ReturnValue.Attribute[string] | Attribute[string] | -| re.Match.expand | Argument[self].Attribute[string] | Attribute[string] | -| re.Match.group | Argument[self].Attribute[string] | Attribute[string] | -| re.Match.groupdict | Argument[self].Attribute[string] | Attribute[string] | -| re.Match.groups | Argument[self].Attribute[string] | Attribute[string] | -| re.Pattern | ReturnValue.Attribute[pattern] | Attribute[pattern] | | re.subn | ReturnValue.TupleElement[0] | TupleElement[0] | diff --git a/python/ql/test/experimental/dataflow/summaries-checks/missing-attribute-content.expected b/python/ql/test/experimental/dataflow/summaries-checks/missing-attribute-content.expected index 6341424e5ac..e69de29bb2d 100644 --- a/python/ql/test/experimental/dataflow/summaries-checks/missing-attribute-content.expected +++ b/python/ql/test/experimental/dataflow/summaries-checks/missing-attribute-content.expected @@ -1,3 +0,0 @@ -| The attribute "pattern" is not a valid TAttributeContent, please add it to the hardcoded list of TAttributeContent in the dataflow library. | -| The attribute "re" is not a valid TAttributeContent, please add it to the hardcoded list of TAttributeContent in the dataflow library. | -| The attribute "string" is not a valid TAttributeContent, please add it to the hardcoded list of TAttributeContent in the dataflow library. |