org.PingOO.DLAI.PPM.codec
Class FromServerCodec

java.lang.Object
  |
  +--org.PingOO.DLAI.PPM.codec.FromServerCodec

public class FromServerCodec
extends java.lang.Object

This class use the client's public key to decrypt messages from the server.

Since:
PingOO 2.0
Version:
2.0
Author:
Fabrice Bouyé (bouye@cur-archamps.fr)

Constructor Summary
private FromServerCodec()
          Hides the constructor from the outside.
 
Method Summary
static byte[] decode(byte[] data)
          Decrypts a byte array using the default method.
static java.lang.String getPublicKey()
          Return the public key used to decode messages that were sent from the server.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Constructor Detail

FromServerCodec

private FromServerCodec()
Hides the constructor from the outside.
Method Detail

getPublicKey

public static final java.lang.String getPublicKey()
Return the public key used to decode messages that were sent from the server.

decode

public static byte[] decode(byte[] data)
                     throws java.lang.NullPointerException
Decrypts a byte array using the default method.
Parameters:
message - The data array to be decoded.
Returns:
The decoded byte array.
Throws:
java.lang.NullPointerException - If data is null.