Trust and risk-based access control for privacy preserving threat detection systems