summaryrefslogtreecommitdiffstats
path: root/imap/auth.h
diff options
context:
space:
mode:
authorThomas Roessler <roessler@does-not-exist.org>2000-07-31 07:18:28 +0000
committerThomas Roessler <roessler@does-not-exist.org>2000-07-31 07:18:28 +0000
commit61333b001c09fb24709398d2ad2dae16b8451080 (patch)
treec9cfc5f76b32aa8f3a2780d213079be6f68a0c30 /imap/auth.h
parente15e685b533f3817a9adb99824f03f03342c64d9 (diff)
Brendan Cully's SASL patch. I hope I didn't miss any files.
Diffstat (limited to 'imap/auth.h')
-rw-r--r--imap/auth.h45
1 files changed, 45 insertions, 0 deletions
diff --git a/imap/auth.h b/imap/auth.h
new file mode 100644
index 00000000..bf3f2c21
--- /dev/null
+++ b/imap/auth.h
@@ -0,0 +1,45 @@
+/*
+ * Copyright (C) 2000 Brendan Cully <brendan@kublai.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
+ */
+
+/* common defs for authenticators. A good place to set up a generic callback
+ * system */
+
+#ifndef _IMAP_AUTH_H
+#define _IMAP_AUTH_H 1
+
+typedef enum
+{
+ IMAP_AUTH_SUCCESS = 0,
+ IMAP_AUTH_FAILURE,
+ IMAP_AUTH_UNAVAIL
+} imap_auth_res_t;
+
+typedef imap_auth_res_t (*imap_auth_t)(IMAP_DATA* idata);
+
+/* external authenticator prototypes */
+imap_auth_res_t imap_auth_anon (IMAP_DATA* idata);
+imap_auth_res_t imap_auth_cram_md5 (IMAP_DATA* idata);
+imap_auth_res_t imap_auth_login (IMAP_DATA* idata);
+#ifdef USE_GSS
+imap_auth_res_t imap_auth_gss (IMAP_DATA* idata);
+#endif
+#ifdef USE_SASL
+imap_auth_res_t imap_auth_sasl (IMAP_DATA* idata);
+#endif
+
+#endif /* _IMAP_AUTH_H */