Skip to content

Wrong logic for negatives in Garbage (G) filter middleware #5

@Macmod

Description

@Macmod

When a query includes a negative clause such as (!(objectClass=msDS-GroupManagedServiceAccount)), the "Garbage" (G) filter middleware may turn it into something like:

(
    !(
        |(
            objectClass=msDS-GroupManagedServiceAccount
        )
       (bfonnkergb~=jlismfmkrj)
    )
)

Which should cancel out the garbage and evaluate to true for objects of classes other than msDS-GroupManagedServiceAccount, but it doesn't. 😋
On the other hand, "moving the negative" makes it work:

(
    |(
       (!(objectClass=msDS-GroupManagedServiceAccount))
       (bfonnkergb~=jlismfmkrj)
    )
)

I'm not sure why, but there should be a workaround. It's worth noting that negatives, when applied to "garbage" clauses, really don't cause the overall query to return "all objects", for example with the query (!(bfonnkergb~=jlismfmkrj)). It's probably some sort of UNDEFINED state, for which UNDEFINED | TRUE = TRUE, but !UNDEFINED != TRUE...

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions