The EJB spec says that you can use the name from Principal.getName() to filter database queries. This is fine for methods that are directly in the EJB because the principal is available from the session/entity context. However, I can't find a way for helper classes to get either their current thread's JAAS subject or the EJB context's principal. This leaves me with the options of: 1. Passing the principal to the helper class, through a method call or thread local. (Can it be bound in java:comp/env?) 2. Getting the query criteria from another EJB, say an entity bean or stateless session bean. The helper called from bean 1 can just look up the "query filter" factory bean and ask it for the filter information for the shared principal of the two. The helper class method can then be arbitrarily far up the stack from bean 1. Am I missing something? TIA, Tim Taylor -- -------------------------------------------------------------- To subscribe: [EMAIL PROTECTED] To unsubscribe: [EMAIL PROTECTED]
