tests: Add tests for domain pwdHistoryLength
authorTim Beale <timbeale@catalyst.net.nz>
Thu, 10 May 2018 21:29:01 +0000 (09:29 +1200)
committerGarming Sam <garming@samba.org>
Wed, 23 May 2018 04:55:32 +0000 (06:55 +0200)
commitb7d1c5aae8530126f1e561911ae3adaa527c189f
treede51ae766020f15771e5c7072a6968274c9ae188
parentc10e1af005270d6d212f8e703d0fb7c5ff3430bc
tests: Add tests for domain pwdHistoryLength

This is not related to PSOs at all, but there's a minor discrepancy
between Windows and Samba password-history-length behaviour that I
noticed during PSO testing.

When the pwdHistoryLength changes from zero to non-zero, Windows
includes the user's current password as invalid immediately, whereas
Samba only includes it as invalid *after* it next changes. It's a
fairly obscure corner-case, and we might not care enough about it to
fix it. However, I've added a test case to highlight the difference and
marked it as a known-fail for now.

I also added a general pwdHistoryLength test case to show that the
basics work (this didn't seem to be tested anywhere else).

Signed-off-by: Tim Beale <timbeale@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
selftest/knownfail.d/password_settings [new file with mode: 0644]
source4/dsdb/tests/python/password_settings.py