Content
Updated by Anton Tkacik about 1 year ago
In midPoint 4.8.2, the advanced search in the "Resource objects" of a resource does not work:
When searching for attributes in the resource, the search fails with a NullPointerException or midPoint does not find the attributes.
The error is independent of:
Connector and Resource Configuration
Filter method (equal, =, endsWith, =\[distinguishedName\], =\[stringIgnoreCase\] etc.)
Attribute name from the resource schema (e.g. sAMAccountName, dn, cn...)
The search for "attributes/name" and "attributes/uid" works, as these attributes do not come from the dynamic resource schema.
This can easily be reproduced in the resource objects view of the resource "**LDAP Server (OpenLDAP)"** on [https://demo.evolveum.com.](https://demo.evolveum.com/)
**Variant 1 (attribute not found):**
`attributes/first_name = "Michelangelo"`
`attributes/ri:first_name = "Michelangelo"`
Error message: `Path attributes/sAMAccountName is not present in type {http://midpoint.evolveum.com/xml/ns/public/common/common-3}ShadowType`
**Variante 2 (fully qualified attribute name):**
`attributes/(http://midpoint.evolveum.com/xml/ns/public/resource/instance-3#first_name) = "Michelangelo"`
Error message: `Cannot invoke "com.evolveum.axiom.lang.antlr.query.AxiomQueryParser$FilterNameContext.filterNameAlias()" because "filterName" is null`
In the customer's use case the basic search is not an option as no complex queries can be executed this way.
Would you please check this issue and provide a fix?
When searching for attributes in the resource, the search fails with a NullPointerException or midPoint does not find the attributes.
Connector and Resource Configuration
Filter method (equal, =, endsWith, =\[distinguishedName\], =\[stringIgnoreCase\] etc.)
Attribute name from the resource schema (e.g. sAMAccountName, dn, cn...)
This can easily be reproduced in the resource objects view of the resource "**LDAP Server (OpenLDAP)"** on [https://demo.evolveum.com.](https://demo.evolveum.com/)
**Variant 1 (attribute not found):**
`attributes/first_name = "Michelangelo"`
`attributes/ri:first_name = "Michelangelo"`
Error message: `Path attributes/sAMAccountName is not present in type {http://midpoint.evolveum.com/xml/ns/public/common/common-3}ShadowType`
**Variante 2 (fully qualified attribute name):**
`attributes/(http://midpoint.evolveum.com/xml/ns/public/resource/instance-3#first_name) = "Michelangelo"`
Error message: `Cannot invoke "com.evolveum.axiom.lang.antlr.query.AxiomQueryParser$FilterNameContext.filterNameAlias()" because "filterName" is null`