summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
Diffstat (limited to 'source4')
-rw-r--r--source4/dsdb/common/util.c7
-rw-r--r--source4/dsdb/common/util.h1
2 files changed, 8 insertions, 0 deletions
diff --git a/source4/dsdb/common/util.c b/source4/dsdb/common/util.c
index 38391a9998..814faa607c 100644
--- a/source4/dsdb/common/util.c
+++ b/source4/dsdb/common/util.c
@@ -3725,6 +3725,13 @@ int dsdb_request_add_controls(struct ldb_request *req, uint32_t dsdb_flags)
}
}
+ if (dsdb_flags & DSDB_PASSWORD_BYPASS_LAST_SET) {
+ ret = ldb_request_add_control(req, DSDB_CONTROL_PASSWORD_BYPASS_LAST_SET_OID, true, NULL);
+ if (ret != LDB_SUCCESS) {
+ return ret;
+ }
+ }
+
if (dsdb_flags & DSDB_MODIFY_PARTIAL_REPLICA) {
ret = ldb_request_add_control(req, DSDB_CONTROL_PARTIAL_REPLICA, false, NULL);
if (ret != LDB_SUCCESS) {
diff --git a/source4/dsdb/common/util.h b/source4/dsdb/common/util.h
index b2f7aa5b32..5ec19fb776 100644
--- a/source4/dsdb/common/util.h
+++ b/source4/dsdb/common/util.h
@@ -38,6 +38,7 @@
#define DSDB_BYPASS_PASSWORD_HASH 0x1000
#define DSDB_SEARCH_NO_GLOBAL_CATALOG 0x2000
#define DSDB_MODIFY_PARTIAL_REPLICA 0x4000
+#define DSDB_PASSWORD_BYPASS_LAST_SET 0x8000
bool is_attr_in_list(const char * const * attrs, const char *attr);