App.config Encryption

Apr 28, 2009 at 8:38 PM
I know this discussion topic has none to do with the toolkit itself, but it is very relative to WPF. Hopefully no one finds it inappropriate for these discussion boards.

I am trying to figure out how to encrypt/decrypt the connection string within my WPF application's app.config file. I am most familiar with the methods used for ASP.Net applications, and it seems the libraries are available in .Net itself, but I cannot find an example that works for WPF as aspnet_regiis.exe doesn't seem to apply.

In app.config I have the following:

<configuration>
    <connectionStrings>
        <add name="ConnectionString" connectionString="WHATEVER DATA HERE" providerName="Oracle.DataAccess.Client" />
    </connectionStrings>
</configuration>

Does anyone know a best practice method for getting this done on the WPF platform?
Coordinator
Apr 28, 2009 at 9:21 PM
I'm not sure where the best place to ask this question is since app.config is a general mechanism of the .NET Framework and not WPF specific. You might try asking in the "Where is the Forum For" forum: http://social.msdn.microsoft.com/Forums/en-US/whatforum/threads

Ben
Apr 28, 2009 at 9:26 PM
My apologies; I thought I'd try here because most of the examples either pertain to ASP.Net tools, or the Enterprise Library methodology, and I am sure there is a way to do this without using either of those methods. Not to mention, none of them address compatibility issues or considerations for ClickOnce deployment.

I'll try there, I guess.