From b82881591cd1c63ed28d14ab31a652ef5319b2d0 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Mon, 5 Jul 2004 07:24:14 +0000 Subject: [PATCH] r1335: NT_STATUS_INTERNAL_DB_CORRUPTION should cause DEBUG(0,(...)); metze (This used to be commit 80851e67783a9c3c8bdd7f2b52e0b46dd7b18d05) --- source4/auth/auth_sam.c | 4 +-- source4/rpc_server/netlogon/dcerpc_netlogon.c | 8 +++--- source4/rpc_server/netlogon/schannel_state.c | 2 +- source4/rpc_server/samr/dcesrv_samr.c | 26 +++++++++---------- 4 files changed, 20 insertions(+), 20 deletions(-) diff --git a/source4/auth/auth_sam.c b/source4/auth/auth_sam.c index 280c57ea560..ac7a6e56936 100644 --- a/source4/auth/auth_sam.c +++ b/source4/auth/auth_sam.c @@ -235,7 +235,7 @@ static NTSTATUS check_sam_security(const struct auth_context *auth_context, } if (ret > 1) { - DEBUG(1,("Found %d records matching user [%s]\n", ret, username)); + DEBUG(0,("Found %d records matching user [%s]\n", ret, username)); samdb_close(sam_ctx); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -259,7 +259,7 @@ static NTSTATUS check_sam_security(const struct auth_context *auth_context, } if (ret_domain > 1) { - DEBUG(1,("Found %d records matching domain [%s]\n", + DEBUG(0,("Found %d records matching domain [%s]\n", ret_domain, domain_sid)); samdb_close(sam_ctx); return NT_STATUS_INTERNAL_DB_CORRUPTION; diff --git a/source4/rpc_server/netlogon/dcerpc_netlogon.c b/source4/rpc_server/netlogon/dcerpc_netlogon.c index 7eb4c0e815b..9f0ca5443a5 100644 --- a/source4/rpc_server/netlogon/dcerpc_netlogon.c +++ b/source4/rpc_server/netlogon/dcerpc_netlogon.c @@ -199,7 +199,7 @@ static NTSTATUS netr_ServerAuthenticate3(struct dcesrv_call_state *dce_call, TAL } if (num_records > 1) { - DEBUG(1,("Found %d records matching user [%s]\n", num_records, r->in.account_name)); + DEBUG(0,("Found %d records matching user [%s]\n", num_records, r->in.account_name)); samdb_close(sam_ctx); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -390,7 +390,7 @@ static NTSTATUS netr_ServerPasswordSet(struct dcesrv_call_state *dce_call, TALLO } if (num_records > 1) { - DEBUG(1,("Found %d records matching user [%s]\n", num_records, + DEBUG(0,("Found %d records matching user [%s]\n", num_records, pipe_state->account_name)); samdb_close(sam_ctx); return NT_STATUS_INTERNAL_DB_CORRUPTION; @@ -399,7 +399,7 @@ static NTSTATUS netr_ServerPasswordSet(struct dcesrv_call_state *dce_call, TALLO domain_sid = samdb_result_sid_prefix(mem_ctx, msgs[0], "objectSid"); if (!domain_sid) { samdb_close(sam_ctx); - DEBUG(1,("no objectSid in user record\n")); + DEBUG(0,("no objectSid in user record\n")); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -417,7 +417,7 @@ static NTSTATUS netr_ServerPasswordSet(struct dcesrv_call_state *dce_call, TALLO } if (num_records_domain > 1) { - DEBUG(1,("Found %d records matching domain [%s]\n", + DEBUG(0,("Found %d records matching domain [%s]\n", num_records_domain, domain_sid)); samdb_close(sam_ctx); return NT_STATUS_INTERNAL_DB_CORRUPTION; diff --git a/source4/rpc_server/netlogon/schannel_state.c b/source4/rpc_server/netlogon/schannel_state.c index 43134fd437f..f64aabb1bf1 100644 --- a/source4/rpc_server/netlogon/schannel_state.c +++ b/source4/rpc_server/netlogon/schannel_state.c @@ -98,7 +98,7 @@ NTSTATUS schannel_store_session_key(TALLOC_CTX *mem_ctx, ret = ldb_add(ldb, &msg); if (ret != 0) { - DEBUG(1,("Unable to add %s to session key db - %s\n", msg.dn, ldb_errstring(ldb))); + DEBUG(0,("Unable to add %s to session key db - %s\n", msg.dn, ldb_errstring(ldb))); ldb_close(ldb); return NT_STATUS_INTERNAL_DB_CORRUPTION; } diff --git a/source4/rpc_server/samr/dcesrv_samr.c b/source4/rpc_server/samr/dcesrv_samr.c index 7eb24f4bd1c..4028a853d70 100644 --- a/source4/rpc_server/samr/dcesrv_samr.c +++ b/source4/rpc_server/samr/dcesrv_samr.c @@ -201,7 +201,7 @@ static NTSTATUS samr_LookupDomain(struct dcesrv_call_state *dce_call, TALLOC_CTX sid = dom_sid_parse_talloc(mem_ctx, sidstr); if (sid == NULL) { - DEBUG(1,("samdb: Invalid sid '%s' for domain %s\n", + DEBUG(0,("samdb: Invalid sid '%s' for domain %s\n", sidstr, r->in.domain->name)); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -238,7 +238,7 @@ static NTSTATUS samr_EnumDomains(struct dcesrv_call_state *dce_call, TALLOC_CTX mem_ctx, NULL, &domains, "name", "(objectclass=domain)"); if (count == -1) { - DEBUG(1,("samdb: no domains found in EnumDomains\n")); + DEBUG(0,("samdb: no domains found in EnumDomains\n")); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -513,7 +513,7 @@ static NTSTATUS samr_CreateDomainGroup(struct dcesrv_call_state *dce_call, TALLO ret = samdb_copy_template(d_state->sam_ctx, mem_ctx, &msg, "(&(name=TemplateGroup)(objectclass=groupTemplate))"); if (ret != 0) { - DEBUG(1,("Failed to load TemplateGroup from samdb\n")); + DEBUG(0,("Failed to load TemplateGroup from samdb\n")); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -554,7 +554,7 @@ static NTSTATUS samr_CreateDomainGroup(struct dcesrv_call_state *dce_call, TALLO /* create the group */ ret = samdb_add(d_state->sam_ctx, mem_ctx, &msg); if (ret != 0) { - DEBUG(1,("Failed to create group record %s\n", msg.dn)); + DEBUG(0,("Failed to create group record %s\n", msg.dn)); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -660,7 +660,7 @@ static NTSTATUS samr_CreateUser2(struct dcesrv_call_state *dce_call, TALLOC_CTX ret = samdb_copy_template(d_state->sam_ctx, mem_ctx, &msg, "(&(name=TemplateUser)(objectclass=userTemplate))"); if (ret != 0) { - DEBUG(1,("Failed to load TemplateUser from samdb\n")); + DEBUG(0,("Failed to load TemplateUser from samdb\n")); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -671,7 +671,7 @@ static NTSTATUS samr_CreateUser2(struct dcesrv_call_state *dce_call, TALLOC_CTX ret = samdb_copy_template(d_state->sam_ctx, mem_ctx, &msg, "(&(name=TemplateMemberServer)(objectclass=userTemplate))"); if (ret != 0) { - DEBUG(1,("Failed to load TemplateMemberServer from samdb\n")); + DEBUG(0,("Failed to load TemplateMemberServer from samdb\n")); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -683,7 +683,7 @@ static NTSTATUS samr_CreateUser2(struct dcesrv_call_state *dce_call, TALLOC_CTX ret = samdb_copy_template(d_state->sam_ctx, mem_ctx, &msg, "(&(name=TemplateDomainController)(objectclass=userTemplate))"); if (ret != 0) { - DEBUG(1,("Failed to load TemplateDomainController from samdb\n")); + DEBUG(0,("Failed to load TemplateDomainController from samdb\n")); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -695,7 +695,7 @@ static NTSTATUS samr_CreateUser2(struct dcesrv_call_state *dce_call, TALLOC_CTX ret = samdb_copy_template(d_state->sam_ctx, mem_ctx, &msg, "(&(name=TemplateTrustingDomain)(objectclass=userTemplate))"); if (ret != 0) { - DEBUG(1,("Failed to load TemplateTrustingDomain from samdb\n")); + DEBUG(0,("Failed to load TemplateTrustingDomain from samdb\n")); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -738,7 +738,7 @@ static NTSTATUS samr_CreateUser2(struct dcesrv_call_state *dce_call, TALLOC_CTX /* create the user */ ret = samdb_add(d_state->sam_ctx, mem_ctx, &msg); if (ret != 0) { - DEBUG(1,("Failed to create user record %s\n", msg.dn)); + DEBUG(0,("Failed to create user record %s\n", msg.dn)); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -1050,13 +1050,13 @@ static NTSTATUS samr_OpenGroup(struct dcesrv_call_state *dce_call, TALLOC_CTX *m return NT_STATUS_NO_SUCH_GROUP; } if (ret != 1) { - DEBUG(1,("Found %d records matching sid %s\n", ret, sidstr)); + DEBUG(0,("Found %d records matching sid %s\n", ret, sidstr)); return NT_STATUS_INTERNAL_DB_CORRUPTION; } groupname = samdb_result_string(msgs[0], "sAMAccountName", NULL); if (groupname == NULL) { - DEBUG(1,("sAMAccountName field missing for sid %s\n", sidstr)); + DEBUG(0,("sAMAccountName field missing for sid %s\n", sidstr)); return NT_STATUS_INTERNAL_DB_CORRUPTION; } @@ -1429,13 +1429,13 @@ static NTSTATUS samr_OpenUser(struct dcesrv_call_state *dce_call, TALLOC_CTX *me return NT_STATUS_NO_SUCH_USER; } if (ret != 1) { - DEBUG(1,("Found %d records matching sid %s\n", ret, sidstr)); + DEBUG(0,("Found %d records matching sid %s\n", ret, sidstr)); return NT_STATUS_INTERNAL_DB_CORRUPTION; } account_name = samdb_result_string(msgs[0], "sAMAccountName", NULL); if (account_name == NULL) { - DEBUG(1,("sAMAccountName field missing for sid %s\n", sidstr)); + DEBUG(0,("sAMAccountName field missing for sid %s\n", sidstr)); return NT_STATUS_INTERNAL_DB_CORRUPTION; }