Using aspnet_setreg

A

Adam Billmeier

Hello,

I am converting a asp.net web app from using connection string safety in the
web.config to using encrypted values using astnet_setreg. I am running into
a problem running the page.

The connection strings are used to connect to SQL server 2000 to load
datasets with the information for the system.

Here is what I have done.

Ran aspnet_setreg following the directions. i specified -c and supplied the
existing string.

I then placed the string generated by aspnet_setreg into the webconfig file.
example:
<add key="WEBCON"
value="registry:HKLM\Software\WEB\DAT\ASPNET_SETREG,sqlConnectionString"/>
I then have the webpage retreive the value as follows:
Dim securityConn As New
SqlClient.SqlConnection(ConfigurationSettings.AppSettings("WEBCON"))

When I run the web I receive the error:
Format of the initialization string does not conform to specification
starting at index 0.

Please Assist
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top