From b36dbd66d5308ddfd3b0e01e8e3190daa7e8f560 Mon Sep 17 00:00:00 2001 From: Yehuda Sadeh Date: Mon, 9 Nov 2009 16:54:08 -0800 Subject: [PATCH] auth: auth none encodes global_id at build_authorizer --- src/auth/none/AuthNoneClientHandler.h | 5 +++-- src/auth/none/AuthNoneProtocol.h | 4 +--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/auth/none/AuthNoneClientHandler.h b/src/auth/none/AuthNoneClientHandler.h index ecfac4b13e590..83199b22a89ee 100644 --- a/src/auth/none/AuthNoneClientHandler.h +++ b/src/auth/none/AuthNoneClientHandler.h @@ -34,8 +34,9 @@ public: AuthAuthorizer *build_authorizer(uint32_t service_id) { AuthNoneAuthorizer *auth = new AuthNoneAuthorizer(); - if (auth) - auth->build_authorizer(); + if (auth) { + auth->build_authorizer(global_id); + } return auth; } diff --git a/src/auth/none/AuthNoneProtocol.h b/src/auth/none/AuthNoneProtocol.h index 9ec4fc7044e98..0f70a6efbd17b 100644 --- a/src/auth/none/AuthNoneProtocol.h +++ b/src/auth/none/AuthNoneProtocol.h @@ -18,10 +18,8 @@ #include "../Auth.h" struct AuthNoneAuthorizer : public AuthAuthorizer { - uint64_t global_id; - AuthNoneAuthorizer() : AuthAuthorizer(CEPH_AUTH_NONE) { } - bool build_authorizer() { + bool build_authorizer(uint64_t global_id) { ::encode(*g_conf.entity_name, bl); ::encode(global_id, bl); return 0; -- 2.39.5