isValidBytes static method

bool isValidBytes(
  1. List<int> keyBytes
)
override

Static method to check the validity of a byte array as a public key for a specific elliptic curve type.

Implementation

static bool isValidBytes(List<int> keyBytes) {
  try {
    BaseDkls23PublicKey.fromBytes(keyBytes);
    return true;
  } catch (_) {
    return false;
  }
}