result is that namespace session management config does not work with default LdapUserDetailsImpl.
Please explain what you mean by "namespace session management config does not work" and supply a test case which reproduces the problem.
sorry. I mean using the <session-management> tag in the namespace element. I was trying to use <concurrency-control max-sessions> but it did not work. I was using the ldap provider with a custom principal that extended LdapUserDetailsImpl. After following some advice about the session registry keying on the principal, I looked at the source and it did not implement equals/hashCode. So I implemented these on my custom principal and it worked.
Ok, I think I see where you're coming from now. The LdapUserDetailsImpl may be used as the principal object in the session registry, which requires a hash lookup. I've added equals and hashcode, purely based on the DN value (and ignoring other data) since that should uniquely identify the principal. That should do the trick for this use case.
This issue has been migrated to https://github.com/spring-projects/spring-security/issues/1716