aboutsummaryrefslogtreecommitdiffstats
path: root/apps/user_ldap/lib/IUserLDAP.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/user_ldap/lib/IUserLDAP.php')
-rw-r--r--apps/user_ldap/lib/IUserLDAP.php33
1 files changed, 33 insertions, 0 deletions
diff --git a/apps/user_ldap/lib/IUserLDAP.php b/apps/user_ldap/lib/IUserLDAP.php
new file mode 100644
index 00000000000..5e8e29c3adf
--- /dev/null
+++ b/apps/user_ldap/lib/IUserLDAP.php
@@ -0,0 +1,33 @@
+<?php
+
+/**
+ * SPDX-FileCopyrightText: 2016 Nextcloud GmbH and Nextcloud contributors
+ * SPDX-License-Identifier: AGPL-3.0-or-later
+ */
+namespace OCA\User_LDAP;
+
+interface IUserLDAP {
+
+ //Functions used by LDAPProvider
+
+ /**
+ * Return access for LDAP interaction.
+ * @param string $uid
+ * @return Access instance of Access for LDAP interaction
+ */
+ public function getLDAPAccess($uid);
+
+ /**
+ * Return a new LDAP connection for the specified user.
+ * @param string $uid
+ * @return \LDAP\Connection of the LDAP connection
+ */
+ public function getNewLDAPConnection($uid);
+
+ /**
+ * Return the username for the given LDAP DN, if available.
+ * @param string $dn
+ * @return string|false with the username
+ */
+ public function dn2UserName($dn);
+}