aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIlya Dryomov <idryomov@gmail.com>2015-10-27 11:42:49 -0400
committerIlya Dryomov <idryomov@gmail.com>2015-11-02 17:37:46 -0500
commit4199b8eec36405822619d4176bddfacf7b47eb44 (patch)
tree72be3f78fafca024ac01532f079d57194424e3dc
parent79dbd1baa651cece408e68a1b445f3628c4b5bdc (diff)
libceph: drop authorizer check from cephx msg signing routines
I don't see a way for auth->authorizer to be NULL in ceph_x_sign_message() or ceph_x_check_message_signature(). Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
-rw-r--r--net/ceph/auth_x.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/net/ceph/auth_x.c b/net/ceph/auth_x.c
index 65054fd31b97..3a544ca6b5ce 100644
--- a/net/ceph/auth_x.c
+++ b/net/ceph/auth_x.c
@@ -697,8 +697,7 @@ static int ceph_x_sign_message(struct ceph_auth_handshake *auth,
697 struct ceph_msg *msg) 697 struct ceph_msg *msg)
698{ 698{
699 int ret; 699 int ret;
700 if (!auth->authorizer) 700
701 return 0;
702 ret = calcu_signature((struct ceph_x_authorizer *)auth->authorizer, 701 ret = calcu_signature((struct ceph_x_authorizer *)auth->authorizer,
703 msg, &msg->footer.sig); 702 msg, &msg->footer.sig);
704 if (ret < 0) 703 if (ret < 0)
@@ -713,8 +712,6 @@ static int ceph_x_check_message_signature(struct ceph_auth_handshake *auth,
713 __le64 sig_check; 712 __le64 sig_check;
714 int ret; 713 int ret;
715 714
716 if (!auth->authorizer)
717 return 0;
718 ret = calcu_signature((struct ceph_x_authorizer *)auth->authorizer, 715 ret = calcu_signature((struct ceph_x_authorizer *)auth->authorizer,
719 msg, &sig_check); 716 msg, &sig_check);
720 if (ret < 0) 717 if (ret < 0)