Interface SecpScalar
- All Known Implementing Classes:
SecpScalarImpl
public interface SecpScalar
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic BigIntegerThrowIllegalArgumentExceptionif an integer is not in the inclusive range1toN - 1, whereNis the order of the SECG P256K1 generator point.static booleanCheck if an integer is in the inclusive range1toN - 1, whereNis the order of the SECG P256K1 generator point.byte[]Get the scalar as aBigInteger
-
Field Details
-
MIN_VALUE
-
MAX_VALUE
-
-
Method Details
-
toBigInteger
-
isInRange
Check if an integer is in the inclusive range1toN - 1, whereNis the order of the SECG P256K1 generator point.- Parameters:
e- A possible scalar to validate- Returns:
- true if valid
-
checkInRange
ThrowIllegalArgumentExceptionif an integer is not in the inclusive range1toN - 1, whereNis the order of the SECG P256K1 generator point.- Parameters:
e- unvalidated integer- Returns:
- a validated integer
-
serialize
byte[] serialize()
-