tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From A <joey122...@yahoo.com>
Subject GenericPrincipal classcast BUG
Date Tue, 24 Aug 2004 09:31:44 GMT
Developers - 

I have read the WIKI about problems with classcast of
a java.lang.Security object.   Here it is

 http://wiki.apache.org/jakarta-tomcat/Tomcat/Howto

 Even though i have System.out.println statements in
my implementation of the Principal class - and i know
that my principal is being authenticated i keep
getting back an object which is of type

org.apache.... GenericPrincipal when in fact it should
be my own Principal object - Can someone let me know
what i have done wrong?  I  have run out of ideas.


//override superclass implementation - 
protected String getRelativePath(HttpServletRequest
request) {
ExtendedPrincipal principal = (ExtendedPrincipal)
request.getUserPrincipal();
}

throws Class Cast Exceptrion 


public interface ExtendedPrincipal extends
java.security.Principal{
public String getEmailAddress();
}




__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message