@Deprecated
public class TlsMasterSecretParameterSpec
extends java.lang.Object
implements java.security.spec.AlgorithmParameterSpec
Instances of this class are immutable.
| Constructor and Description |
|---|
TlsMasterSecretParameterSpec(javax.crypto.SecretKey premasterSecret,
int majorVersion,
int minorVersion,
byte[] clientRandom,
byte[] serverRandom,
java.lang.String prfHashAlg,
int prfHashLength,
int prfBlockSize)
Deprecated.
Constructs a new TlsMasterSecretParameterSpec.
|
TlsMasterSecretParameterSpec(javax.crypto.SecretKey premasterSecret,
int majorVersion,
int minorVersion,
byte[] extendedMasterSecretSessionHash,
java.lang.String prfHashAlg,
int prfHashLength,
int prfBlockSize)
Deprecated.
Constructs a new TlsMasterSecretParameterSpec.
|
| Modifier and Type | Method and Description |
|---|---|
byte[] |
getClientRandom()
Deprecated.
Returns a copy of the client's random value.
|
byte[] |
getExtendedMasterSecretSessionHash()
Deprecated.
Returns a copy of the Extended Master Secret session hash.
|
int |
getMajorVersion()
Deprecated.
Returns the major version number.
|
int |
getMinorVersion()
Deprecated.
Returns the minor version number.
|
javax.crypto.SecretKey |
getPremasterSecret()
Deprecated.
Returns the premaster secret.
|
int |
getPRFBlockSize()
Deprecated.
Obtains the block size of the PRF hash algorithm.
|
java.lang.String |
getPRFHashAlg()
Deprecated.
Obtains the PRF hash algorithm to use in the PRF calculation.
|
int |
getPRFHashLength()
Deprecated.
Obtains the length of the PRF hash algorithm.
|
byte[] |
getServerRandom()
Deprecated.
Returns a copy of the server's random value.
|
public TlsMasterSecretParameterSpec(javax.crypto.SecretKey premasterSecret,
int majorVersion,
int minorVersion,
byte[] clientRandom,
byte[] serverRandom,
java.lang.String prfHashAlg,
int prfHashLength,
int prfBlockSize)
The getAlgorithm() method of premasterSecret
should return "TlsRsaPremasterSecret" if the key exchange
algorithm was RSA and "TlsPremasterSecret" otherwise.
premasterSecret - the premaster secretmajorVersion - the major number of the protocol versionminorVersion - the minor number of the protocol versionclientRandom - the client's random valueserverRandom - the server's random valueprfHashAlg - the name of the TLS PRF hash algorithm to use.
Used only for TLS 1.2+. TLS1.1 and earlier use a fixed PRF.prfHashLength - the output length of the TLS PRF hash algorithm.
Used only for TLS 1.2+.prfBlockSize - the input block size of the TLS PRF hash algorithm.
Used only for TLS 1.2+.java.lang.NullPointerException - if premasterSecret, clientRandom,
or serverRandom are nulljava.lang.IllegalArgumentException - if minorVersion or majorVersion are
negative or larger than 255public TlsMasterSecretParameterSpec(javax.crypto.SecretKey premasterSecret,
int majorVersion,
int minorVersion,
byte[] extendedMasterSecretSessionHash,
java.lang.String prfHashAlg,
int prfHashLength,
int prfBlockSize)
The getAlgorithm() method of premasterSecret
should return "TlsRsaPremasterSecret" if the key exchange
algorithm was RSA and "TlsPremasterSecret" otherwise.
premasterSecret - the premaster secretmajorVersion - the major number of the protocol versionminorVersion - the minor number of the protocol versionextendedMasterSecretSessionHash - the session hash for
Extended Master SecretprfHashAlg - the name of the TLS PRF hash algorithm to use.
Used only for TLS 1.2+. TLS1.1 and earlier use a fixed PRF.prfHashLength - the output length of the TLS PRF hash algorithm.
Used only for TLS 1.2+.prfBlockSize - the input block size of the TLS PRF hash algorithm.
Used only for TLS 1.2+.java.lang.NullPointerException - if premasterSecret is nulljava.lang.IllegalArgumentException - if minorVersion or majorVersion are
negative or larger than 255public javax.crypto.SecretKey getPremasterSecret()
public int getMajorVersion()
public int getMinorVersion()
public byte[] getClientRandom()
public byte[] getServerRandom()
public byte[] getExtendedMasterSecretSessionHash()
public java.lang.String getPRFHashAlg()
public int getPRFHashLength()
public int getPRFBlockSize()