pub type Result<T> = core::result::Result<T, Error>;
#[derive(Copy, Clone, Eq, PartialEq, Debug)]
#[repr(u32)]
pub enum Error {
HostMemory = 0x0000_0002,
GeneralError = 0x0000_0005,
FunctionFailed = 0x0000_0006,
FunctionNotSupported = 0x0000_0054,
MechanismInvalid = 0x0000_0070,
MechanismParamInvalid = 0x0000_0071,
ObjectHandleInvalid = 0x0000_0082,
AeadError,
CborError,
EntropyMalfunction,
FilesystemReadFailure,
FilesystemWriteFailure,
ImplementationError,
InternalError,
InvalidSerializedKey,
InvalidSerializationFormat,
MechanismNotAvailable,
NonceOverflow,
NoSuchCertificate,
NoSuchKey,
NotJustLetters,
RequestNotAvailable,
SignDataTooLarge,
WrongKeyKind,
WrongMessageLength,
WrongSignatureLength,
}