1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

dsdb: Allow DSDB_CONTROL_PASSWORD_BYPASS_LAST_SET_OID to be specified as a flag

This commit is contained in:
Andrew Bartlett 2012-01-24 18:36:49 +11:00
parent 1f0298dd1b
commit 1a9ee7cbd5
2 changed files with 8 additions and 0 deletions

View File

@ -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) {

View File

@ -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);