I have 2 similar projects with shiro authentication. Configuration is identical.
*First Project Conf. (shiro.ini)* [main] jwtg = gr.histopath.platform.lib.JWTGuard jwtv = gr.histopath.platform.lib.JWTVerifyingFilter ds = com.mysql.cj.jdbc.MysqlDataSource ds.serverName = 127.0.0.1 ds.port = 3306 ds.user = histopathUser ds.password = ********** ds.databaseName = histopath.gr jdbcRealm = gr.histopath.platform.lib.MyRealm jdbcRealm.dataSource = $ds credentialsMatcher = org.apache.shiro.authc.credential.Sha512CredentialsMatcher credentialsMatcher.hashIterations = 50000 credentialsMatcher.hashSalted = true credentialsMatcher.storedCredentialsHexEncoded = false jdbcRealm.credentialsMatcher = $credentialsMatcher jdbcRealm.permissionsLookupEnabled = false shiro.loginUrl = /authentication/login cacheManager = org.apache.shiro.cache.MemoryConstrainedCacheManager securityManager.cacheManager = $cacheManager sessionManager = org.apache.shiro.web.session.mgt.DefaultWebSessionManager securityManager.sessionManager = $sessionManager #securityManager.sessionManager.sessionIdCookieEnabled = false # ssl.enabled = false securityManager.realms = $jdbcRealm [users] [roles] [urls] /authentication/login = authc # /authentication/logout = logout /search/* = noSessionCreation, jwtv /statistics/* = noSessionCreation, jwtv /clinics/* = noSessionCreation, jwtv /patients/* = noSessionCreation, jwtv /incidents/* = noSessionCreation, jwtv /doctors/* = noSessionCreation, jwtv /users/new = noSessionCreation, anon /users/details/* = noSessionCreation, anon /users/* = noSessionCreation, jwtv /* = anon *Second Project Conf. (shiro.ini)* [main] jwtg = gr.gourvas.platform.lib.JWTGuard jwtv = gr.gourvas.platform.lib.JWTVerifyingFilter ds = com.mysql.cj.jdbc.MysqlDataSource ds.serverName = 127.0.0.1 ds.port = 3306 ds.user = gourvasUser ds.password = *********** ds.databaseName = gourvas_platform jdbcRealm = gr.gourvas.platform.lib.MyRealm jdbcRealm.dataSource = $ds credentialsMatcher = org.apache.shiro.authc.credential.Sha512CredentialsMatcher credentialsMatcher.hashIterations = 50000 credentialsMatcher.hashSalted = true credentialsMatcher.storedCredentialsHexEncoded = false jdbcRealm.credentialsMatcher = $credentialsMatcher jdbcRealm.permissionsLookupEnabled = false shiro.loginUrl = /authentication/login cacheManager = org.apache.shiro.cache.MemoryConstrainedCacheManager securityManager.cacheManager = $cacheManager sessionManager = org.apache.shiro.web.session.mgt.DefaultWebSessionManager securityManager.sessionManager = $sessionManager #securityManager.sessionManager.sessionIdCookieEnabled = false # ssl.enabled = false securityManager.realms = $jdbcRealm [users] [roles] [urls] /authentication/login = authc # /authentication/logout = logout /search/* = noSessionCreation, jwtv /statistics/* = noSessionCreation, jwtv /clinics/* = noSessionCreation, jwtv /patients/* = noSessionCreation, jwtv /incidents/* = noSessionCreation, jwtv /doctors/* = noSessionCreation, jwtv /users/new = noSessionCreation, anon /users/details/* = noSessionCreation, anon /users/* = noSessionCreation, jwtv /* = anon The first one build and works normally. *The second one fails to build with shiro error: * org.apache.shiro.config.ConfigurationException: Unable to instantiate class [gr.gourvas.platform.lib.MyRealm] for object named 'jdbcRealm'. Please ensure you've specified the fully qualified class name correctly. What is going on. Why the second project doesn't find MyRealm??? Any Ideas? I am banging my head for hours... -- Sent from: http://shiro-user.582556.n2.nabble.com/
