-/*
+/*
ldb database module
Copyright (C) Simo Sorce 2004-2008
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
-
+
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
-
+
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
return ldb_next_request(module, request);
}
-/* Get the NT hash, and fill it in as an entry in the password history,
+/* Get the NT hash, and fill it in as an entry in the password history,
and specify it into io->g.nt_hash */
static int setup_nt_fields(struct setup_password_fields_io *io)
.user = &sAMAccountName_l,
.realm = &dns_domain_u,
},
- /*
+ /*
* userPrincipalName, no realm
*/
{
.user = &userPrincipalName,
},
{
- /*
+ /*
* NOTE: w2k3 messes this up, if the user has a real userPrincipalName,
* the fallback to the sAMAccountName based userPrincipalName is correct
*/
{
.user = &userPrincipalName_u,
},
- /*
+ /*
* nt4dom\sAMAccountName, no realm
*/
{
io->ac->status->domain_data.dns_domain);
if (!user_principal_name) {
return ldb_oom(ldb);
- }
+ }
}
userPrincipalName = data_blob_string_const(user_principal_name);
userPrincipalName_l = data_blob_string_const(strlower_talloc(io->ac, user_principal_name));
return LDB_SUCCESS;
}
-static int setup_io(struct ph_context *ac,
+static int setup_io(struct ph_context *ac,
const struct ldb_message *client_msg,
const struct ldb_message *existing_msg,
- struct setup_password_fields_io *io)
-{
+ struct setup_password_fields_io *io)
+{
const struct ldb_val *quoted_utf16, *old_quoted_utf16, *lm_hash, *old_lm_hash;
struct ldb_context *ldb = ldb_module_get_ctx(ac->module);
struct loadparm_context *lp_ctx = talloc_get_type(