From fd5174e88ca1727a91d6dc9bf9bd898ff9087fe8 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Wed, 4 Nov 2009 17:42:53 +1100 Subject: lib/util Split data_blob_hex_string() into upper and lower Rather than have a repeat of the bugs we found at the plugfest where hexidecimal strings must be in upper or lower case in particular places, ensure that each caller chooses which case they want. This reverts most of the callers back to upper case, as things were before tridge's patch. The critical call in the extended DN code is of course handled in lower case. Andrew Bartlett --- source4/dsdb/samdb/ldb_modules/password_hash.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'source4/dsdb/samdb') diff --git a/source4/dsdb/samdb/ldb_modules/password_hash.c b/source4/dsdb/samdb/ldb_modules/password_hash.c index 7779a1752b..8791db2bc4 100644 --- a/source4/dsdb/samdb/ldb_modules/password_hash.c +++ b/source4/dsdb/samdb/ldb_modules/password_hash.c @@ -1137,7 +1137,7 @@ static int setup_supplemental_field(struct setup_password_fields_io *io) nt_errstr(status)); return LDB_ERR_OPERATIONS_ERROR; } - pknb_hexstr = data_blob_hex_string(io->ac, &pknb_blob); + pknb_hexstr = data_blob_hex_string_upper(io->ac, &pknb_blob); if (!pknb_hexstr) { ldb_oom(ldb); return LDB_ERR_OPERATIONS_ERROR; @@ -1169,7 +1169,7 @@ static int setup_supplemental_field(struct setup_password_fields_io *io) nt_errstr(status)); return LDB_ERR_OPERATIONS_ERROR; } - pkb_hexstr = data_blob_hex_string(io->ac, &pkb_blob); + pkb_hexstr = data_blob_hex_string_upper(io->ac, &pkb_blob); if (!pkb_hexstr) { ldb_oom(ldb); return LDB_ERR_OPERATIONS_ERROR; @@ -1200,7 +1200,7 @@ static int setup_supplemental_field(struct setup_password_fields_io *io) nt_errstr(status)); return LDB_ERR_OPERATIONS_ERROR; } - pdb_hexstr = data_blob_hex_string(io->ac, &pdb_blob); + pdb_hexstr = data_blob_hex_string_upper(io->ac, &pdb_blob); if (!pdb_hexstr) { ldb_oom(ldb); return LDB_ERR_OPERATIONS_ERROR; @@ -1229,7 +1229,7 @@ static int setup_supplemental_field(struct setup_password_fields_io *io) nt_errstr(status)); return LDB_ERR_OPERATIONS_ERROR; } - pcb_hexstr = data_blob_hex_string(io->ac, &pcb_blob); + pcb_hexstr = data_blob_hex_string_upper(io->ac, &pcb_blob); if (!pcb_hexstr) { ldb_oom(ldb); return LDB_ERR_OPERATIONS_ERROR; @@ -1255,7 +1255,7 @@ static int setup_supplemental_field(struct setup_password_fields_io *io) nt_errstr(status)); return LDB_ERR_OPERATIONS_ERROR; } - pb_hexstr = data_blob_hex_string(io->ac, &pb_blob); + pb_hexstr = data_blob_hex_string_upper(io->ac, &pb_blob); if (!pb_hexstr) { ldb_oom(ldb); return LDB_ERR_OPERATIONS_ERROR; -- cgit