Package org.activecomponents.udp
Class NullKeyVerifier
- java.lang.Object
- 
- org.activecomponents.udp.NullKeyVerifier
 
- 
- All Implemented Interfaces:
- IKeyVerifier
 
 public class NullKeyVerifier extends java.lang.Object implements IKeyVerifier Implements a verification-less approach (MITM attacks are possible!)
- 
- 
Field SummaryFields Modifier and Type Field Description static byteMAGIC_BYTE
 - 
Constructor SummaryConstructors Constructor Description NullKeyVerifier()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]sign(byte[] input)Signs the public key.booleanverify(byte[] input, byte[] signature)Verifies a signed input..
 
- 
- 
- 
Field Detail- 
MAGIC_BYTEpublic static final byte MAGIC_BYTE - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
signpublic byte[] sign(byte[] input) Signs the public key.- Specified by:
- signin interface- IKeyVerifier
- Parameters:
- input- Raw data of the key.
- Returns:
- Signed key.
 
 - 
verifypublic boolean verify(byte[] input, byte[] signature)Verifies a signed input..- Specified by:
- verifyin interface- IKeyVerifier
- Parameters:
- input- Raw data sent by remote.
- signature- The signature.
- Returns:
- True, if the input could be verified, false if not.
 
 
- 
 
-