summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mdw@samba.org>2010-06-12 15:47:14 +0200
committerMatthias Dieter Wallnöfer <mdw@samba.org>2010-06-28 14:51:06 +0200
commitc0160d0614ad74be275d4008559a45da3d79d2e7 (patch)
treea9669b446486d4e3ffb4c1b0665d4181a8ca6752 /source4
parentb200d8a5ca2d58f5351b6963c864aa52db925f65 (diff)
downloadsamba-c0160d0614ad74be275d4008559a45da3d79d2e7.tar.gz
samba-c0160d0614ad74be275d4008559a45da3d79d2e7.tar.bz2
samba-c0160d0614ad74be275d4008559a45da3d79d2e7.zip
s4:torture - SAMR password tests - activate support for password sets on level "18" and "21"
Diffstat (limited to 'source4')
-rw-r--r--source4/torture/rpc/samr.c39
1 files changed, 17 insertions, 22 deletions
diff --git a/source4/torture/rpc/samr.c b/source4/torture/rpc/samr.c
index c514ed6188..8a8520c25f 100644
--- a/source4/torture/rpc/samr.c
+++ b/source4/torture/rpc/samr.c
@@ -4684,34 +4684,29 @@ static bool test_user_ops(struct dcerpc_pipe *p,
ret = false;
}
- if (torture_setting_bool(tctx, "samba4", false)) {
- torture_comment(tctx, "skipping Set Password level 18 and 21 against Samba4\n");
- } else {
+ if (!test_SetUserPass_18(p, tctx, user_handle, &password)) {
+ ret = false;
+ }
- if (!test_SetUserPass_18(p, tctx, user_handle, &password)) {
- ret = false;
+ if (!test_ChangePasswordUser3(p, tctx, base_acct_name, 0, &password, NULL, 0, false)) {
+ ret = false;
+ }
+
+ for (i = 0; password_fields[i]; i++) {
+
+ if (password_fields[i] == SAMR_FIELD_LM_PASSWORD_PRESENT) {
+ /* we need to skip as that would break
+ * the ChangePasswordUser3 verify */
+ continue;
}
- if (!test_ChangePasswordUser3(p, tctx, base_acct_name, 0, &password, NULL, 0, false)) {
+ if (!test_SetUserPass_21(p, tctx, user_handle, password_fields[i], &password)) {
ret = false;
}
- for (i = 0; password_fields[i]; i++) {
-
- if (password_fields[i] == SAMR_FIELD_LM_PASSWORD_PRESENT) {
- /* we need to skip as that would break
- * the ChangePasswordUser3 verify */
- continue;
- }
-
- if (!test_SetUserPass_21(p, tctx, user_handle, password_fields[i], &password)) {
- ret = false;
- }
-
- /* check it was set right */
- if (!test_ChangePasswordUser3(p, tctx, base_acct_name, 0, &password, NULL, 0, false)) {
- ret = false;
- }
+ /* check it was set right */
+ if (!test_ChangePasswordUser3(p, tctx, base_acct_name, 0, &password, NULL, 0, false)) {
+ ret = false;
}
}