Spring: avoid logins during night/weekend for non-admin

We are working on an authentication system, using Spring 5 (I'm new using this Framework).

We use AuthenticationManagerBuilder, and, for security reasons, I have to extend the system to avoid that non-admin user could login during weekends, or during certain non-working hours.

I was checking on the documentation, this site, and the Web, the only thing I found that gave me ideas is @PreAuthorize, but I could not find the way to use it for my purpose.

Do you know if it can be done through some annotation, or using some Framework-provided...

Read More »

By: StackOverFlow - Tuesday, 13 March

Related Posts