-
Jan 4th, 2006, 08:01 AM
#1
Combined id on user table in stead of userid
Hi,
I have an application where I have many clients. I changed the user table and added a column called client_id.
How can I get Acegi to look for the combination of userid and client_id in stead of only userid when authenticating?
My problem is that the userid is unique in the whole application today and I would like to have the combination to be unique in stead.
Regards
Tborum
Last edited by tborum; Jan 4th, 2006 at 08:12 AM.
-
Jan 4th, 2006, 09:14 AM
#2
First question is why do you want that? This way users can have the same userid? Do users have to logon with userid and clientid than? As for the answer, what kind of provider are you using? Are you using the JdbcDaoImpl?
In short, please provide more details
greetz Jettro
-
Jan 25th, 2006, 07:20 PM
#3
I have done this plenty of times in ASP style deployments.
A bit of an intro is at http://forum.springframework.org/showthread.php?t=9830
Basically you need to select an identifier, then in your UserDetailsService you need to tokenize the Authentication.getPrincipal() so you get the two components out. See org.springframework.util.StringUtils for helpful methods.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules