This project is read-only.
1
Vote

Support for ComplexTypes with string value

description

I have a complex type that represents TaxId in my system. TaxID has a TaxIdType enum (SSN/EIN) property and a string Value property. EF5 will map this to my Entity table with following naming convention: Customer.TaxId_TaxIdType and Customer.TaxId_Value

When I use the complex type in my Customer Entity, SecurEntity doesn't encrypt the complex type's string property, leaving the value of the Tax ID in clear text in the database.

Types marked with ComplexTypeAttribute should receive special case in SecurEntity in order to encrypt/decrypt those properties of those types.

comments

dangriffin wrote Jun 4, 2013 at 11:57 PM

What's the advantage of using a Complex Type rather than pushing them to their own table and using a typical POCO reference?

Alternatively, perhaps more typically in your case, why not just call that column a native string?

Anyway, the first step for supporting this in SE would be to walk through the encryption loop in the debugger and figure out what type name is being used for those, and how to detect them generally in code.