HTTP Status 500 - java.lang.IllegalArgumentException: Wildcard string cannot be null or empty. Make

 

type Exception report

message java.lang.IllegalArgumentException: Wildcard string cannot be null or empty. Make sure permission strings are properly formatted.

description The server encountered an internal error that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: java.lang.IllegalArgumentException: Wildcard string cannot be null or empty. Make sure permission strings are properly formatted.
	org.apache.shiro.web.servlet.AdviceFilter.cleanup(AdviceFilter.java:196)
	org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:148)
	org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)
	org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66)
	org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:449)
	org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:365)
	org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90)
	org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83)
	org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:383)
	org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:362)
	org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)

 

root cause

java.lang.IllegalArgumentException: Wildcard string cannot be null or empty. Make sure permission strings are properly formatted.
	org.apache.shiro.authz.permission.WildcardPermission.setParts(WildcardPermission.java:151)
	org.apache.shiro.authz.permission.WildcardPermission.(WildcardPermission.java:142)
	org.apache.shiro.authz.permission.WildcardPermission.(WildcardPermission.java:138)
	org.apache.shiro.authz.permission.WildcardPermissionResolver.resolvePermission(WildcardPermissionResolver.java:41)
	org.apache.shiro.realm.AuthorizingRealm.resolvePermissions(AuthorizingRealm.java:433)
	org.apache.shiro.realm.AuthorizingRealm.getPermissions(AuthorizingRealm.java:409)
	org.apache.shiro.realm.AuthorizingRealm.isPermitted(AuthorizingRealm.java:466)
	org.apache.shiro.realm.AuthorizingRealm.isPermitted(AuthorizingRealm.java:462)
	org.apache.shiro.realm.AuthorizingRealm.isPermitted(AuthorizingRealm.java:457)
	org.apache.shiro.authz.ModularRealmAuthorizer.isPermitted(ModularRealmAuthorizer.java:223)
	org.apache.shiro.mgt.AuthorizingSecurityManager.isPermitted(AuthorizingSecurityManager.java:113)
	org.apache.shiro.subject.support.DelegatingSubject.isPermitted(DelegatingSubject.java:158)
	org.apache.shiro.web.filter.authz.PermissionsAuthorizationFilter.isAccessAllowed(PermissionsAuthorizationFilter.java:45)
	org.apache.shiro.web.filter.AccessControlFilter.onPreHandle(AccessControlFilter.java:162)
	org.apache.shiro.web.filter.PathMatchingFilter.isFilterChainContinued(PathMatchingFilter.java:203)
	org.apache.shiro.web.filter.PathMatchingFilter.preHandle(PathMatchingFilter.java:178)
	org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:131)
	org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)
	org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66)
	org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:449)
	org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:365)
	org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90)
	org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83)
	org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:383)
	org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:362)
	org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)

 

note The full stack trace of the root cause is available in the Apache Tomcat/7.0.70 logs.


Apache Tomcat/7.0.70

 

错误原因:shiro 中权限信息错误 subject.setAuthorities(authorities) 方法存在空值

 

 

 

你可能感兴趣的:(java)