PetaPoco
PetaPoco copied to clipboard
T4 Templates Value Converter for Connection String
I know its very common to use one of multiple options to encrypt/decrypt web.config file sections but the majority of these options involve built-in specifics related to the machine or user account. Each of these options has many gotchas and/or vulnerabilities.
I find it much more preferable to use my own solution where the value (I.e. connection string) is already encrypted and I reference my own assembly to decrypt values, The T4 templates work great, but they depend on direct access to the connectionStrings section web.config files.
Is there a current method, or can I request support for a value converter for connection string section values so that I can inject my own encryption/decryption and still have the T4 templates generate properly?
If you can work out a way to do this with a T4 template - PR please.
Keep in mind
- It would need to be backwards compatible. No regression.
- There would need to be documentation written and supplied so it can be added to the wiki.