NServiceBus.Core.Tests.Encryption.FakeEncryptionService.Decrypt C# (CSharp) Method

Decrypt() public method

public Decrypt ( EncryptedValue encryptedValue, IIncomingLogicalMessageContext context ) : string
encryptedValue EncryptedValue
context IIncomingLogicalMessageContext
return string
        public string Decrypt(EncryptedValue encryptedValue, IIncomingLogicalMessageContext context)
        {
            if (encryptedValue.Base64Iv == hardcodedValue.Base64Iv && encryptedValue.EncryptedBase64Value == hardcodedValue.EncryptedBase64Value)
             return "A secret";

            throw new InvalidOperationException("Failed to decrypt");
        }