The following diagram describes the process for document security during a user session, and for queries, and the interaction between the different security components.