xorEncodeBytesToString method
bytes to string xor encryption
Implementation
String xorEncodeBytesToString(List<int> bytes, {String? key}) {
this.key = key ?? this.key;
if (this.key != null && this.key!.isNotEmpty) {
return base64Encode(_xor(bytes, utf8.encode(this.key!)));
} else {
return base64Encode(_encrypt(bytes));
}
}