The majority of systems I've worked on have some notion of user and permission management that typically has very similar requirements. There are currently no widely available and complete solutions to this problem (that I'm aware of). I've only found two vaguely similar open source projects. One was a user management system deeply embedded in Turbine, I think it was part of Fulcrum. This was an inflexible solution. The other is OSUser hosted at Open Symphony. OSUser has not had an official download for a few years though you can grab the source.
It struck me as quite strange that this seemingly common component of most systems, some kind of user management, was unavailable. I still find it hard to believe. LDAP provides a partial solution, but its schema is challenging to modify and it comes up short in other areas as well.
So after implementing this solution multiple times and considering carefully how to simplify the solution in a general way I've created J.G.U.M. - Java Generic User Management.
Originally JGUM was written using a XML files for persistence. This was done leveraging Castor to marshal data to and from XML. Later requirements demanded integration with an existing SQLServer db so I converted the persistence layer using Hibernate. Although designed with encapsulation and a pluggable persistence layer in mind I was pleasently suprised to realize that I didn't end up having to touch the core objects - Group, User, Role, Permission. XML is no longer supported as a persistence layer, but all major databases are supported. Of course now there are all kinds of ways to turn your relations data into XML including dbunit.
