Package org.activecomponents.udp
Class SymCipherSuite
- java.lang.Object
-
- org.activecomponents.udp.SymCipherSuite
-
public class SymCipherSuite extends java.lang.Object
Class containing a symmetric cipher and associated security data.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.concurrent.atomic.AtomicLong
messageidcounter
Counters for message IDs.protected java.util.concurrent.atomic.AtomicLong
packetidcounter
Counters for packet IDs, must be greater than Long.MIN_VALUE to allow replay identification to work.protected IdReplayTracker
packetidreplaytracker
Tracker for identifying packet replaysprotected ISymCipher
symcipher
The symmetric cipher.
-
Constructor Summary
Constructors Constructor Description SymCipherSuite(ISymCipher symcipher)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.concurrent.atomic.AtomicLong
getMessageidcounter()
Gets the message ID counter.java.util.concurrent.atomic.AtomicLong
getPacketidcounter()
Gets the packet ID counter.IdReplayTracker
getPacketIdReplayTracker()
Returns Packet ID tracker for identifying replay attacks.ISymCipher
getSymCipher()
Gets the symmetric cipher.
-
-
-
Field Detail
-
packetidcounter
protected java.util.concurrent.atomic.AtomicLong packetidcounter
Counters for packet IDs, must be greater than Long.MIN_VALUE to allow replay identification to work.
-
messageidcounter
protected java.util.concurrent.atomic.AtomicLong messageidcounter
Counters for message IDs.
-
packetidreplaytracker
protected IdReplayTracker packetidreplaytracker
Tracker for identifying packet replays
-
symcipher
protected ISymCipher symcipher
The symmetric cipher.
-
-
Constructor Detail
-
SymCipherSuite
public SymCipherSuite(ISymCipher symcipher)
-
-
Method Detail
-
getPacketidcounter
public java.util.concurrent.atomic.AtomicLong getPacketidcounter()
Gets the packet ID counter.- Returns:
- The packet ID counter.
-
getMessageidcounter
public java.util.concurrent.atomic.AtomicLong getMessageidcounter()
Gets the message ID counter.- Returns:
- The message ID counter.
-
getPacketIdReplayTracker
public IdReplayTracker getPacketIdReplayTracker()
Returns Packet ID tracker for identifying replay attacks.- Returns:
- Packet ID tracker.
-
getSymCipher
public ISymCipher getSymCipher()
Gets the symmetric cipher.- Returns:
- The symmetric cipher.
-
-