better error messages when encryption operations fail
set missing contentType headears to applicaiton/json