encodeSha1 static method

String encodeSha1(
  1. String data
)

sha1 加密

Implementation

static String encodeSha1(String data) {
  var bytes = utf8.encode(data);
  var digest = sha1.convert(bytes);
  return digest.toString();
}