]> git.ipfire.org Git - thirdparty/postfix.git/commitdiff
postfix-2.6-20080116
authorWietse Venema <wietse@porcupine.org>
Wed, 16 Jan 2008 05:00:00 +0000 (00:00 -0500)
committerViktor Dukhovni <viktor@dukhovni.org>
Tue, 5 Feb 2013 06:33:53 +0000 (06:33 +0000)
postfix/HISTORY
postfix/RELEASE_NOTES-2.5
postfix/WISHLIST
postfix/src/global/mail_version.h
postfix/src/smtp/smtp_sasl_auth_cache.c
postfix/src/smtp/smtp_sasl_auth_cache.h

index e0a09f1c85714ff02791b2a80890129c710b2d25..29af59cdd00cd943541dd75437b9e50416f2d748 100644 (file)
@@ -14265,3 +14265,8 @@ Apologies for any names omitted.
        The text is automatically generated from bits and pieces of
        information that are scattered across other documents.
        File: mantools/make_soho_readme.
+
+20080116
+
+       Bugfix (introduced 20080112): missing #ifdef for the SASL
+       login failure cache. File: smtp/smtp_sasl_auth_cache.h.
index 3f487f3e6be8635ba6b0250a5b32d4968f44edf9..a8730c4b440cb3d37a7027310ae070a65186631d 100644 (file)
@@ -12,7 +12,7 @@ The mail_release_date configuration parameter (format: yyyymmdd)
 specifies the release date of a stable release or snapshot release.
 
 Incompatibility with Postfix 2.3 and earlier
-============================================
+--------------------------------------------
 
 If you upgrade from Postfix 2.3 or earlier, read RELEASE_NOTES-2.4
 before proceeding.
@@ -200,16 +200,16 @@ New configuration parameters: destination_concurrency_feedback_debug,
 default_destination_concurrency_positive_feedback,
 default_destination_concurrency_negative_feedback,
 default_destination_concurrency_failed_cohort_limit, as well as
-transport-specific versions of the same.  See postconf(5) for
-extensive descriptions, and SCHEDULER_README for background information
-on the theory and practice of how these settings work.
+transport-specific versions of the same.
 
 The default parameter settings are backwards compatible with older
 Postfix versions. This may change after better defaults are field
 tested.
 
-The SCHEDULER_README document describes the new concurrency scheduler,
-as well as Patrik Rak's preemptive job scheduler.
+The updated SCHEDULER_README document describes the theory behind
+the new concurrency scheduler, as well as Patrik Rak's preemptive
+job scheduler. See postconf(5) for more extensive descriptions of
+the configuration parameters.
 
 Major changes - small/home office
 ---------------------------------
index 51524c8906a99e9f42bef48f23d4cf5e0d52c837..7cafb5ccd9f70902b1471ef76f421a19643e0f1c 100644 (file)
@@ -1,8 +1,8 @@
 Wish list:
 
-       Collect random bits and pieces in one SOHO_README document:
-       smtp_generic_maps, sender_dependent_mumble,
-       smtp_sasl_auth_cache_name/time.
+       Write delivery rate delay example (which _README?) and auth
+       failure cache example (SASL_README). Then include them in
+       SOHO_README.
 
        See if "pickup =o content_filter=smtp:127.0.0.1" can be
        made a viable alternative to the use of non_smtpd_milters.
index b37fbabc00160c3497b159f7089d7bbf5ef99245..06bbd42000b61a6e46d0ea6666fcffd271404a3d 100644 (file)
@@ -20,7 +20,7 @@
   * Patches change both the patchlevel and the release date. Snapshots have no
   * patchlevel; they change the release date only.
   */
-#define MAIL_RELEASE_DATE      "20080115"
+#define MAIL_RELEASE_DATE      "20080116"
 #define MAIL_VERSION_NUMBER    "2.6"
 
 #ifdef SNAPSHOT
index 33f308f1e659990294550ed728aca7cd01b595cd..9920850a1d484dfb76e99696cad06a7611ec3278 100644 (file)
@@ -141,8 +141,8 @@ SMTP_SASL_AUTH_CACHE *smtp_sasl_auth_cache_init(const char *map, int ttl)
     auth_cache = (SMTP_SASL_AUTH_CACHE *) mymalloc(sizeof(*auth_cache));
     auth_cache->dict = dict_open(map, O_CREAT | O_RDWR, CACHE_DICT_OPEN_FLAGS);
     auth_cache->ttl = ttl;
-    auth_cache->dsn = mymalloc(100);
-    auth_cache->text = mymalloc(100);
+    auth_cache->dsn = mystrdup("");
+    auth_cache->text = mystrdup("");
     return (auth_cache);
 }
 
@@ -154,9 +154,9 @@ SMTP_SASL_AUTH_CACHE *smtp_sasl_auth_cache_init(const char *map, int ttl)
   * password has changed.
   */
 
-/* smtp_sasl_make_auth_cache_key - format auth failure cache lookup key */
+/* smtp_sasl_auth_cache_make_key - format auth failure cache lookup key */
 
-static char *smtp_sasl_make_auth_cache_key(const char *host, const char *user)
+static char *smtp_sasl_auth_cache_make_key(const char *host, const char *user)
 {
     VSTRING *buf = vstring_alloc(100);
 
@@ -164,9 +164,9 @@ static char *smtp_sasl_make_auth_cache_key(const char *host, const char *user)
     return (vstring_export(buf));
 }
 
-/* smtp_sasl_make_auth_cache_pass - hash the auth failure cache password */
+/* smtp_sasl_auth_cache_make_pass - hash the auth failure cache password */
 
-static char *smtp_sasl_make_auth_cache_pass(const char *password)
+static char *smtp_sasl_auth_cache_make_pass(const char *password)
 {
     VSTRING *buf = vstring_alloc(2 * SHA_DIGEST_LENGTH);
 
@@ -176,9 +176,9 @@ static char *smtp_sasl_make_auth_cache_pass(const char *password)
     return (vstring_export(buf));
 }
 
-/* smtp_sasl_make_auth_cache_value - format auth failure cache value */
+/* smtp_sasl_auth_cache_make_value - format auth failure cache value */
 
-static char *smtp_sasl_make_auth_cache_value(const char *password,
+static char *smtp_sasl_auth_cache_make_value(const char *password,
                                                     const char *dsn,
                                                     const char *rep_str)
 {
@@ -186,7 +186,7 @@ static char *smtp_sasl_make_auth_cache_value(const char *password,
     char   *pwd_hash;
     unsigned long now = (unsigned long) time((time_t *) 0);
 
-    pwd_hash = smtp_sasl_make_auth_cache_pass(password);
+    pwd_hash = smtp_sasl_auth_cache_make_pass(password);
     vstring_sprintf(val_buf, "%lu;%s;%s;%s", now, pwd_hash, dsn, rep_str);
     myfree(pwd_hash);
     return (vstring_export(val_buf));
@@ -216,7 +216,7 @@ static int smtp_sasl_auth_cache_valid(SMTP_SASL_AUTH_CACHE *auth_cache,
     } else if (time_stamp + auth_cache->ttl < now) {
        valid = 0;
     } else {
-       curr_hash = smtp_sasl_make_auth_cache_pass(password);
+       curr_hash = smtp_sasl_auth_cache_make_pass(password);
        valid = (strcmp(cache_hash, curr_hash) == 0);
        myfree(curr_hash);
     }
@@ -233,7 +233,7 @@ int     smtp_sasl_auth_cache_find(SMTP_SASL_AUTH_CACHE *auth_cache,
     const char *entry;
     int     valid = 0;
 
-    key = smtp_sasl_make_auth_cache_key(session->host, session->sasl_username);
+    key = smtp_sasl_auth_cache_make_key(session->host, session->sasl_username);
     if ((entry = dict_get(auth_cache->dict, key)) != 0)
        if ((valid = smtp_sasl_auth_cache_valid(auth_cache, entry,
                                                session->sasl_passwd)) == 0)
@@ -254,8 +254,8 @@ void    smtp_sasl_auth_cache_store(SMTP_SASL_AUTH_CACHE *auth_cache,
     char   *key;
     char   *value;
 
-    key = smtp_sasl_make_auth_cache_key(session->host, session->sasl_username);
-    value = smtp_sasl_make_auth_cache_value(session->sasl_passwd,
+    key = smtp_sasl_auth_cache_make_key(session->host, session->sasl_username);
+    value = smtp_sasl_auth_cache_make_value(session->sasl_passwd,
                                            resp->dsn, resp->str);
     dict_put(auth_cache->dict, key, value);
 
index 71271a21ea2e0cb605bf6a1da3a01812381cfc47..cbbdb0d533deac253f86d8b3bf34bd55da068b36 100644 (file)
@@ -20,7 +20,7 @@
  /*
   * This code stores hashed passwords which requires OpenSSL.
   */
-#ifdef USE_TLS
+#if defined(USE_TLS) && defined(USE_SASL_AUTH)
 #define HAVE_SASL_AUTH_CACHE
 
  /*