summaryrefslogtreecommitdiff
path: root/source4/auth/credentials
diff options
context:
space:
mode:
Diffstat (limited to 'source4/auth/credentials')
-rw-r--r--source4/auth/credentials/credentials.i4
-rw-r--r--source4/auth/credentials/tests/bindings.py8
2 files changed, 12 insertions, 0 deletions
diff --git a/source4/auth/credentials/credentials.i b/source4/auth/credentials/credentials.i
index 2edda111b4..e694f93351 100644
--- a/source4/auth/credentials/credentials.i
+++ b/source4/auth/credentials/credentials.i
@@ -89,5 +89,9 @@ typedef struct cli_credentials {
bool is_anonymous(void);
const struct samr_Password *get_nt_hash(TALLOC_CTX *mem_ctx);
+
+ bool authentication_requested();
+
+ bool wrong_password();
}
} cli_credentials;
diff --git a/source4/auth/credentials/tests/bindings.py b/source4/auth/credentials/tests/bindings.py
index 9bb49a12a5..6253e8fbad 100644
--- a/source4/auth/credentials/tests/bindings.py
+++ b/source4/auth/credentials/tests/bindings.py
@@ -82,3 +82,11 @@ class CredentialsTests(unittest.TestCase):
def test_guess(self):
# Just check the method is there and doesn't raise an exception
self.creds.guess()
+
+ def test_authentication_requested(self):
+ self.assertFalse(self.creds.authentication_requested())
+
+ def test_wrong_password(self):
+ self.assertTrue(self.creds.wrong_password())
+ self.assertTrue(self.creds.wrong_password())
+ self.assertFalse(self.creds.wrong_password())