public final class EcdhCofactorKeyAgreement extends EcdhKeyAgreement
This implementation is based on the 'Modified Diffie-Hellman Primitive' defined in ANSI X9.63-2001 Section 5.4.2 (for further details, refer to ANSI X9.63). The modified ECDH primitive differs from the standard ECDH primitive by using the cofactor (an EC domain parameter) in the computation:
P = d1Q2P = hd1Q2h is the cofactor, d1 is the private key of
one party and Q2 is the public key of the other party. The
modified ECDH primitive was designed to resist small subgroup attacks.
An instance of this algorithm can be obtained using the Java Cryptography
Architecture (JCA), by requesting a 'cofactorECDH' key agreement algorithm
from the Entrust
cryptographic service provider. This can be done using the following call:
KeyAgreement.getInstance("cofactorECDH", "Entrust");This class SHOULD NOT be used directly; it should only be used through the JCA/JCE.
Note: When used with an EC domain that has a cofactor of 1, the
standard and modified ECDH primitives produce the same result (multiplication
by a cofactor of 1 is the identity operation). When a cofactor other than 1 is
used, the cofactor is included in the ECDH primitive. For a
list of the named curves that are supported, refer to
EcParameterFactory.
EcdhKeyAgreement| Constructor and Description |
|---|
EcdhCofactorKeyAgreement()
The constructor; creates a new instance of the cofactorECDH key agreement
algorithm.
|
engineDoPhase, engineGenerateSecret, engineGenerateSecret, engineGenerateSecret, engineInit, engineInitpublic EcdhCofactorKeyAgreement()
Applications should never use this constructor, instead the key agreement
algorithm should be requested from the appropriate JCA/JCE cryptographic
service provider as follows:
KeyAgreement.getInstance("cofactorECDH", "Entrust").