crypto / org.apache.tuweni.crypto / SECP256K1 / SecretKey

SecretKey

class SecretKey : Destroyable (source)

A SECP256K1 private key.

Functions

bytes

open fun bytes(): Bytes32

bytesArray

open fun bytesArray(): ByteArray

destroy

open fun destroy(): Unit

equals

open fun equals(other: Any?): Boolean

fromBytes

open static fun fromBytes(bytes: Bytes32): SecretKey

Create the private key from bytes.

fromInteger

open static fun fromInteger(key: BigInteger): SecretKey

Create the private key from a BigInteger.

hashCode

open fun hashCode(): Int

load

open static fun load(file: Path): SecretKey

Load a private key from a file.

store

open fun store(file: Path): Unit

Write the secret key to a file.