|
|||||||||
Home >> All >> gnu >> javax >> net >> ssl >> [ provider overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: ![]() ![]() ![]() |
DETAIL: FIELD | CONSTR | METHOD |
gnu.javax.net.ssl.provider
Class JCESecurityParameters

java.lang.Objectgnu.javax.net.ssl.provider.JCESecurityParameters
- All Implemented Interfaces:
- SecurityParameters
- class JCESecurityParameters
- extends java.lang.Object
- implements SecurityParameters
- extends java.lang.Object
Field Summary | |
private java.util.zip.Deflater |
deflater
|
private int |
fragmentLength
|
private javax.crypto.Cipher |
inCipher
|
private java.util.zip.Inflater |
inflater
|
private javax.crypto.Mac |
inMac
|
private long |
inSequence
|
private javax.crypto.Cipher |
outCipher
|
private javax.crypto.Mac |
outMac
|
private long |
outSequence
|
private ProtocolVersion |
version
|
Constructor Summary | |
(package private) |
JCESecurityParameters()
|
Method Summary | |
byte[] |
decrypt(byte[] fragment,
ProtocolVersion version,
ContentType type)
Decrypts, verifies, and inflates a fragment received. |
byte[] |
encrypt(byte[] fragment,
int off,
int len,
ContentType type)
Deflates, authenticates, and encrypts a fragment to be sent. |
int |
getFragmentLength()
Returns the maximum size that plaintext fragments may be. |
ProtocolVersion |
getVersion()
Returns the version of texts being sent. |
void |
reset()
Set all crypto primitives to null , meaning that any calls
to #encrypt(byte[],int,int,org.metastatic.jessie.provider.ContentType) or
#decrypt(byte[],org.metastatic.jessie.provider.ProtocolVersion,org.metastatic.jessie.provider.ContentType )
will perform the identity transformation. |
void |
setDeflating(boolean deflate)
Turns zlib deflating on or off. |
void |
setFragmentLength(int fragmentLength)
Sets the maximum size that plaintext fragments may be. |
void |
setInCipher(java.lang.Object inCipher)
Set the cipher used to decrypt incoming fragments. |
void |
setInflating(boolean inflate)
Turns zlib inflating on or off. |
void |
setInMac(java.lang.Object inMac)
Set the MAC used to verify incoming fragments. |
void |
setOutCipher(java.lang.Object outCipher)
Set the cipher used to encrypt outgoing fragments. |
void |
setOutMac(java.lang.Object outMac)
Set the MAC used to authenticating outgoinging fragments. |
void |
setVersion(ProtocolVersion version)
Sets the version of texts being sent. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
inCipher
private javax.crypto.Cipher inCipher
outCipher
private javax.crypto.Cipher outCipher
inMac
private javax.crypto.Mac inMac
outMac
private javax.crypto.Mac outMac
inflater
private java.util.zip.Inflater inflater
deflater
private java.util.zip.Deflater deflater
fragmentLength
private int fragmentLength
inSequence
private long inSequence
outSequence
private long outSequence
version
private ProtocolVersion version
Constructor Detail |
JCESecurityParameters
JCESecurityParameters()
Method Detail |
reset
public void reset()
- Description copied from interface:
SecurityParameters
- Set all crypto primitives to
null
, meaning that any calls to#encrypt(byte[],int,int,org.metastatic.jessie.provider.ContentType)
or#decrypt(byte[],org.metastatic.jessie.provider.ProtocolVersion,org.metastatic.jessie.provider.ContentType
) will perform the identity transformation.- Specified by:
reset
in interfaceSecurityParameters
setInCipher
public void setInCipher(java.lang.Object inCipher)
- Description copied from interface:
SecurityParameters
- Set the cipher used to decrypt incoming fragments. The parameter must be
appropriate for the implementation.
- Specified by:
setInCipher
in interfaceSecurityParameters
setOutCipher
public void setOutCipher(java.lang.Object outCipher)
- Description copied from interface:
SecurityParameters
- Set the cipher used to encrypt outgoing fragments. The parameter must be
appropriate for the implementation.
- Specified by:
setOutCipher
in interfaceSecurityParameters
setInMac
public void setInMac(java.lang.Object inMac)
- Description copied from interface:
SecurityParameters
- Set the MAC used to verify incoming fragments. The parameter must be
appropriate for the implementation.
- Specified by:
setInMac
in interfaceSecurityParameters
setOutMac
public void setOutMac(java.lang.Object outMac)
- Description copied from interface:
SecurityParameters
- Set the MAC used to authenticating outgoinging fragments. The parameter
must be appropriate for the implementation.
- Specified by:
setOutMac
in interfaceSecurityParameters
setDeflating
public void setDeflating(boolean deflate)
- Description copied from interface:
SecurityParameters
- Turns zlib deflating on or off.
- Specified by:
setDeflating
in interfaceSecurityParameters
setInflating
public void setInflating(boolean inflate)
- Description copied from interface:
SecurityParameters
- Turns zlib inflating on or off.
- Specified by:
setInflating
in interfaceSecurityParameters
getFragmentLength
public int getFragmentLength()
- Description copied from interface:
SecurityParameters
- Returns the maximum size that plaintext fragments may be.
- Specified by:
getFragmentLength
in interfaceSecurityParameters
setFragmentLength
public void setFragmentLength(int fragmentLength)
- Description copied from interface:
SecurityParameters
- Sets the maximum size that plaintext fragments may be.
- Specified by:
setFragmentLength
in interfaceSecurityParameters
getVersion
public ProtocolVersion getVersion()
- Description copied from interface:
SecurityParameters
- Returns the version of texts being sent.
- Specified by:
getVersion
in interfaceSecurityParameters
setVersion
public void setVersion(ProtocolVersion version)
- Description copied from interface:
SecurityParameters
- Sets the version of texts being sent. This affects the
#encrypt(byte[],int,int,org.metastatic.jessie.provider.ContentType)
method.- Specified by:
setVersion
in interfaceSecurityParameters
decrypt
public byte[] decrypt(byte[] fragment, ProtocolVersion version, ContentType type) throws MacException, OverflowException, javax.net.ssl.SSLException
- Description copied from interface:
SecurityParameters
- Decrypts, verifies, and inflates a fragment received. The fragment is
just the data field of a text object, without the version, type, and
length fields. An exception is thrown if any step fails.
- Specified by:
decrypt
in interfaceSecurityParameters
encrypt
public byte[] encrypt(byte[] fragment, int off, int len, ContentType type) throws OverflowException, javax.net.ssl.SSLException
- Description copied from interface:
SecurityParameters
- Deflates, authenticates, and encrypts a fragment to be sent.
- Specified by:
encrypt
in interfaceSecurityParameters
|
|||||||||
Home >> All >> gnu >> javax >> net >> ssl >> [ provider overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: ![]() ![]() ![]() |
DETAIL: FIELD | CONSTR | METHOD |