Compiere 3.1

org.compiere.util
Class SecureUtil

java.lang.Object
  extended by org.compiere.util.SecureUtil

public class SecureUtil
extends Object

Security Utility

Version:
$Id$
Author:
Jorg Janke

Field Summary
static String SecureFileName
          Secure File name
 
Method Summary
static byte[] convertHexString(String hexString)
          Convert Hex String to Byte Array
static String convertToHexString(byte[] bytes)
          Convert Byte Array to Hex String
static boolean createNewKey(String compiereHome)
          Create New Key and Install.
static File getKeyFile(String compiereHome)
          Get Key Name
static int hash(String key)
          Hash checksum number
static boolean installKey(String compiereHome)
          Install Key
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

SecureFileName

public static final String SecureFileName
Secure File name

See Also:
Constant Field Values
Method Detail

hash

public static int hash(String key)
Hash checksum number

Parameters:
key - key
Returns:
checksum number

convertToHexString

public static String convertToHexString(byte[] bytes)
Convert Byte Array to Hex String

Parameters:
bytes - bytes
Returns:
HexString

convertHexString

public static byte[] convertHexString(String hexString)
Convert Hex String to Byte Array

Parameters:
hexString - hex string
Returns:
byte array

createNewKey

public static boolean createNewKey(String compiereHome)
Create New Key and Install. Should not be called as it always will create a new key

Parameters:
compiereHome - compiere home directory
Returns:
true if key installed

installKey

public static boolean installKey(String compiereHome)
Install Key

Parameters:
compiereHome - compiere home directory
Returns:
true if key installed

getKeyFile

public static File getKeyFile(String compiereHome)
Get Key Name

Parameters:
compiereHome - compiere home directory
Returns:
file name

main

public static void main(String[] args)
Test

Parameters:
args -

Compiere 3.1

Compiere® is a registered trademark of ComPiere, Inc. ©2004-2008 HumanFlash.com All rights reserved.