Skip to main content

private_key_from_u256

Function private_key_from_u256 

Source
pub fn private_key_from_u256(
    private_key: U256,
) -> Result<PrivateKeySigner, String>
Expand description

Constructs a [PrivateKeySigner] from a raw private key value.

Returns Err when private_key is zero or its bytes are not a valid secp256k1 scalar.