We help IT Professionals succeed at work.

ASP.NET - encrypt web.config - shared hosting

822 Views
Last Modified: 2008-02-01
I'm trying to encrypt the connection strings in my web.config.   ASP.NET 2.0, VB.NET ...    Googling, I find two methods.   I'm using shared hosting (Brinkster), so I have no access to IIS.   The other method involves some simple code, but apparently requires wriiting to the code folder, which the hosting company understandably forbids for the aspnet_user .

So, what am I missing?   Is there a way to do this in a shared hosting environment?
Comment
Watch Question

Munawar HussainPrincipal Software Engineer
CERTIFIED EXPERT

Commented:
you may encrypt connectionstring and put in webconfig file
for each user at the time of login get encrypted conection string and save in applicaion state or session for that specific user. and keep it using ?

Author

Commented:
I guess I don't fully understand how all this works.   I can encrypt the connection string at page load on my development machine and everything works - as long as I am running the code on the development machine.  I thought it stored an encryption key somewhere on the machine that is runnng the code.     That code fails on the web host - apparently because I don't have rights to create that key.    

So, if I put a web.config that has been encrypted on my development machine on the server - it cannot be unencrypted there, because the key isn't there????  I did try that and it doesn't work.

This must be a common problem, but I can't figure out how to get around it.
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION

Gain unlimited access to on-demand training courses with an Experts Exchange subscription.

Get Access
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Empower Your Career
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.