Security agents for information retrieval in distributed systems