|
Authentication API v8.1 SP2 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.rsa.ace.techservice.udpserver.AcePacketTrailer
public class AcePacketTrailer
This is a packet trailer parsing/building helper class. This is used by both requests and responses for trailer processing. It implements methods associated with processing nonce and packet CRC calculations.
| Constructor Summary | |
|---|---|
AcePacketTrailer()
Constructs an AcePacketTrailer which nonce will be initialized |
|
AcePacketTrailer(byte[] nonce)
Constructs a default AcePacketTrailer. |
|
AcePacketTrailer(java.nio.ByteBuffer buf)
Constructs an AcePacketTrailer reading bytes from the stream passed. |
|
| Method Summary | |
|---|---|
boolean |
addNonce(java.nio.ByteBuffer respBuf)
Adds the nonce portion of the AcePacketTrailer to the buffer passed. |
int |
calculateCRC(byte[] crcData,
int crcDataOffset,
int crcDataLength)
Calculates the Cyclic Redundacy Check value for the trailer. |
int |
getCRC()
This returns the Cyclic Redundacy Check value from the trailer. |
byte[] |
getNonce()
This returns the nonce. |
int |
getSize()
|
java.lang.String |
toString()
Converts the AcePacketTrailer to a string. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public AcePacketTrailer(byte[] nonce)
throws AcePacketException
nonce - A request from which the nonce is taken. This may be null.cyclicRedundancyCheck - The CRC for the trailer.
AcePacketException - If the nonce is not the correct length.
public AcePacketTrailer(java.nio.ByteBuffer buf)
throws AcePacketException
buf - The byte-buffer from which the header is initialized.
AcePacketException - If the nonce is not the correct length or this
is unable to get the nonce and CRC values.
public AcePacketTrailer()
throws AcePacketException
AcePacketException| Method Detail |
|---|
public byte[] getNonce()
public int getCRC()
public boolean addNonce(java.nio.ByteBuffer respBuf)
throws AcePacketException
respBuf - The byte-buffer to which the nonce is written.
AcePacketException - If an error occurs adding the nonce.
public int calculateCRC(byte[] crcData,
int crcDataOffset,
int crcDataLength)
crcData - The data to be CRC'd. This should include the nonce.crcDataOffset - The offset at which CRC calculation will start.cdcDataLength - The number of bytes to be CRC'ed.
public int getSize()
public java.lang.String toString()
toString in class java.lang.Object
|
Authentication API v8.1 SP2 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||