예제 #1
0
        public async Task <string> EncryptEphemeralAsync <T>(T data, TimeSpan?validity = null)
            where T : class
        {
            var ce = new CryptoEphemeral <T>(data, validity ?? _defaultValidity);

            return(await EncryptAsync(ce));
        }
예제 #2
0
        public async Task <string> EncryptEphemeralAsync(string text, TimeSpan?validity = null)
        {
            var ce = new CryptoEphemeral <string>(text, validity ?? _defaultValidity);

            return(await EncryptAsync(ce));
        }