public static IObservable <Tuple <byte[], byte[]> > EncryptAESWithCBCAsync(byte[] src, byte[] key, int encryptKeyCount) { byte[] iv = null; byte[] dst = null; return(Observable.Start(() => Utility.EncryptAESWithCBC(src, key, encryptKeyCount, out iv, out dst)) .ObserveOnMainThread() .Select(_ => Tuple.Create(iv, dst))); }
public static IObservable <Tuple <string, string> > EncryptAESWithABCAsync(string src, string key, int encryptKeyCount) { string iv = null; string dst = null; return(Observable.Start(() => Utility.EncryptAESWithCBC(src, key, encryptKeyCount, out iv, out dst)) .ObserveOnMainThread() .Select(_ => Tuple.Create(iv, dst))); }