I've come across a situation which isn't clear to me. The following code works:
application.Billing.Bank.AccountNumber = "1";
application.Billing.Bank.RoutingNumber = "1";
But the following code does not work:
application.Billing.Bank.AccountNumber =
cryptographer.EncryptSymmetric(application.Billing.Bank.AccountNumber);
application.Billing.Bank.RoutingNumber =
cryptographer.EncryptSymmetric(application.Billing.Bank.RoutingNumber);
I've made sure the database fields hold sufficient characters to avoid truncation exceptions. The entity fields AccountNumber and RoutingNumber already contain a value prior to the above field operations. The root entity application is hydrated from the active Session in an ASP.NET MVC application.
I receive no exceptions. What am I missing here?
Thanks!