tests: Add corner-case test: fromServer points to dead server
commit24a02a31b5c2506fbbdfeec4ab773e433088a108
authorTim Beale <timbeale@catalyst.net.nz>
Fri, 28 Sep 2018 00:35:35 +0000 (28 12:35 +1200)
committerKarolin Seeger <kseeger@samba.org>
Mon, 5 Nov 2018 11:44:29 +0000 (5 12:44 +0100)
tree630a78f2b55154a1fd79f887f0cad308dfba0fe0
parent5e4e3daad5a906127c332516508ce4fc3de1ab18
tests: Add corner-case test: fromServer points to dead server

The fromServer attribute is slightly unique, in that it's a DN (similar
to a one-way link), but it is also a mandatory attribute.

Currently, if fromServer gets a bad value (i.e. a dead server that has
been expunged), the DSDB rejects any attempts to modify the associated
nTDSConnection object (regardless of whether or not you're actually
changing the fromServer attribute).

This patch adds a test-case that demonstrates how the DB can get into
such a state.

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

Signed-off-by: Tim Beale <timbeale@catalyst.net.nz>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
(cherry picked from commit dec3eda1f74f5bf7ea91c1be3d5dfd832e9672b9)
selftest/knownfail.d/attr_from_server [new file with mode: 0644]
source4/dsdb/tests/python/attr_from_server.py [new file with mode: 0644]
source4/selftest/tests.py