Click here to Skip to main content
15,890,579 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
have made a little webapp in Java using jsp and am having a little problem with Login Authentication..

i have 4 different users. have 4 tabs in a jsp page

i need to give them the limited access to Tabs.

eg-director (can see all the tabs) officer 1 (can see only have accesses to 3 of tabs ) officer 2 (can see only have accesses to 2 of tabs ) officer 3 (can see only have accesses to 1 of tabs )

it is like a security clearance i tried to so many ways and failed and i am thinking to do that with passing a Boolean to Database and give the access levels for that i need a help if it is with a small sample log in project that will be very help full for me

if it can do with the EER also it ill be ok
Posted
Comments
Shubhashish_Mandal 31-Dec-13 2:10am    
what actually you want?
gayan_priyankara 31-Dec-13 2:27am    
a simple example how to to give security clearance to the users as i wish
Shubhashish_Mandal 31-Dec-13 2:38am    
There are so many to do this. You have to add a user_type column in you db which basically tell you the type of the logged user. Also create a mapping which will keep the tabs accessibility info against the user_type. To keep the mapping info you could choose a xml file or db table.
Once user logged in successfully, pick the user type and then look into the map to get the right tabs info.
gayan_priyankara 31-Dec-13 2:48am    
ya i have the idea but i couldn't make it right.. thats the problem

1 solution

simple
store the user to tab map
get the map of current user and check which tab will show
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900