Author: markt
Date: Mon Sep 14 12:39:23 2015
New Revision: 1702927

URL: http://svn.apache.org/r1702927
Log:
Remove deprecated code

Modified:
    tomcat/trunk/java/org/apache/catalina/realm/RealmBase.java

Modified: tomcat/trunk/java/org/apache/catalina/realm/RealmBase.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/realm/RealmBase.java?rev=1702927&r1=1702926&r2=1702927&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/realm/RealmBase.java (original)
+++ tomcat/trunk/java/org/apache/catalina/realm/RealmBase.java Mon Sep 14 
12:39:23 2015
@@ -1108,44 +1108,6 @@ public abstract class RealmBase extends
 
     // ------------------------------------------------------ Protected Methods
 
-
-    /**
-     * Digest the password using the specified algorithm and
-     * convert the result to a corresponding hexadecimal string.
-     * If exception, the plain credentials string is returned.
-     *
-     * @param credentials Password or other credentials to use in
-     *  authenticating this username
-     *
-     * @deprecated Used. Will be removed in Tomcat 9.
-     */
-    @Deprecated
-    protected String digest(String credentials)  {
-
-        // If no MessageDigest instance is specified, return unchanged
-        if (hasMessageDigest() == false)
-            return (credentials);
-
-        // Digest the user credentials and return as hexadecimal
-        synchronized (this) {
-            try {
-                byte[] bytes = null;
-                try {
-                    bytes = credentials.getBytes(getDigestCharset());
-                } catch (UnsupportedEncodingException uee) {
-                    log.error("Illegal digestEncoding: " + 
getDigestEncoding(), uee);
-                    throw new IllegalArgumentException(uee.getMessage());
-                }
-
-                return 
(HexUtils.toHexString(ConcurrentMessageDigest.digest(getDigest(), bytes)));
-            } catch (Exception e) {
-                log.error(sm.getString("realmBase.digest"), e);
-                return (credentials);
-            }
-        }
-
-    }
-
     protected boolean hasMessageDigest() {
         return getDigest() != null;
     }



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to