Class AlgorithmParametersSpi
- java.lang.Object
-
- java.security.AlgorithmParametersSpi
-
- org.bouncycastle.jcajce.provider.asymmetric.dh.AlgorithmParametersSpi
-
public class AlgorithmParametersSpi extends AlgorithmParametersSpi
-
-
Constructor Summary
Constructors Constructor Description AlgorithmParametersSpi()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected byte[]engineGetEncoded()Return the PKCS#3 ASN.1 structure DHParameter.protected byte[]engineGetEncoded(String format)Returns the parameters in the specified encoding format.protected AlgorithmParameterSpecengineGetParameterSpec(Class paramSpec)Returns theAlgorithmParameterSpecfor thisAlgorithmParametersSpi.protected voidengineInit(byte[] params)Initializes thisAlgorithmParametersSpiwith the specifiedbyte[]using the default decoding format for parameters.protected voidengineInit(byte[] params, String format)Initializes thisAlgorithmParametersSpiwith the specifiedbyte[]using the specified decoding format.protected voidengineInit(AlgorithmParameterSpec paramSpec)Initializes thisAlgorithmParametersSpiwith the specifiedAlgorithmParameterSpec.protected StringengineToString()Returns a string containing a concise, human-readable description of thisAlgorithmParametersSpi.protected booleanisASN1FormatString(String format)protected AlgorithmParameterSpeclocalEngineGetParameterSpec(Class paramSpec)
-
-
-
Method Detail
-
isASN1FormatString
protected boolean isASN1FormatString(String format)
-
engineGetParameterSpec
protected AlgorithmParameterSpec engineGetParameterSpec(Class paramSpec) throws InvalidParameterSpecException
Description copied from class:AlgorithmParametersSpiReturns theAlgorithmParameterSpecfor thisAlgorithmParametersSpi.- Specified by:
engineGetParameterSpecin classAlgorithmParametersSpi- Parameters:
paramSpec- the type of the parameter specification in which this parameters should be converted.- Returns:
- the
AlgorithmParameterSpecfor thisAlgorithmParametersSpi. - Throws:
InvalidParameterSpecException- if thisAlgorithmParametersSpihas already been initialized, or if this parameters could not be converted to the specified class.
-
engineGetEncoded
protected byte[] engineGetEncoded()
Return the PKCS#3 ASN.1 structure DHParameter.DHParameter ::= SEQUENCE { prime INTEGER, -- p base INTEGER, -- g privateValueLength INTEGER OPTIONAL}- Specified by:
engineGetEncodedin classAlgorithmParametersSpi- Returns:
- the encoded parameters.
-
engineGetEncoded
protected byte[] engineGetEncoded(String format)
Description copied from class:AlgorithmParametersSpiReturns the parameters in the specified encoding format.- Specified by:
engineGetEncodedin classAlgorithmParametersSpi- Parameters:
format- the name of the encoding format.- Returns:
- the encoded parameters.
-
localEngineGetParameterSpec
protected AlgorithmParameterSpec localEngineGetParameterSpec(Class paramSpec) throws InvalidParameterSpecException
- Throws:
InvalidParameterSpecException
-
engineInit
protected void engineInit(AlgorithmParameterSpec paramSpec) throws InvalidParameterSpecException
Description copied from class:AlgorithmParametersSpiInitializes thisAlgorithmParametersSpiwith the specifiedAlgorithmParameterSpec.- Specified by:
engineInitin classAlgorithmParametersSpi- Parameters:
paramSpec- the parameter specification.- Throws:
InvalidParameterSpecException- if thisAlgorithmParametersSpihas already been initialized or the givenparamSpecis not appropriate for initializing thisAlgorithmParametersSpi.
-
engineInit
protected void engineInit(byte[] params) throws IOExceptionDescription copied from class:AlgorithmParametersSpiInitializes thisAlgorithmParametersSpiwith the specifiedbyte[]using the default decoding format for parameters. The default encoding format is ASN.1.- Specified by:
engineInitin classAlgorithmParametersSpi- Parameters:
params- the encoded parameters.- Throws:
IOException- if thisAlgorithmParametersSpihas already been initialized, or the parameter could not be encoded.
-
engineInit
protected void engineInit(byte[] params, String format) throws IOExceptionDescription copied from class:AlgorithmParametersSpiInitializes thisAlgorithmParametersSpiwith the specifiedbyte[]using the specified decoding format.- Specified by:
engineInitin classAlgorithmParametersSpi- Parameters:
params- the encoded parameters.format- the name of the decoding format.- Throws:
IOException- if thisAlgorithmParametersSpihas already been initialized, or the parameter could not be encoded.
-
engineToString
protected String engineToString()
Description copied from class:AlgorithmParametersSpiReturns a string containing a concise, human-readable description of thisAlgorithmParametersSpi.- Specified by:
engineToStringin classAlgorithmParametersSpi- Returns:
- a printable representation for this
AlgorithmParametersSpi.
-
-