How to create custom roles in spring using waffle

Aug 13, 2010 at 4:54 AM

Hello All,

I'm trying out wonderful WAFFLE using the spring tutorial as my starting point. It works and shows my details (Active Directory etc). Now i want to create custom roles and want to check if the logged in user has this role or not. My config is same as the Spring+Waffle+Tomcat example that is shown in this site.







Aug 13, 2010 at 8:29 AM

Upon successful login, Waffle adds a ROLE_USER to the list of granted authorities along with user's identity and groups prefixed with ROLE_. For example, if a user is a member of the Everyone group, he obtains the ROLE_EVERYONE granted authority. The rest is spring-standard, so you should refer to the spring-security documentation. If you learn something we don't know, do post it here :)