From: Francesco Chemolli Date: Mon, 31 Aug 2015 15:59:52 +0000 (+0200) Subject: Remove Auth::Digest::PurgeCredentialsCache X-Git-Tag: SQUID_4_0_1~21^2~49 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=209fee34a1061c2a4d050101e6631f792e574cb9;p=thirdparty%2Fsquid.git Remove Auth::Digest::PurgeCredentialsCache --- diff --git a/src/auth/digest/Scheme.cc b/src/auth/digest/Scheme.cc index c3cc69ef73..880710d498 100644 --- a/src/auth/digest/Scheme.cc +++ b/src/auth/digest/Scheme.cc @@ -37,7 +37,6 @@ Auth::Digest::Scheme::shutdownCleanup() if (_instance == NULL) return; - PurgeCredentialsCache(); authenticateDigestNonceShutdown(); _instance = NULL; @@ -50,22 +49,3 @@ Auth::Digest::Scheme::createConfig() Auth::Digest::Config *digestCfg = new Auth::Digest::Config; return dynamic_cast(digestCfg); } - -void -Auth::Digest::Scheme::PurgeCredentialsCache(void) -{ - AuthUserHashPointer *usernamehash; - - debugs(29, 2, HERE << "Erasing Digest authentication credentials from username cache."); - hash_first(proxy_auth_username_cache); - - while ((usernamehash = static_cast(hash_next(proxy_auth_username_cache)) )) { - Auth::User::Pointer auth_user = usernamehash->user(); - - if (strcmp(auth_user->config->type(), "digest") == 0) { - hash_remove_link(proxy_auth_username_cache, static_cast(usernamehash)); - delete usernamehash; - } - } -} - diff --git a/src/auth/digest/Scheme.h b/src/auth/digest/Scheme.h index f7c9937549..713236a3ed 100644 --- a/src/auth/digest/Scheme.h +++ b/src/auth/digest/Scheme.h @@ -38,12 +38,6 @@ public: private: static Auth::Scheme::Pointer _instance; - /** - * Remove all cached user credentials from circulation. - * Intended for use during shutdown procedure. - * After calling this all newly received credentials must be re-authenticated. - */ - static void PurgeCredentialsCache(void); }; } // namespace Digest