title: TransformFinalBlock with TripleDes(3DES) - DESMode.ECB in Dart/Flutter
body: <p>I tried and looked for a solution to my problem, but I didn't find anything that worked.</p>
  <p>I have a C# program that works perfectly. My task is to turn this program into Flutter, but I can't.</p>
  <p>** The code (in C#) that works is this: **</p>
  <pre><code>private ICryptoTransform mDesEnc;
  TripleDESCryptoServiceProvider mDes = new TripleDESCryptoServiceProvider();
  mDes.Key = Convert.FromBase64String(&quot;B4WOmhsRsOSD2ZRfhmULCcI0lR4kNiy6&quot;);
  mDes.Mode = CipherMode.ECB;
  mDes.Padding = PaddingMode.Zeros;
  mDesEnc = mDes.CreateEncryptor();
  
  mSeq = 2;
  byte[] data = Encoding.UTF8.GetBytes(mSeq.ToString());
  var dec = mDesEnc.TransformFinalBlock(data, 0, data.Length);
  var ret = Convert.ToBase64String(dec);
  //dec = 213, 5, 215, 181, 143, 185, 167, 134
  //ret = &quot;1QXXtY+5p4Y=&quot;
  </code></pre>
  <p>In Flutter, I tried to do this:</p>
  <pre><code>final key = base64.decode(&quot;B4WOmhsRsOSD2ZRfhmULCcI0lR4kNiy6&quot;);
  print(key);
  final seq = 2;
  final bytes = utf8.encode(seq.toString());
  
  mDes3CBC = DES3(
    key: key,
    mode: DESMode.ECB,
    paddingType: DESPaddingType.OneAndZeroes,
  );
  
  List&lt;int&gt; t = [];
  t.add(bytes.last);
  
  final encrypted = mDes3CBC!.encrypt(t);
  print(encrypted);
  </code></pre>
  <p>but the result is: // [11, 195, 182, 192, 231, 57, 14, 15] (Needs to be like 'dec' in the other example).
  different from expected.</p>