Issue:
In JasperReports Server v5.1, when configuring LDAP authentication usling the applicationContext-externalAuth-LDAP-mt.xml sample file, with no multitenant license, users get the following error on the login screen:
"Invalid credentials supplied. Could not login to JasperReports Server. "
With this configuration, the JasperReports Server is assuming multitenancy and attempts to map the organization hierarchy which results in the invalid credentials error message.
Resolution:
The ldapExternalTenantProcessor bean must be configured to ignore multitenancy. The new JasperReports Server Authentication Cookbook v5.2, section 3.7.1, "Mapping to a Single Organization" (found in our Docs Area) shows the proper configuration for this bean when using a single organization (see also attached sample-applicationContext-externalAuth-LDAP-pro-nomt.xml). The bean should be configured as follows:
<bean class="com.jaspersoft.jasperserver.multipleTenancy.security.externalAuth.processors.ldap.LdapExternalTenantProcessor" id="ldapExternalTenantProcessor" parent="abstractExternalProcessor"> <property name="ldapContextSource" ref="ldapContextSource" /> <property name="multiTenancyService"><ref bean="internalMultiTenancyService"></ref></property> <property name="excludeRootDn" value="true" /> <!-- only following LDAP attributes will be used in creation of organization hierarchy. Eg. cn=Smith,ou=Developement,o=Jaspersoft will produce tanant Development as child of tenant Jaspersoft (if excludeRootDn=false) as child of default tenant organization_1 --> <property name="organizationRDNs"><list /></property> <property name="rootOrganizationId" value="organization_1" /> <property name="defaultOrganization" value="organization_1" /> </bean>
Note the excludeRootDn property is set to "true," the organizationRDNs list is empty, and the defaultOrganization property has been added with value, "organization_1."
Please review JasperReports Server Authentication Cookbook v5.2, for more implementation details.
References
- JasperReports Server Authentication Cookbook v5.2 (HTML)
- JasperReports Server Authentication Cookbook v5.1 (PDF)
- JasperReports Server Authentication Cookbook v4.7 (PDF)
- jasperreportsserver-auth-cookbook-4.0.pdf v4.0 (PDF)
sample-applicationcontext-externalauth-ldap-pro-nomt.xml
sample-applicationcontext-externalauth-ldap-pro-nomt-5.2.xml
Recommended Comments
There are no comments to display.