Wrox Programmer Forums
|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old March 25th, 2004, 07:35 AM
Registered User
 
Join Date: Feb 2004
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Securing Connection String Passwords and Keys

Hi,

I've just been reading about a method whereby a hacker using HTTP_REFERER methods can access the source code of an ASP website. I've made it work from inside my site but does anyone know how/if it can be done from an external source? If so this opens up a huge security hole in ASP, as many people store connection string passwords and encryption public keys within the ASP code.

I am currently doing this in the classic macromedia method of including the connection string at the top of pages that require it. I want to move these into a COM/DLL object which i believe is more secure (Requiring decompiling, after the original DLL is located in the server's root). Does anyone know a good way of writing one of these connection string DLLs? I'm using Dreamweaver, Visual Studio.NET etc.

Thanks

Joe

 
Old March 25th, 2004, 09:13 PM
Authorized User
 
Join Date: Mar 2004
Posts: 29
Thanks: 0
Thanked 0 Times in 0 Posts
Default

What article are you referring to? Post the link, because I'm interested too.

If its some kind of injection exploit, why don't you just sanitize the string (e..g RegExp to remove bad characters) before using it?

 
Old March 25th, 2004, 11:30 PM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

Are you writing ASP in VS.net? Why not write in ASP.net? The .net runtime secures the files that you would store connections strings. In a typical ASP.net application, a connection string can be stored in the web.config file. The ASP.net installation on IIS will not permit that file to be served.
 
Old March 27th, 2004, 02:13 AM
Registered User
 
Join Date: Feb 2004
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I'm using classic ASP. The article i was reading was on ASP101.com - someone mentioned that you could use HTTP_REFERER to view site source code. I managed to find a script that did this if it was within the site folders online but couldn't find a lot more out about the process. Basically you use a fileSystemObject to download a file as text. That way the ASP.dll doesn't parse the data it just outputs it as plain text. Very cunning.

I already have some SQL injection protection but am going to add some more. I'd just like to know if anyone has any links to good tutorials on making a connection dll. I'm only just starting out with VS.Net and its all very complicated!

Thanks






Similar Threads
Thread Thread Starter Forum Replies Last Post
Securing connection strings haines ASP.NET 2.0 Basics 1 March 2nd, 2008 04:28 PM
SQL connection problems username passwords beatniks BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 6 August 16th, 2006 11:45 AM
When to define primary keys and foregin keys? method SQL Server 2000 1 August 26th, 2005 09:14 AM
Connection String aadz5 JSP Basics 1 January 24th, 2005 04:36 AM
Connection String JsonTerre1 BOOK: ASP.NET Website Programming Problem-Design-Solution 5 November 1st, 2004 02:06 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.