CoDE : An application-layer framework for confidentiality in distributed environments