Compiere Looks 1.2.1

org.compiere.util
Class Secure

java.lang.Object
  |
  +--org.compiere.util.Secure

public class Secure
extends Object

Security Services (Open Source - none).

Version:
$Id: Secure.java,v 1.8 2003/01/11 05:46:34 jjanke Exp $
Author:
Jorg Janke

Field Summary
static String CLEARTEXT
          Clear Text Indiactor
 
Constructor Summary
Secure()
           
 
Method Summary
static String decrypt(String value)
          Decryption
static String encrypt(String value)
          Encryption
static String getDigest(String message)
          Convert Message to Digest.
static int hash(String key)
          Hash checksum number
static boolean isDigest(String value)
          Checks, if value is a valid digest
static void main(String[] args)
          Test
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLEARTEXT

public static final String CLEARTEXT
Clear Text Indiactor

See Also:
Constant Field Values
Constructor Detail

Secure

public Secure()
Method Detail

encrypt

public static String encrypt(String value)
Encryption

Parameters:
value - clear value
Returns:
encrypted String

decrypt

public static String decrypt(String value)
Decryption

Parameters:
value - encrypted value
Returns:
decrypted String

hash

public static int hash(String key)
Hash checksum number

Parameters:
key - key
Returns:
checksum number

getDigest

public static String getDigest(String message)
Convert Message to Digest. JavaScript version see - http://pajhome.org.uk/crypt/md5/index.html

Parameters:
message - message
Returns:
HexString of message (length = 32 characters)

isDigest

public static boolean isDigest(String value)
Checks, if value is a valid digest

Parameters:
value - digest string
Returns:
true if valid digest

main

public static void main(String[] args)
Test

Parameters:
args - ignored

Compiere Looks 1.2.1

Copyright (c) 1999-2003 ComPiere, Inc. - Author: Jorg Janke