]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Final changes to track TLS credentials (STR #1616)
authormsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Fri, 18 Jul 2014 14:26:14 +0000 (14:26 +0000)
committermsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Fri, 18 Jul 2014 14:26:14 +0000 (14:26 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@12048 a1ca3aef-8c08-0410-bb20-df032aa958be

CHANGES.txt
backend/ipp.c

index 8222b9bafbfbbaf146226d9762040e7582b7fd50..577c6c776e10168c9f195ac3c966002bbdbc5415 100644 (file)
@@ -11,6 +11,8 @@ CHANGES IN CUPS V2.0b1
        - Dropped support for AIX, HP-UX, and OSF/1 (aka Digital UNIX)
        - Dropped lppasswd and support for Digest authentication in in the
          scheduler (STR #4321)
+       - CUPS TLS support now supports certificate validation and policy
+         enforcement (STR #1616)
        - The configure script now supports target-specific tools for pkg-config
          and others (STR #4423)
        - The ipptool program now supports EXPECT statements for collection
index 60f4df25e1da084a61d89db464a37c0d34bf8832..dc1a18289f89266985d7e76e2f6f3cefaac9d9ee 100644 (file)
@@ -689,6 +689,7 @@ main(int  argc,                             /* I - Number of command-line args */
     */
 
     cups_array_t       *creds;         /* TLS credentials */
+    cups_array_t       *lcreds = NULL; /* Loaded credentials */
     http_trust_t       trust;          /* Trust level */
     static const char  *trusts[] = { NULL, "+cups-pki-invalid", "+cups-pki-changed", "+cups-pki-expired", NULL, "+cups-pki-unknown" };
                                        /* Trust keywords */
@@ -704,6 +705,17 @@ main(int  argc,                            /* I - Number of command-line args */
         return (CUPS_BACKEND_STOP);
       }
 
+      if (httpLoadCredentials(NULL, &lcreds, hostname))
+      {
+       /*
+        * Could not load the credentials, let's save the ones we have so we
+        * can detect changes...
+        */
+
+        httpSaveCredentials(NULL, creds, hostname);
+      }
+
+      httpFreeCredentials(lcreds);
       httpFreeCredentials(creds);
     }
   }