On Wed, Jun 27, 2001 at 09:25:56PM -0400, Allen fogleson wrote:
> it would just be a mess if you had to have method permissions for separate
> users, and not very dynamic at all. thats what roles are for.

What I would have liked is a method in entity beans called
checkAccess() that would be called after data is loaded for the entity
bean. There I could do my security checking (typically checking
against a security coloumn I have added) and if I return false, an
appropriate security exception would be thrown and the contents of the
entity bean would not be made available to the current context.

checkAccess would typically be called only when the bean determines it
needs to load the data (for lazy loading) so the calling code would
need to either catch the security exception and skip that bean, or it
could be lazy and just abort (i.e., let it go to the next outer
layer).

I would still implement my searches so that I never _do_ get data I am
not supposed to, but I would like this level of redundancy to be
absolutely sure nobody gets information they shouldn't get. Getting
security exceptions would therefore in most cases be the result of
either a bug or of lazy programming. I still think it would be an
important addition.

I might be able to use ejbLoad() and/or ejbPostCreate() for this, but
I have yet to investigate how feasible this is.

Cheers
        Bent D
-- 
Bent Dalager - [EMAIL PROTECTED] - http://www.pvv.org/~bcd
                                    powered by emacs

_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to