Generalized communication encryption