JPasswordField and MD5 hashes

I have two methods to make an MD5 String from an entered password in a JPasswordField. Which one is better for security? Can anyone recommend any changes?
* Create MD5 of password field
* @param JPasswordField - location of the password
* @return String - an MD5 hash of the field text
private String getMD5(javax.swing.JPasswordField field) {
    java.security.MessageDigest md;
    String passwdString = "";
    char[] passwdChars = field.getPassword();
    int i;
    field.setText("");
    // char[] to string and blank out chars
    for (i = 0; i < passwdChars.length; i++) {
        passwdString += passwdChars;
passwdChars[i] = 0; // blank after for security
try {
md = java.security.MessageDigest.getInstance("MD5");
} catch (java.security.NoSuchAlgorithmException e) {
return null;
byte[] passwdMD5 = md.digest(passwdString.getBytes());
passwdString = "xxxxxxxxxxxxxxxxxxxxxxxxx"; // security
return dumpBytes(passwdMD5);
* Create MD5 of password field
* @param JPasswordField - location of the password
* @return String - an MD5 hash of the field text
private String getMD5a(javax.swing.JPasswordField field) {
java.security.MessageDigest md;
String MD5;
try {
md = java.security.MessageDigest.getInstance("MD5");
} catch (java.security.NoSuchAlgorithmException e) {
return null;
MD5 = dumpBytes(md.digest(new String(field.getPassword()).getBytes()));
field.setText("");
return MD5;
* Byte[] to String conversion
* @param byte[]
* @return String
private static String dumpBytes(byte[] bytes) {
int i;
StringBuffer sb = new StringBuffer();
for (i=0; i<bytes.length; i++) {
if (i%32 == 0 && i!=0) {
sb.append("\n");
String s = Integer.toHexString(bytes[i]);
if (s.length() < 2) {
s = "0"+s;
if (s.length() > 2) {
s = s.substring(s.length()-2);
sb.append(s);
return sb.toString();

Thanks for the replies.
Unfortunately I can't get the charsToBytes function to work. For example, if you run the following code you can see that it doesn't seem to give me the correct md5 (if you to to http://pajhome.org.uk/crypt/md5/ and calculate the MD5 for 'test' you will see that function getMD5a works but not getMD5b):
public class test {
    public static void main(String args[]) {
        new test();
    public test() {
        char[] chars = {'t','e','s','t'};
        System.out.println("Method a: "+getMD5a(chars));
        System.out.println("Method b: "+getMD5b(chars));
    private String getMD5a(char[] passwd) {
        java.security.MessageDigest md;
        String MD5;
        try {
            md = java.security.MessageDigest.getInstance("MD5");
        } catch (java.security.NoSuchAlgorithmException e) {
            return null;
        MD5 = dumpBytes(md.digest(new String(passwd).getBytes()));
        return MD5;
    private String getMD5b(char[] passwd) {
        java.security.MessageDigest md;
        String MD5;
        try {
            md = java.security.MessageDigest.getInstance("MD5");
        } catch (java.security.NoSuchAlgorithmException e) {
            return null;
        MD5 = dumpBytes(md.digest(charsToBytes(passwd)));
        return MD5;
    public static byte[] charsToBytes(char[] chars) {
        byte[] bytes = new byte[chars.length*2];
        int b,c;
        for (b = 0, c = 0; c < chars.length; c++, b+=2) {
            bytes[b] = (byte)((chars[c] >> 8) & 0xFF);
            bytes[b+1] = (byte)(chars[c] & 0xFF);
        return bytes;
    public static String dumpBytes(byte[] bytes) {
        int i;
        StringBuffer sb = new StringBuffer();
        for (i=0; i<bytes.length; i++) {
            if (i%32 == 0 && i!=0) {
                sb.append("\n");
            String s = Integer.toHexString(bytes);
if (s.length() < 2) {
s = "0"+s;
if (s.length() > 2) {
s = s.substring(s.length()-2);
sb.append(s);
return sb.toString();

Similar Messages

  • Request Native Ability to Calculate CRC, MD5, and SHA Hashes

    // Requested via the Feedback tool also //
    Provide the ability to calculate and generate CRC, MD5, and SHA hashes via a right-click context menu without having to resort to third party tools.  In some environments, policy does not allow for certain applications.  Having this ability natively
    would really help to verify files.
    This has been requested during the preview stage of Windows 7 and Windows 8.  Asking again here.

    That works perfectly!  Thanks.  I did not know that was available.
    NAME
        Get-FileHash
    SYNTAX
        Get-FileHash [-Path] <string[]> [-Algorithm <string> {SHA1 | SHA256 | SHA384 | SHA512 | MACTripleDES | MD5 |
        RIPEMD160}]  [<CommonParameters>]
        Get-FileHash -LiteralPath <string[]> [-Algorithm <string> {SHA1 | SHA256 | SHA384 | SHA512 | MACTripleDES | MD5 |
        RIPEMD160}]  [<CommonParameters>]
        Get-FileHash -InputStream <Stream> [-Algorithm <string> {SHA1 | SHA256 | SHA384 | SHA512 | MACTripleDES | MD5 |
        RIPEMD160}]  [<CommonParameters>]
    ALIASES
        None
    REMARKS
        Get-Help cannot find the Help files for this cmdlet on this computer. It is displaying only partial help.
            -- To download and install Help files for the module that includes this cmdlet, use Update-Help.

  • The selected signed file could not be authenticated. The file might have been tampered with or an error might have occured during download. Please verify the MD5 hash value against the Cisco Systems web site

    I am trying to load any 9.0.3 firmware on my UCM 5.0.4.2000-1 server. Every newer firmware I load throws the following error. I have verified the MD5 is correct and also downloaded the file several times with the same result. I can load the same firmware file on another UCM server and it loads fine. Any ideas?
    Thanks in advance!
    Error Message:
    The selected signed file could not be authenticated. The file might have been  tampered with or an error might have occured during download. Please verify the  MD5 hash value against the Cisco Systems web site:  9b:b6:31:09:18:15:e7:c0:97:9f:e6:fe:9a:19:94:99
    Firmware File: cmterm-7970_7971-sccp.9-0-3.cop.sgn
    UCM version: 5.0.4.2000-1

    Thanks for your reply. We have a lab environment where I maintain  UCM 5.0, 5.1, 6.0, 6.1, 7.0, 7.1 and 8.0 servers each running the latest released firmware for our QA testing team. I have downloaded and installed the latest device packages but find that if I try to install any firmware newer then 8.3.1 on either 5.0.4 or 6.0 i start getting MD5 hash authentication errors. It looks like 9.0.3 firmware should work on UCM 5.0 and 6.0 so I am lost as to why I can't seem to update any firmware for any model phone if it is newer then version 8.3.1 on either 5.0 or 6.0. while 5.1 and 6.1 work without issues. Maybe it is just a bug. I mostly wanted to see if anyone else has experienced this or if it is just me.

  • Cisco ISE NTP MD5 hash is 20-Bytes?

    When attempting to configure an NTP authentication-key in the Cisco ISE CLI I noticed that it will not accept an md5 hash of 32 characters (16 bytes). Instead it is expecting a 40 character (20 bytes) hash. That is in line with a SHA-1 hash, not an MD5 hash even though there is no SHA-1 keyword, only an MD5 keyword.
    What's the deal?
    Cisco ISE Version: 1.1.2.145 (Update 3)
    ise/user(config)# ntp authentication-key 75 ?
      md5  MD5 authentication
    ise/user(config)# ntp authentication-key 75 md5 hash ?
      <WORD>  Hashed key for authentication (Max Size - 40)
    ise/user(config)# ntp authentication-key 75 md5 hash 12345678901234567890123456789012
    % ERROR: Bad hashed key.
    ise/user(config)# ntp authentication-key 75 md5 plain test
    ise/user(config)# do show run | i md5
    ntp authentication-key 75 md5 hash 97dc37c94236ec1b4c56871c2e482cbd6f56bd33
    That's not an MD5 hash as it's 40 characters long (20 bytes).

    Hmm, that is an interesting observation. I am guessing that it is a typo and should be "sha-1" because 40 characters is definitely not MD5 :)
    I would suggest you open a case with Cisco TAC and report this. If you get a bug ID or a different answer please let us know. 
    Thank you for rating helpful posts!

  • AAA and MD5 Configuration on SIP Calls

    Olease can anyone help in AAA and MD5 configuration on Cisco 3640 running SIP. My carrier told me that the only way that my calls can be Authenticated is thru AAAor MD5, eg -
    Host:
    Authentication ID:
    Secret:
    Please I need your help thank you in advance.
    Knmezi

    MD5 authentication works similarly to plain text authentication, except that the key is never sent over the wire. Instead, the router uses the MD5 algorithm to produce a "message digest" of the key (also called a "hash"). The message digest is then sent instead of the key itself. This ensures that nobody can eavesdrop on the line and learn keys during transmission.
    These protocols use MD5 authentication:
    OSPF
    RIP version 2
    BGP
    IP Enhanced IGRP
    For AAA configuration refer to following url;
    http://www.cisco.com/en/US/products/sw/secursw/ps2138/products_configuration_example09186a008017ee15.shtml

  • DBMS_CRYPTO MD5 hash value does not match 3rd party MD5 free tool

    Hello,
    I am using Oracle Version: 11.2.4.
    I have a problem where the MD5 value from DBMS_CRYPTO does not match the hash value from 3rd party MD5 free tool (MD5 Checksum Calculator 0.0.5.58 or WinMD5Free v1.20) and also the MD5 hash value calculated by an ingestion tool where I am transferring files to. The MD5 hash value that the ingestion tool calculates is the same as the 3rd party MD5 free tools I have. This occurs only on some of the XML files that I generate using XSQL(xmlserialize, xmlagg, xmlelement, etc.) and DBMS_XSLPROCESSOR on a Linux OS. The XML files are transferred from the Unix OS to my Windows 7 OS via filezilla.
    I found a thread on this forum that also had a similar issue so I copy/paste the java functions. They are listed below(both are the same expect for the character set):
    create or replace java source named "MD5_UTF_8" as
    import java.security.MessageDigest;
    import java.security.NoSuchAlgorithmException;
    import java.sql.Clob;
    import java.sql.Blob;
    public class MD5_UTF_8 {
    private static final byte [] hexDigit = {
    '0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F'
    /** Converts a byte array to a hex string
    * Returns an empty string if the byte array is null
    public static final String toHexString(byte [] bytes) {
    if (bytes == null) return new String("");
    StringBuffer buf = new StringBuffer(bytes.length * 2);
    for (int i = 0; i < bytes.length; i++) {
    buf.append((char) hexDigit[((bytes >>> 4) & 0x0F)]);
    buf.append((char) hexDigit[(bytes & 0x0F)]);
    return buf.toString();
    // Convert Hex String to Byte Array
    public static final byte[] byteArrayFromHexString(String str) {
    byte[] bytes = new byte[str.length() / 2];
    for (int i = 0; i < bytes.length; i++)
    bytes = (byte) Integer.parseInt(str.substring(2 * i, 2 * i + 2), 16);
    return bytes;
    public static String getMD5HashFromClob(Clob inhalt) throws Exception{
    MessageDigest algorithm;
    StringBuffer hexString;
    String s = null;
    String salida = null;
    int i;
    byte[] digest;
    String tepFordigest = inhalt.getSubString(1L, (int)inhalt.length());
    try {
    algorithm = MessageDigest.getInstance("MD5_UTF_8");
    algorithm.reset();
    algorithm.update(tepFordigest.getBytes("UTF-8"));
    digest = algorithm.digest();
    s = toHexString(digest);
    } catch (java.security.NoSuchAlgorithmException nsae) {
    s = "No es posible cifrar MD5";
    return s;
    sho err
    alter java source "MD5_UTF_8" compile
    sho err
    CREATE OR REPLACE FUNCTION get_md5_UTF_8_CLOB(inhalt CLOB) RETURN VARCHAR2 DETERMINISTIC
    AS LANGUAGE JAVA
    name 'MD5_UTF_8.getMD5HashFromClob(java.sql.Clob) return java.lang.String';
    create or replace java source named "MD5" as
    import java.security.MessageDigest;
    import java.security.NoSuchAlgorithmException;
    import java.sql.Clob;
    import java.sql.Blob;
    public class MD5 {
    private static final byte [] hexDigit = {
    '0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F'
    /** Converts a byte array to a hex string
    * Returns an empty string if the byte array is null
    public static final String toHexString(byte [] bytes) {
    if (bytes == null) return new String("");
    StringBuffer buf = new StringBuffer(bytes.length * 2);
    for (int i = 0; i < bytes.length; i++) {
    buf.append((char) hexDigit[((bytes >>> 4) & 0x0F)]);
    buf.append((char) hexDigit[(bytes & 0x0F)]);
    return buf.toString();
    // Convert Hex String to Byte Array
    public static final byte[] byteArrayFromHexString(String str) {
    byte[] bytes = new byte[str.length() / 2];
    for (int i = 0; i < bytes.length; i++)
    bytes = (byte) Integer.parseInt(str.substring(2 * i, 2 * i + 2), 16);
    return bytes;
    public static String getMD5HashFromClob(Clob inhalt) throws Exception{
    MessageDigest algorithm;
    StringBuffer hexString;
    String s = null;
    String salida = null;
    int i;
    byte[] digest;
    String tepFordigest = inhalt.getSubString(1L, (int)inhalt.length());
    try {
    algorithm = MessageDigest.getInstance("MD5");
    algorithm.reset();
    algorithm.update(tepFordigest.getBytes());
    digest = algorithm.digest();
    s = toHexString(digest);
    } catch (java.security.NoSuchAlgorithmException nsae) {
    s = "No es posible cifrar MD5";
    return s;
    sho err
    alter java source "MD5" compile
    sho err
    CREATE OR REPLACE FUNCTION get_md5_CLOB(inhalt CLOB) RETURN VARCHAR2 DETERMINISTIC
    AS LANGUAGE JAVA
    name 'MD5.getMD5HashFromClob(java.sql.Clob) return java.lang.String';
    I created the above java functions and added the calls to them in my package to see what hash values they would produce but I am getting "ORA-29532: Java call terminated by uncaught Java exception: java.nio.BufferOverflowException " the XML is about 60mb.
    package code sniippets:
    declare
    l_hash raw(2000);
    l_checksum_md5 varchar2(2000);
    l_checksum_md5_utf_8 varchar2(2000);
    Begin
    t_checksum := lower(RAWTOHEX(dbms_crypto.hash(src=>l_clob,typ=>dbms_crypto.hash_md5)));
    l_hash := get_md5_CLOB (l_clob);
    l_checksum_md5 := lower(rawtohex(l_hash));
    l_hash := get_md5_UTF_8_CLOB (l_clob);
    l_checksum_md5_UTF_8 := lower(rawtohex(l_hash));Please help,
    Thank You in advance
    Don
    Edited by: 972551 on Nov 21, 2012 12:18 PM
    Edited by: sabre150 on Nov 21, 2012 11:06 PM
    Moderator action : added [code ] tags to format properly. In future please add them yourself.

    >
    I have a problem where the MD5 value from DBMS_CRYPTO does not match the hash value from 3rd party MD5 free tool (MD5 Checksum Calculator 0.0.5.58 or WinMD5Free v1.20) and also the MD5 hash value calculated by an ingestion tool where I am transferring files to. The MD5 hash value that the ingestion tool calculates is the same as the 3rd party MD5 free tools I have.
    I found a thread on this forum that also had a similar issue so I copy/paste the java functions.
    >
    And in that thread (Re: MD5 HASH computed from DBMS_CRYPTO does not match .NET MD5 I provided the reason why DBMS_CRYPTO may not match hashes produced by other methodologies.
    I have no idea why you copied and posted all of that Java code the other poster and I provided since code has NOTHING to do with the problem you say you are having. Thte other poster's question was how to write Java code that would produce the same result as DBMS_CRYPTO.
    You said your problem was understanding why DBMS_CRYPTO 'does not match the hash value from 3rd party MD5 free tool ...'. and I answered that in the other forum.
    >
    The Crypto package always converts everything to AL32UTF8 before hashing so if the .NET character set is different the hash will likely be different.
    See DBMS_CRYPTO in the PL/SQL Packages and Types doc
    http://docs.oracle.com/cd/B28359_01/appdev.111/b28419/d_crypto.htm
    If you look at the spec header for the DBMS_CRYPTO package it shows this note:
    -- Prior to encryption, hashing or keyed hashing, CLOB datatype is
    -- converted to AL32UTF8. This allows cryptographic data to be
    -- transferred and understood between databases with different
    -- character sets, across character set changes and between
    -- separate processes (for example, Java programs).
    -- If your 3rd party MD5 free tool (MD5 Checksum Calculator 0.0.5.58 or WinMD5Free v1.20) do not use the AL32UTF8 character set then the hashes will likely be different. You can't modify DBMS_CRYPTO so if the hashes need to match you need to use 3rd party tools that either use the correct character set or can be configured to use the correct character set.
    The problem in the other thread was how to WRITE Java code that uses the correct character set and I showed that OP how to do that.
    So unless you are writing your own Java code all of that code you copied and pasted is useless for your use case.

  • Sha1 or MD5 hash

    Is there a SHa1 or Md5 hash check for Mountain lion like the other updated Aple provides?
    It seems Apple provides Sha1 hashes for its updates but not for a major operating system? Why?

    This is a question best asked of Apple directly; the "why" questions are often not something that non-Apple folks are in a position to answer.
    Of what's been posted and discussed about your question, "For updates delivered by Automatic Software Update, SHA-1 digest verification is performed automatically for you."  (HT1652)  
    For details on code signing used on more recent OS X releases, see the Code Signing Guide and review commands such as codesign --verify --deep-verify --verbose /applications/Install\ OS\ X\ Mountain\ Lion.app  and codesign --display -vvv  --entitlements - /applications/Install\ OS\ X\ Mountain\ Lion.app    Based on the output from those and related commands, the code-signing here is using SHA-1, and it traces back to Apple digital certificates.  
    AFAIK, the installation verifies the signatures, as it wouldn't be much value otherwise.
    US NSA and Apple security guides are among the available security-related documentation.   Apple's Gatekeeper (HT5290) might also be of some interest.
    Alternatively (and likely better), please call the Apple support center folks directly, as your requirements are clearly quite specialized, and it would appear your distribution path requirements may be equally specialized.
    FWIW, few folks are using MD5 anymore for anything more serious than detecting file transfer corruptions.

  • SOA 10g - Convert string to MD5 hash

    Hi Guys,
    Is there a way apart from using Java to convert a string to MD5 hash in soa bpel process ?
    Thanks
    K

    Sorted it out, used java embedding and it worked, example below of java embedding
    String md5=getVariableData("md5Var").toString(); //this is the variable that needs to be md5 hashed
    try{              
    MessageDigest md = MessageDigest.getInstance("MD5");
    byte[] myByteArray1 = md5.getBytes("UTF-8");
    byte[] myByteArray2 = md.digest(myByteArray1);
    BigInteger bigInt = new BigInteger( 1, myByteArray2);
    String javahashedstring = bigInt.toString(16);
    setVariableData("md5Var", javahashedstring, false); //return md5 hashed variable
    }catch (Exception ex){     
    ex.printStackTrace();
    }

  • Migrate users from qmail to sun messaging  (import MD5 hashed passwords)

    Hi,
    we are planning to migrate about 2000 users from our current mail system (qmail + openldap) to Sun Messaging 6.2.
    We have encountered a problem with user password migration. In our current ldap user passwords are MD5 encrypted, but it appears as Directory 5.2 does not support MD5 encryption method.
    This is what I have found :
    http://docs.sun.com/source/817-7616/config.html#wp26092
    The following encryption types are supported by Directory Server:
    * SSHA (Salted Secure Hash Algorithm) is the recommended method as it is the most secure.
    * SHA (Secure Hash Algorithm). This is the method supported by 4.x Directory Servers.
    * CRYPT is the UNIX crypt algorithm. It is provided for compatibility with UNIX passwords.
    * If this attribute is set to CLEAR, passwords are not encrypted and appear in plain text.
    We want to import MD5 hashed passwords so users can use their old password after we migrate to SUN, but as passwords are updated they will be SSHA hashed.
    We only have a problem with importing MD5 hashed passwords in ldap directory.
    Current password on openLDAP are created with the following PHP code:
    $info["userPassword"]= '{md5}' . base64_encode(pack('H*', md5($passwd)));
    I have tried to copy userpassword value from openldap to directory but the directory ignores {md5} and hashed the string again using SSHA.
    Example:
    cleartextpass: password
    md5_base64_hash={MD5}X03MO1qnZdYdgyfeuILPmQ==
    after ldap modify userpassword field loks like this:
    userpassword:{SSHA}a+dFsejrTGwQAgdU07kkgzWWOC16SiIW2UsPcQ==
    What is the correct procedure to import MD5 hashed passwords in Sun Directory?
    (NS-MTA-MD5 Password Storage Plug-In is enabled)

    Sun Directory 5.2 has a plugin NT-MTA-MD5 which should enable users to authenticate with MD5 hashed passwords.
    I have checked in cn=config and NS-MTA-MD5 plugin is enabled.
    I have tried with {NS-MTA-MD5} prefix and still directory does not allow users to authenticate.
    Example:
    cleartextpass: foo
    md5_base64_hash={NS-MTA-MD5}rL0Y20zC+Fzt72VPzMSk2A==
    after ldap modify userpassword field loks like this( NS-MTA-MD5 is accepted by directory):
    userpassword:{NS-MTA-MD5}rL0Y20zC+Fzt72VPzMSk2A==
    but
    ldap bind fails with "invalid credentials" error
    We are using solaris 10 so I tried using the prefix {crypt} and it did not work. You said something about the right config in /etc/security/crypt.conf. Here is the content of my crypt.conf file:
    1 crypt_bsdmd5.so.1
    2a crypt_bsdbf.so.1
    md5 crypt_sunmd5.so.1
    This should be the right config "md5 crypt_sunmd5.so.1"
    Am I missing something here?
    Is there anything else I need to do to enable directory to use MD5 hashed passwords?
    Maybe NS-MTA-MD5 plugin is not enough?

  • Generating MD5 hash value for any specific flat file

    Hi experts,
    I am developing a program that will generate flat files and also I should generate the MD5 Hash value for each and every flat files. My question is how can I generate the MD5 hash value for the generated .txt files.
    Thanks in advance
    Shabir

    You can use functions
    MD5_CALCULATE_HASH_FOR_CHAR for text file
    MD5_CALCULATE_HASH_FOR_RAW for binary

  • Berkeley DB MD5 Hash file

    Hi,
    I have a question regarding HASH file for Berkeley DB. How can I get the MD5 HASH file to make sure the tar file that I downloaded came from Oracle? Basically I am looking for how to validate that this software came from the Oracle site? Can you please help?
    Thank you.

    Hello,
    A while ago, maybe 4 years or so now, we used to build a MD5 file for every release download package. If you downloaded http://download.oracle.com/berkeley-db/db-5.0.21.tar.gz you could expect to find http://download.oracle.com/berkeley-db/db-5.0.21.tar.gz.md5 with the signature. I guess back then it wasn't all that common to do that and not many people downloaded the signature file. So, somewhere along the line we dropped that. I've considered re-starting that practice. Why? Well, lets just say that you're not the first to ask for it. :) Are you building something that automates the download of BDB code, then verifies the package? Just curious...
    thanks for the request/question,
    -greg
    Product Manager, Oracle Berkeley DB

  • MD5 Hashing

    Hi,
    We are using MessageDigest , from Java Security api, to hash certian critical parameters in our application. These parameters along with their name, value and hash values are sent to the client browser. This prevents the user to modify any data as we re calculate the hash based on the actual value and compare it again with the hash. My question is how secure is hashing? One of the Penetration testing companies claim that hashing functions can be exploited and there has to be some server side privilege validation as well. While I agree that server side validation is good, I am not sure if MD5 hashing can be broken. Can some one please share any information on this?
    Thanks in Advance

    Hi,
    Here are some articles outlining some of the weaknesses of MD5.
    [http://www.kb.cert.org/vuls/id/836068]
    [http://eprint.iacr.org/2004/199.pdf]
    [http://www.cs.colorado.edu/~jrblack/papers/md5e-full.pdf]
    If you are worried about collisions and are using this for security, you might want to use one of the SHA-2 family.
    Here are some links to NIST recommendations for message digests
    [http://csrc.nist.gov/groups/ST/toolkit/secure_hashing.html]
    [http://csrc.nist.gov/publications/nistpubs/800-107/NIST-SP-800-107.pdf]
    It is also worth noting that weaknesses have been found with SHA1 as well.
    Cheers,
    Shane

  • Md5 hash check sum on the Below

    Hi Experts
    how to perform md5 hash check sum on the Below :
    md5: 1265f8f703b00c15b02115aa20d6c50d all-in-one-VM-1.2.1-194.ova
    thanks to all
    Ibrahim

    Hey Ibrahim, 
    Use HashTab.  It's free and it's easy to install.  
    Once installed, highlight the file and click "Properties".  Go to the "File Hashes" tab and enter the MD5 value.  

  • MD5 hash

    hi ,
    does any has code for calculating the MD5 hash ..given the file it the code should get the MD5 hash..like for example picture files...like jpg,qxd...etc... if so please it..
    thanks..

    There is java.security.MessageDigest but I get different result with that then md5sum in my cygwin utilities. My test program is below. What am I doing wrong?
    import java.security.MessageDigest;
    public class ThreadID658080 {
        public static void main(String[] args) throws Exception {
            MessageDigest md = MessageDigest.getInstance("MD5");
            md.reset();
            md.update("ABC".getBytes());
            show(md);
        static void show(MessageDigest md) {
            byte[] arr = md.digest();
            System.out.println("Algorithm: " + md.getAlgorithm() + ", Length: " + md.getDigestLength());
            for (int i = 0; i < arr.length; i++) {
                System.out.print(arr);
    System.out.println();
    This program gives the following output:
    Algorithm: MD5, Length: 16
    -11247-67-46-79-331279112-76-91-465337-2350cygwin md5sum (and some other utilities) gives:
    $ echo "abc" | md5sum -b
    0bee89b07a248e27c83fc3d5951213c1

  • MD5 hash code in PLSQL

    Hi everyone,
    I am building dynamic web pages using Oracle's plsql web
    toolkit. I am building a page that will pass information to a
    credit card authorizer. I need to create a MD5 hash string to
    pass to the credit card company. Is there an Oracle built in
    procedure/function/package to generate a MD5 hash string? If
    not, can anyone recommend a good reference source for generating
    a MD5 hash code in a plsql environment.
    Thanks.
    Dave W.

    This is from the Object API; I think it has the information that explains what's happening (but doesn't resolve your apparent problem)
    public int hashCode()
    Returns a hash code value for the object. This method is supported for the benefit of hashtables such as those provided by java.util.Hashtable.
    The general contract of hashCode is:
    Whenever it is invoked on the same object more than once during an execution of a Java application, the hashCode method must consistently return the same integer, provided no information used in equals comparisons on the object is modified. This integer need not remain consistent from one execution of an application to another execution of the same application.
    If two objects are equal according to the equals(Object) method, then calling the hashCode method on each of the two objects must produce the same integer result.
    It is not required that if two objects are unequal according to the equals(java.lang.Object) method, then calling the hashCode method on each of the two objects must produce distinct integer results.
    However, the programmer should be aware that producing distinct integer results for unequal objects may improve the performance of hashtables.
    As much as is reasonably practical, the hashCode method defined by class Object does return distinct integers for distinct objects. (This is typically implemented by converting the internal address of the object into an integer, but this implementation technique is not required by the JavaTM programming language.)

Maybe you are looking for

  • How to play live streaming in windows phone 8.1 silverlight app?

    Hi, I am developing a windows phone 8.1 silverlight app. In my I want to show live streaming youtube channel , I think it is not possible,  Actually that youtube channel is a television channel , I want to stream that live tv in my app.(I tried to lo

  • Username and Password

    Hi ,  There is a cmd tool that we use for which we need to enter the uid and pwd in command line, i am writing a script , i would like to know is there a better way of prompting the uid and pwd of command prompt in windows prompt box using powershell

  • I receive an error while trying to partition my Harddrive back to one.

    So I have messed around with using bootcamp and and disk utlity to create partitions for Ubuntu. I decided to erase the extra partition and give all the space back to my macintosh HD. I go to the partition tab in disk utility and drag the macintosh b

  • ZENworks user source login won't go away

    Not sure where the best place to put this is. ZCM 11.2.1 Server 2008R2 - Embedded DB Win7 Clients - Not sure about XP, we're moving to Win7 only ASAP Active Directory When logging into a laptop and NOT connected to the domain LAN, it gets stuck on th

  • How to move apps in win 8.1

    My OP sys is win 8.1 I would like to consolidate all my games under GAMES. Right now  if I sesrch for games only  4-5 shows up but I have about 15. Could I move them under "GAMES" I know how to move icon on the START page but on the apps page (when I