]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
auth/cephx/CephxSessionHandler: use connection_secret for encryption
authorSage Weil <sage@redhat.com>
Tue, 8 Jan 2019 14:57:39 +0000 (08:57 -0600)
committerRicardo Dias <rdias@suse.com>
Wed, 23 Jan 2019 13:59:27 +0000 (13:59 +0000)
Signed-off-by: Sage Weil <sage@redhat.com>
src/auth/cephx/CephxSessionHandler.cc

index d40682f11bf0a642b8367cfd6c1decc4fe9f8e53..384e92c848bda55f61cf1be3656014c2b573056f 100644 (file)
@@ -207,7 +207,7 @@ int CephxSessionHandler::sign_bufferlist(bufferlist &in, bufferlist &out)
 int CephxSessionHandler::encrypt_bufferlist(bufferlist &in, bufferlist &out) {
   std::string error;
   try {
-    key.encrypt(cct, in, out, &error);
+    connection_secret.encrypt(cct, in, out, &error);
   } catch (std::exception &e) {
     lderr(cct) << __func__ << " failed to encrypt buffer: " << error << dendl;
     return -1;
@@ -218,7 +218,7 @@ int CephxSessionHandler::encrypt_bufferlist(bufferlist &in, bufferlist &out) {
 int CephxSessionHandler::decrypt_bufferlist(bufferlist &in, bufferlist &out) {
   std::string error;
   try {
-    key.decrypt(cct, in, out, &error);
+    connection_secret.decrypt(cct, in, out, &error);
   } catch (std::exception &e) {
     lderr(cct) << __func__ << " failed to decrypt buffer: " << error << dendl;
     return -1;