Live changes on Permission/Rule
- sansumaki
- Member | 2
Hello
I have a problem with the Authentication.
I have a class that extends from Nette\Object and implements Nette\Security\IAuthenticator with the method authenticate(array $credentials).
When a user is logged in with rule Admin and at the same time i change the rule of that user or remove the user, then the user stays logged in and hold his rules.
What should i do to refresh rule and permission on live changes?
- Jan Tvrdík
- Nette guru | 2595
If you need to check the rules or user existence on every request then just
do it, e.g. in startup
.
- sansumaki
- Member | 2
Jan Tvrdík wrote:
If you need to check the rules or user existence on every request then just do it, e.g. in
startup
.
Thanks for your reply.
But, what do you mean with ‘startup’?
Should i check on any startup, manualy if rule and user match and when doesn't call logout() for example?