Role-Based Authorization with Granted Authorities
After authenticating users from a database, learn to authorize them using roles and authorities, securing endpoints and methods in Spring Security.
Authentication vs Authorization
You can now load users from a database and verify passwords. That is authentication (who you are). The next question is authorization (what you may do), driven by roles and authorities.
Authorities and Roles
Spring represents permissions as GrantedAuthority objects. A role is just an authority with a ROLE_ prefix, e.g. ROLE_ADMIN.
All lessons in this course
- Custom UserDetailsService Implementation
- Understanding Password Encoders
- Database User Management Integration
- Role-Based Authorization with Granted Authorities