]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
msg/async/ProtocolV1: resurrect "implement cephx_*require_version options"
authorIlya Dryomov <idryomov@gmail.com>
Fri, 16 Oct 2020 09:35:27 +0000 (11:35 +0200)
committerIlya Dryomov <idryomov@gmail.com>
Tue, 10 Nov 2020 06:45:36 +0000 (07:45 +0100)
commit4c11203122d729c832a645c9e3f5092db4963840
tree01e13a5f545ffc94a097bf40fd6481ec04e9ae7a
parentbb5d3d58bfcae96d2e5f796eaa74fc0987f79e77
msg/async/ProtocolV1: resurrect "implement cephx_*require_version options"

This was added in commit 9bcbc2a3621f ("mon,msg: implement
cephx_*_require_version options") and inadvertently dropped in
commit e6f043f7d2dc ("msgr/async: huge refactoring of protocol V1").
As a result, service daemons don't enforce cephx_require_version
and cephx_cluster_require_version options and connections without
CEPH_FEATURE_CEPHX_V2 are allowed through.

(cephx_service_require_version enforcement was brought back a
year later in commit 321548010578 ("mon/MonClient: skip CEPHX_V2
challenge if client doesn't support it"), although the peer gets
TAG_BADAUTHORIZER instead of TAG_FEATURES.)

Resurrect the original behaviour: all cephx_*require_version
options are enforced and the peer gets TAG_FEATURES, signifying
that it is missing a required feature.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit 6f5c4152ca2c6423e665cde2196c6301f76043a2)

Conflicts:
src/msg/async/ProtocolV1.cc [ drop nautilus-only commit
  89ffece49097 ("msg/async/ProtocolV1: require CEPHX_V2 if
  cephx_service_require_version >= 2") ]
src/msg/async/ProtocolV1.cc