Группа :: Система/Серверы
Пакет: postfix
Главная Изменения Спек Патчи Загрузить Bugs and FR
Патч: postfix-2.2.4-deb-alt-sasl-config.patch
diff -upk.orig postfix-2.2.4.orig/src/lmtp/lmtp_sasl_glue.c postfix-2.2.4/src/lmtp/lmtp_sasl_glue.c
--- postfix-2.2.4.orig/src/lmtp/lmtp_sasl_glue.c 2005-04-13 14:09:47 +0000
+++ postfix-2.2.4/src/lmtp/lmtp_sasl_glue.c 2005-06-23 12:21:56 +0000
@@ -197,6 +197,16 @@ static int lmtp_sasl_log(void *unused_co
return (SASL_OK);
}
+static int lmtp_sasl_getpath(void * context, char ** path)
+{
+#if SASL_VERSION_MAJOR >= 2
+ *path = strdup("/etc/postfix/sasl:/usr/lib/sasl2");
+#else
+ *path = strdup("/etc/postfix/sasl:/usr/lib/sasl");
+#endif
+ return SASL_OK;
+}
+
/* lmtp_sasl_get_user - username lookup call-back routine */
static int lmtp_sasl_get_user(void *context, int unused_id, const char **result,
@@ -298,6 +308,7 @@ void lmtp_sasl_initialize(void)
*/
static sasl_callback_t callbacks[] = {
{SASL_CB_LOG, &lmtp_sasl_log, 0},
+ {SASL_CB_GETPATH,&lmtp_sasl_getpath, 0},
{SASL_CB_LIST_END, 0, 0}
};
diff -upk.orig postfix-2.2.4.orig/src/smtp/smtp_sasl_glue.c postfix-2.2.4/src/smtp/smtp_sasl_glue.c
--- postfix-2.2.4.orig/src/smtp/smtp_sasl_glue.c 2005-04-13 14:09:53 +0000
+++ postfix-2.2.4/src/smtp/smtp_sasl_glue.c 2005-06-23 12:21:56 +0000
@@ -217,6 +217,16 @@ static int smtp_sasl_log(void *unused_co
return (SASL_OK);
}
+static int smtp_sasl_getpath(void * context, char ** path)
+{
+#if SASL_VERSION_MAJOR >= 2
+ *path = strdup("/etc/postfix/sasl:/usr/lib/sasl2");
+#else
+ *path = strdup("/etc/postfix/sasl:/usr/lib/sasl");
+#endif
+ return SASL_OK;
+}
+
/* smtp_sasl_get_user - username lookup call-back routine */
static int smtp_sasl_get_user(void *context, int unused_id, const char **result,
@@ -327,6 +337,7 @@ void smtp_sasl_initialize(void)
*/
static sasl_callback_t callbacks[] = {
{SASL_CB_LOG, &smtp_sasl_log, 0},
+ {SASL_CB_GETPATH,&smtp_sasl_getpath, 0},
{SASL_CB_LIST_END, 0, 0}
};
diff -upk.orig postfix-2.2.4.orig/src/smtpd/smtpd_sasl_glue.c postfix-2.2.4/src/smtpd/smtpd_sasl_glue.c
--- postfix-2.2.4.orig/src/smtpd/smtpd_sasl_glue.c 2005-04-13 14:09:59 +0000
+++ postfix-2.2.4/src/smtpd/smtpd_sasl_glue.c 2005-06-23 12:21:56 +0000
@@ -182,6 +182,16 @@ static int smtpd_sasl_log(void *unused_c
return SASL_OK;
}
+static int smtpd_sasl_getpath(void * context, char ** path)
+{
+#if SASL_VERSION_MAJOR >= 2
+ *path = strdup("/etc/postfix/sasl:/usr/lib/sasl2");
+#else
+ *path = strdup("/etc/postfix/sasl:/usr/lib/sasl");
+#endif
+ return SASL_OK;
+}
+
/*
* SASL callback interface structure. These call-backs have no per-session
* context.
@@ -190,6 +200,7 @@ static int smtpd_sasl_log(void *unused_c
static sasl_callback_t callbacks[] = {
{SASL_CB_LOG, &smtpd_sasl_log, NO_CALLBACK_CONTEXT},
+ {SASL_CB_GETPATH,&smtpd_sasl_getpath, NO_CALLBACK_CONTEXT},
{SASL_CB_LIST_END, 0, 0}
};