I am building an application using Hibernate 3 (with JPA Annotations), Spring 2.5 and Spring Security 2.0.5.
I want to know what I need to put in my <authentication-provider> in my Spring security configuration file (applicationContext-security.xml) so that I can get Spring Security to use my existing service level class (AuthenticationService), which deals with my user domain and user objects.
I understand that Spring Security requires two tables with the following schema:
create table users( username varchar_ignorecase(50) not null primary key, password varchar_ignorecase(50) not null, enabled boolean not null); create table authorities ( username varchar_ignorecase(50) not null, authority varchar_ignorecase(50) not null, constraint fk_authorities_users foreign key(username) references users(username)); create unique index ix_auth_username on authorities (username,authority);;
but I want to use my own domain objects that are different from the above table definitions.
Can someone point me in the right direction? I cannot find useful documentation, and I am not sure if what I want to do is really possible.
Thank!
spring spring-security jpa
JMM Feb 23 '10 at 13:34 2010-02-23 13:34
source share