summaryrefslogtreecommitdiff
path: root/source4/auth/credentials/credentials.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/auth/credentials/credentials.c')
-rw-r--r--source4/auth/credentials/credentials.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source4/auth/credentials/credentials.c b/source4/auth/credentials/credentials.c
index 09366e8d54..549c2691f0 100644
--- a/source4/auth/credentials/credentials.c
+++ b/source4/auth/credentials/credentials.c
@@ -750,6 +750,11 @@ _PUBLIC_ bool cli_credentials_is_anonymous(struct cli_credentials *cred)
{
const char *username;
+ /* if bind dn is set it's not anonymous */
+ if (cred->bind_dn) {
+ return false;
+ }
+
if (cred->machine_account_pending) {
cli_credentials_set_machine_account(cred,
cred->machine_account_pending_lp_ctx);