Return-Path: Delivered-To: apmail-shiro-dev-archive@www.apache.org Received: (qmail 50567 invoked from network); 13 Jan 2011 00:48:12 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 13 Jan 2011 00:48:12 -0000 Received: (qmail 29045 invoked by uid 500); 13 Jan 2011 00:48:12 -0000 Delivered-To: apmail-shiro-dev-archive@shiro.apache.org Received: (qmail 28995 invoked by uid 500); 13 Jan 2011 00:48:11 -0000 Mailing-List: contact dev-help@shiro.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@shiro.apache.org Delivered-To: mailing list dev@shiro.apache.org Received: (qmail 28987 invoked by uid 99); 13 Jan 2011 00:48:11 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 13 Jan 2011 00:48:11 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 13 Jan 2011 00:48:09 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id p0D0llgI011493 for ; Thu, 13 Jan 2011 00:47:48 GMT Message-ID: <25258204.330391294879667658.JavaMail.jira@thor> Date: Wed, 12 Jan 2011 19:47:47 -0500 (EST) From: "Dan Diephouse (JIRA)" To: dev@shiro.apache.org Subject: [jira] Created: (SHIRO-234) ClassCastException in checkRoles MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org 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 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. - You can reply to this email to add a comment to the issue online.