L2JPREMIUM  5M
com.premium.NewCrypt Class Reference
Collaboration diagram for com.premium.NewCrypt:

Public Member Functions

 NewCrypt (byte[] blowfishKey)
 
 NewCrypt (String key)
 
byte[] decrypt (byte[] raw) throws IOException
 
void decrypt (byte[] raw, final int offset, final int size) throws IOException
 
byte[] crypt (byte[] raw) throws IOException
 
void crypt (byte[] raw, final int offset, final int size) throws IOException
 

Static Public Member Functions

static boolean verifyChecksum (byte[] raw)
 
static boolean verifyChecksum (byte[] raw, final int offset, final int size)
 
static void appendChecksum (byte[] raw)
 
static void appendChecksum (byte[] raw, final int offset, final int size)
 
static void encXORPass (byte[] raw, int key)
 
static void encXORPass (byte[] raw, final int offset, final int size, int key)
 

Static Protected Attributes

static Logger _log = Logger.getLogger(NewCrypt.class.getName())
 

Detailed Description

This class ...

Version
Revision
1.3.4.1
Date
2005/03/27 15:30:09

Constructor & Destructor Documentation

◆ NewCrypt()

com.premium.NewCrypt.NewCrypt ( byte[]  blowfishKey)
inline
Parameters
blowfishKey

Member Function Documentation

◆ encXORPass() [1/2]

static void com.premium.NewCrypt.encXORPass ( byte[]  raw,
final int  offset,
final int  size,
int  key 
)
inlinestatic

Packet is first XOR encoded with key Then, the last 4 bytes are overwritten with the the XOR "key". Thus this assume that there is enough room for the key to fit without overwriting data.

Parameters
rawThe raw bytes to be encrypted
offsetThe begining of the data to be encrypted
sizeLength of the data to be encrypted
keyThe 4 bytes (int) XOR key

◆ encXORPass() [2/2]

static void com.premium.NewCrypt.encXORPass ( byte[]  raw,
int  key 
)
inlinestatic

Packet is first XOR encoded with key Then, the last 4 bytes are overwritten with the the XOR "key". Thus this assume that there is enough room for the key to fit without overwriting data.

Parameters
rawThe raw bytes to be encrypted
keyThe 4 bytes (int) XOR key

The documentation for this class was generated from the following file: