From: Andrew Bartlett Date: Wed, 14 Sep 2022 21:36:45 +0000 (+1200) Subject: selftest: Prepare for "old Samba" mode regarding getncchanges GET_ANC/GET_TGT X-Git-Tag: talloc-2.4.0~778 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=62b426243f4eaa4978c249b6e6ce90d35aeaefe4;p=thirdparty%2Fsamba.git selftest: Prepare for "old Samba" mode regarding getncchanges GET_ANC/GET_TGT The chgdcpass environment will emulate older verions of Samba that fail to implement DRSUAPI_DRS_GET_ANC correctly and totally fails to support DRSUAPI_DRS_GET_TGT. This will allow testing of a client-side fallback, allowing migration from sites that run very old Samba versions over DRSUAPI (currently the only option is to attempt an in-place upgrade). BUG: https://bugzilla.samba.org/show_bug.cgi?id=15189 Signed-off-by: Andrew Bartlett Reviewed-by: Douglas Bagnall --- diff --git a/selftest/knownfail.d/samba-4.5-emulation b/selftest/knownfail.d/samba-4.5-emulation new file mode 100644 index 00000000000..82959240588 --- /dev/null +++ b/selftest/knownfail.d/samba-4.5-emulation @@ -0,0 +1,2 @@ +# This fails as there is no second DC in this enviroment, so it is always the owner +samba4.drs.getnc_exop.python\(chgdcpass\).getnc_exop.DrsReplicaSyncTestCase.test_FSMONotOwner\(chgdcpass\) \ No newline at end of file diff --git a/source4/selftest/tests.py b/source4/selftest/tests.py index e63e9b40bf8..67d800c47ab 100755 --- a/source4/selftest/tests.py +++ b/source4/selftest/tests.py @@ -1561,11 +1561,6 @@ for env in ['vampire_dc', 'promoted_dc']: name="samba4.drs.repl_move.python(%s)" % env, environ={'DC1': "$DC_SERVER", 'DC2': '$SERVER'}, extra_args=['-U$DOMAIN/$DC_USERNAME%$DC_PASSWORD']) - planoldpythontestsuite(env, "getnc_exop", - extra_path=[os.path.join(samba4srcdir, 'torture/drs/python')], - name="samba4.drs.getnc_exop.python(%s)" % env, - environ={'DC1': "$DC_SERVER", 'DC2': '$SERVER'}, - extra_args=['-U$DOMAIN/$DC_USERNAME%$DC_PASSWORD']) planoldpythontestsuite(env, "getnc_unpriv", extra_path=[os.path.join(samba4srcdir, 'torture/drs/python')], name="samba4.drs.getnc_unpriv.python(%s)" % env, @@ -1582,6 +1577,15 @@ for env in ['vampire_dc', 'promoted_dc']: environ={'DC1': "$DC_SERVER", 'DC2': '$SERVER'}, extra_args=['-U$DOMAIN/$DC_USERNAME%$DC_PASSWORD']) +# Environment chgdcpass has the Samba 4.5 GET_ANC behaviour, which we +# set a knownfail to expect +for env in ['vampire_dc', 'promoted_dc', 'chgdcpass']: + planoldpythontestsuite(env, "getnc_exop", + extra_path=[os.path.join(samba4srcdir, 'torture/drs/python')], + name="samba4.drs.getnc_exop.python(%s)" % env, + environ={'DC1': "$DC_SERVER", 'DC2': '$SERVER'}, + extra_args=['-U$DOMAIN/$DC_USERNAME%$DC_PASSWORD']) + for env in ['vampire_dc', 'promoted_dc', 'vampire_2000_dc']: planoldpythontestsuite(env, "repl_schema", extra_path=[os.path.join(samba4srcdir, 'torture/drs/python')],