Hi,

In my standalone application, I have a problem that I want to create
AuthenticationRealms dynamically according to incoming subjects. So I plan
to create securityManagers instances dynamically and add the realms I
created into a new  SecurityManager instance.

My logic is like this:

one incoming request->Create realms-> new SecurityManger and set realms->
new Shiro delegate Subject which delegates the SecurityManger ->
subject.login()

I have disabled shiro internal session ,RememberMeManager and
SessionManager. And I am not using threadlocal in shiro.

On the shiro official documents, I saw it is recommended to use
SecurityManger as a singleton. Is there any problems I may have if I create
SecurityManagers in this way?

Thanks!

Chi

Reply via email to