]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
SourceLayout: Shuffle InitAuthSchemes() to Auth::Init()
authorAmos Jeffries <squid3@treenet.co.nz>
Mon, 11 Apr 2011 03:25:32 +0000 (21:25 -0600)
committerAmos Jeffries <squid3@treenet.co.nz>
Mon, 11 Apr 2011 03:25:32 +0000 (21:25 -0600)
No logic changes.

src/AuthReg.cc
src/cache_cf.cc
src/main.cc
src/protos.h

index d47b34cb70b5f23ccc5a29960f7e876b3d006f38..a08726129d6c7ebfb86e11c32e44cc3d84ba5296 100644 (file)
@@ -2,9 +2,6 @@
 
 #if USE_AUTH
 
-#include "Debug.h"
-#include "protos.h"
-
 #if HAVE_AUTH_MODULE_BASIC
 #include "auth/basic/Scheme.h"
 #endif
 #include "auth/ntlm/Scheme.h"
 #endif
 
+#include "Debug.h"
+#include "protos.h"
+
 /**
  * Initialize the authentication modules (if any)
  * This is required once, before any configuration actions are taken.
  */
 void
-InitAuthSchemes()
+Auth::Init()
 {
-    debugs(29,1,"Initializing Authentication Schemes ...");
+    debugs(29,DBG_IMPORTANT,"Startup: Initializing Authentication Schemes ...");
 #if HAVE_AUTH_MODULE_BASIC
     static const char *basic_type = Auth::Basic::Scheme::GetInstance()->type();
-    debugs(29,1,"Initialized Authentication Scheme '" << basic_type << "'");
+    debugs(29,DBG_IMPORTANT,"Startup: Initialized Authentication Scheme '" << basic_type << "'");
 #endif
 #if HAVE_AUTH_MODULE_DIGEST
     static const char *digest_type = Auth::Digest::Scheme::GetInstance()->type();
-    debugs(29,1,"Initialized Authentication Scheme '" << digest_type << "'");
+    debugs(29,DBG_IMPORTANT,"Startup: Initialized Authentication Scheme '" << digest_type << "'");
 #endif
 #if HAVE_AUTH_MODULE_NEGOTIATE
     static const char *negotiate_type = Auth::Negotiate::Scheme::GetInstance()->type();
-    debugs(29,1,"Initialized Authentication Scheme '" << negotiate_type << "'");
+    debugs(29,DBG_IMPORTANT,"Startup: Initialized Authentication Scheme '" << negotiate_type << "'");
 #endif
 #if HAVE_AUTH_MODULE_NTLM
     static const char *ntlm_type = Auth::Ntlm::Scheme::GetInstance()->type();
-    debugs(29,1,"Initialized Authentication Scheme '" << ntlm_type << "'");
+    debugs(29,DBG_IMPORTANT,"Startup: Initialized Authentication Scheme '" << ntlm_type << "'");
 #endif
-    debugs(29,1,"Initializing Authentication Schemes Complete.");
+    debugs(29,DBG_IMPORTANT,"Startup: Initialized Authentication.");
 }
 
 #endif /* USE_AUTH */
index 201a768afcecc6338f2bf5aa96a20fc3beeac7be..10368edb020d47a53c77ac00e0b1b2b5293350e1 100644 (file)
@@ -1882,7 +1882,7 @@ free_authparam(Auth::ConfigVector * cfg)
 
     /* on reconfigure initialize new auth schemes for the new config. */
     if (reconfiguring) {
-        InitAuthSchemes();
+        Auth::Init();
     }
 }
 
index 8966c83e5b191cc5a1a2b3c3a41789e54ef2d9c0..67e110fee9b83d5967b636c39ea3d04dc35b7e25 100644 (file)
@@ -1368,7 +1368,7 @@ SquidMain(int argc, char **argv)
         /* we may want the parsing process to set this up in the future */
         Store::Root(new StoreController);
 #if USE_AUTH
-        InitAuthSchemes();      /* required for config parsing */
+        Auth::Init();      /* required for config parsing */
 #endif
         Ip::ProbeTransport(); // determine IPv4 or IPv6 capabilities before parsing.
 
index bac9cfca70de7b9a72e9070a60b013b384fc4f1e..8735f6cd43282f191da85ba4757a4b627fcaf3c4 100644 (file)
@@ -804,8 +804,12 @@ class external_acl;
             SQUIDCEXTERN char *peer_proxy_negotiate_auth(char *principal_name, char *proxy);
 #endif
 
-            /* call to ensure the auth component schemes exist. */
-            SQUIDCEXTERN void InitAuthSchemes(void);
+namespace Auth
+{
+/* call to ensure the auth component schemes exist. */
+extern void Init(void);
+} // namespace Auth
+
 #endif /* USE_AUTH */
 
 #endif /* SQUID_PROTOS_H */