java.lang.Object
net.i2p.crypto.eddsa.spec.EdDSAParameterSpec
- All Implemented Interfaces:
Serializable, AlgorithmParameterSpec
- Direct Known Subclasses:
EdDSANamedCurveSpec
Parameter specification for an EdDSA algorithm.
- See Also:
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final GroupElementThe base point.private final CurveThe curve parameters.private final StringHash algo.private final ScalarOpsThe scalar operations.private static final longPinned for serialized-form compatibility.Constructor Summary
ConstructorsConstructorDescriptionEdDSAParameterSpec(Curve curve, String hashAlgo, ScalarOps sc, GroupElement b) Create a new EdDSA parameter specification.Method Summary
All MethodsModifier and TypeMethodDescriptionbooleanCompares this parameter specification to another object for equality.getB()Return the base (generator) point.getCurve()Returns the curve used by this parameter specification.Returns the JCA hash algorithm name.Returns the scalar operations implementation.inthashCode()Returns a hash code for this parameter specification.
Field Details
serialVersionUID
private static final long serialVersionUIDPinned for serialized-form compatibility.- See Also:
curve
The curve parameters.hashAlgo
Hash algo.sc
The scalar operations.B
The base point.
Constructor Details
EdDSAParameterSpec
Create a new EdDSA parameter specification.- Parameters:
curve- the curve the parameters describe; its field size must match the hash output lengthhashAlgo- the JCA string for the hash algorithmsc- the parameter L represented as ScalarOpsb- the parameter B- Throws:
IllegalArgumentException- if hash algorithm is unsupported or length is wrong
Method Details
getCurve
Returns the curve used by this parameter specification.- Returns:
- the curve parameters this spec was built with, never null
getHashAlgorithm
getScalarOps
Returns the scalar operations implementation.- Returns:
- the scalar operations
getB
hashCode
equals