Hi Andrea , I am unsure by what you mean by passing down the interface.
Would you be able to be more specific? I am unsure how the code works as i was not able to replicate the issue on my local machine J
I tried the following
return (FeatureIterator) SecuredObjects.secure((FeatureIterator)delegate.features(), policy);
FeatureCollection fc=(FeatureCollection)SecuredObjects.secure(delegate.features(), policy);
return fc.features();
both to no avail.
I am just taking shots in the dark. Once again thanks
IMappingFeatureIterator extends Iterator, FeatureIterator
This might be the cause but I am unsure why it would cause an error casting to FeatureIterator.
From: andrea.aime@anonymised.com [mailto:andrea.aime@…403…] On Behalf Of Andrea Aime
Sent: Monday, 11 April 2011 11:58 PM
To: Justin Deoliveira
Cc: Tey, Victor (CESRE, Kensington); Geotools-Devel list
Subject: Re: [Geotools-devel] ava.lang.ClassCastException: org.geoserver.security.decorators.SecuredIterator
On Mon, Apr 11, 2011 at 4:39 PM, Justin Deoliveira <jdeolive@anonymised.com> wrote:
Hi Victor,
I believe this is a more specifically a geoserver issue… you should probably move the conversation there. As for the fix I still think modifying the SecuredObject* interfaces in geoserver to explicitly pass down the interface is the most robust option. But that is something for discussion on geoserver-devel.
Passing down the interface might be an option, another one could be a security wrapper that implements
both interfaces, so that we don’t even have to decide
Cheers
Andrea
–
Ing. Andrea Aime
GeoSolutions S.A.S.
Tech lead
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 962313
mob: +39 333 8128928
http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf