summaryrefslogtreecommitdiff
path: root/plugins/gnusocial/BridgeGnusocial.php
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/gnusocial/BridgeGnusocial.php')
-rw-r--r--plugins/gnusocial/BridgeGnusocial.php14
1 files changed, 14 insertions, 0 deletions
diff --git a/plugins/gnusocial/BridgeGnusocial.php b/plugins/gnusocial/BridgeGnusocial.php
new file mode 100644
index 0000000..bfac3fb
--- /dev/null
+++ b/plugins/gnusocial/BridgeGnusocial.php
@@ -0,0 +1,14 @@
+<?php
+
+/**
+ * Implements EjabberdAuthBridge.
+ */
+class BridgeGnusocial extends EjabberdAuthBridge {
+ function isuser($username, $server) {
+ return Nickname::isTaken($username) != null;
+ }
+
+ function auth($username, $server, $password) {
+ return common_check_user($username, $password) instanceof User;
+ }
+}