Class GF2nONBField
java.lang.Object
org.bouncycastle.pqc.legacy.math.linearalgebra.GF2nField
org.bouncycastle.pqc.legacy.math.linearalgebra.GF2nONBField
This class implements the abstract class GF2nField for ONB
representation. It computes the fieldpolynomial, multiplication matrix and
one of its roots mONBRoot, (see for example Certicoms Whitepapers).
GF2nField is used by GF2nONBElement which implements the elements of this
field.
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorDescriptionGF2nONBField
(int deg, SecureRandom random) constructs an instance of the finite field with 2deg elements and characteristic 2. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
Computes the change-of-basis matrix for basis conversion according to 1363.protected void
Computes the field polynomial for a ONB according to IEEE 1363 A.7.2 (p110f).protected GF2nElement
getRandomRoot
(GF2Polynomial polynomial) Computes a random root of the given polynomial.Methods inherited from class org.bouncycastle.pqc.legacy.math.linearalgebra.GF2nField
convert, equals, getDegree, getFieldPolynomial, hashCode, invertMatrix
-
Constructor Details
-
GF2nONBField
constructs an instance of the finite field with 2deg elements and characteristic 2.- Parameters:
deg
- -the extention degree of this fieldrandom
- - a source of randomness for generating polynomials on the field.- Throws:
RuntimeException
-
-
Method Details
-
getRandomRoot
Computes a random root of the given polynomial.- Specified by:
getRandomRoot
in classGF2nField
- Parameters:
polynomial
- a polynomial- Returns:
- a random root of the polynomial
- See Also:
-
computeCOBMatrix
Computes the change-of-basis matrix for basis conversion according to 1363. The result is stored in the lists fields and matrices.- Specified by:
computeCOBMatrix
in classGF2nField
- Parameters:
B1
- the GF2nField to convert to- See Also:
-
computeFieldPolynomial
protected void computeFieldPolynomial()Computes the field polynomial for a ONB according to IEEE 1363 A.7.2 (p110f).- Specified by:
computeFieldPolynomial
in classGF2nField
- See Also:
-