shiro-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Les Hazlewood (Closed) (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (SHIRO-234) ClassCastException in checkRoles
Date Tue, 24 Jan 2012 01:11:53 GMT

     [ https://issues.apache.org/jira/browse/SHIRO-234?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Les Hazlewood closed SHIRO-234.
-------------------------------


Closing with the 1.2.0 release.
                
> ClassCastException in checkRoles
> --------------------------------
>
>                 Key: SHIRO-234
>                 URL: https://issues.apache.org/jira/browse/SHIRO-234
>             Project: Shiro
>          Issue Type: Bug
>    Affects Versions: 1.1.0
>            Reporter: Dan Diephouse
>             Fix For: 1.2.0
>
>
> I get the following:
> java.lang.ClassCastException: [Ljava.lang.Object; cannot be cast to [Ljava.lang.String;
> 	at org.apache.shiro.authz.ModularRealmAuthorizer.checkRoles(ModularRealmAuthorizer.java:426)
> In checkRoles, the collection is incorrectly cast to a String[]. The line needs to do
toArray(new String[roles.size]) and not toArray().

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message