bytes property

List<int> bytes

bytes will calculate the bytes for the private key's D

Implementation

List<int> get bytes {
  var byteLen = (curve.bitSize + 7) >> 3;
  var hex = D.toRadixString(16).padLeft(byteLen * 2, '0'); // to bigendian
  return List<int>.generate(
      byteLen, (i) => int.parse(hex.substring(i * 2, i * 2 + 2), radix: 16));
}