decrypt method

Iterable<int> decrypt(
  1. dynamic input, {
  2. Padder? padder,
  3. bool raw = false,
})

Implementation

Iterable<int> decrypt(/* String | List<int> */ input,
    {Padder? padder, bool raw = false}) {
  Uint8List inputBytes;
  if (input is String) {
    inputBytes = base64Decode(input);
  } else if (input is Uint8List) {
    inputBytes = input;
  } else if (input is List<int>) {
    inputBytes = Uint8List.fromList(input);
  } else {
    throw ArgumentError('Should be String or List<int>');
  }
  Iterable<int> unpadded = engine.process(inputBytes, dontPadLastBlock: raw);
  if (padder == null) {
    return unpadded;
  }
  return padder.unpad(blockSize, unpadded);
}