Java MD5 newMd5MessageDigest()

Here you can find the source of newMd5MessageDigest()

Description

new Md Message Digest

License

Open Source License

Declaration

@Deprecated
    private static MessageDigest newMd5MessageDigest() 

Method Source Code

//package com.java2s;
/*// w w  w  .j a  va2s . com
 *   $Id$
 *
 *   Copyright 2006 University of Dundee. All rights reserved.
 *   Use is subject to license terms supplied in LICENSE.txt
 */

import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;

public class Main {
    @Deprecated
    private static MessageDigest newMd5MessageDigest() {
        MessageDigest md;

        try {
            md = MessageDigest.getInstance("MD5");
        } catch (NoSuchAlgorithmException e) {
            throw new RuntimeException("Required MD5 message digest algorithm unavailable.");
        }

        md.reset();
        return md;
    }
}

Related

  1. md5ToHex(byte[] hash)
  2. md5ToString(byte[] md5sum)
  3. md5Update(byte[] inbuf, int inputLen)
  4. newMd5()
  5. newMD5HashUri(String value)
  6. validateMD5(String md5String)