ctdb-daemon: Only consider client ID for local database attach
authorMartin Schwenke <martin@meltin.net>
Tue, 26 Jun 2018 10:12:23 +0000 (20:12 +1000)
committerMartin Schwenke <martins@samba.org>
Mon, 2 Jul 2018 06:51:22 +0000 (08:51 +0200)
commit63255ef92552da92956c05160f33622d0bbc3a28
tree56d7c596e588221c82b1122da02a9bb4de50f31c
parentaf446d5209e37a38363911e5f339869b73d87963
ctdb-daemon: Only consider client ID for local database attach

The comment immediately above this code says "don't allow local
clients to attach" and then looks up the client ID regardless of
whether the request is local or remote.

This means that an intentional remote attach from a client will not
work correctly.  No real client should ever do that since clients
attach so they an access databases locally.  Perhaps some sanity
checks should be added.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13500

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
ctdb/include/ctdb_private.h
ctdb/server/ctdb_control.c
ctdb/server/ctdb_ltdb_server.c