Jump to content

Search the Community

Showing results for tags 'sha2'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • RuneLocus
    • News & Announcements
    • Information Booth
    • Website Support
    • Introductions
    • Chat
    • Forum Games
  • RuneScape Development
    • RSPS General
    • RuneScape Private Server (RS2)
    • RuneScape Private Server (503+)
    • RuneScape Private Server (EoC 742+)
  • Other
    • Digital Art
    • Gaming
    • Webdevelopment
    • Computers
  • Marketplace
    • RuneScape Market
    • RSPS Market
    • Others Market
    • Freelance Middleman Services
  • Super Secret Club's Topics

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Found 1 result

  1. This will work for any java program, you can use the following code to create a hash using any of the following cryptographic hash functions: MD2 MD5 Sha1 Sha-256 Sha-384 Sha-512 [code] import java.security.*; public static String createHash(String s) { try { MessageDigest md = MessageDigest.getInstance("Sha-512");//Change this to whatever Hash function you want to byte[] array = md.digest(s.getBytes()); StringBuffer sb = new StringBuffer(); for (int i = 0; i < array.length; i++) { sb.append(Integer.toHexString((array[i] & 0xFF) | 0x100).substring(1,3)); } return sb.toString(); } catch (NoSuchAlgorithmException e) { } return null; } [/code] There you go, secure hash for any string you want. Personally I use it to create a hash for the data I store on my MySQL Database, but there's multiple uses.
×