egovframework.rfc3.common.crypt
Class SEED

java.lang.Object
  extended by egovframework.rfc3.common.crypt.SEED

public class SEED
extends java.lang.Object

S-box table


Constructor Summary
SEED()
           
 
Method Summary
static java.lang.String byteArrayToHex(byte[] ba)
           
static java.lang.String Decrypt(java.lang.String key, java.lang.String data)
           
static java.lang.String Encrypt(java.lang.String key, java.lang.String data)
           
static byte[] hexToByteArray(java.lang.String hex)
           
static void SeedDecrypt(byte[] pbData, int[] pdwRoundKey, byte[] outData)
          SEED decrtyption function
static void SeedEncrypt(byte[] pbData, int[] pdwRoundKey, byte[] outData)
          SEED encrtyption function
static void SeedRoundKey(int[] pdwRoundKey, byte[] pbUserKey)
          Key Schedule
static java.lang.String stringToHex(java.lang.String s)
          Example code
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SEED

public SEED()
Method Detail

SeedEncrypt

public static void SeedEncrypt(byte[] pbData,
                               int[] pdwRoundKey,
                               byte[] outData)
SEED encrtyption function


SeedDecrypt

public static void SeedDecrypt(byte[] pbData,
                               int[] pdwRoundKey,
                               byte[] outData)
SEED decrtyption function


SeedRoundKey

public static void SeedRoundKey(int[] pdwRoundKey,
                                byte[] pbUserKey)
Key Schedule


stringToHex

public static java.lang.String stringToHex(java.lang.String s)
Example code


hexToByteArray

public static byte[] hexToByteArray(java.lang.String hex)

byteArrayToHex

public static java.lang.String byteArrayToHex(byte[] ba)

Encrypt

public static java.lang.String Encrypt(java.lang.String key,
                                       java.lang.String data)

Decrypt

public static java.lang.String Decrypt(java.lang.String key,
                                       java.lang.String data)