Completely prevent Access database files from being downloaded

Source: Internet
Author: User
access| Data | database | Download straight to the point.
Our purpose: To prevent Web site Access database files from being downloaded.
Current approach: Change the database file name extension to. asp
Flaw: In fact, even if you change the extension to. asp, the database can still be downloaded, because this file does not contain <% or%> tags, so IIS does not do any processing of this file, download the database and the original database exactly the same!
Solution: The idea is very simple, add <% or%>,iis in this file will be parsed according to ASP syntax, then will report 500 error, nature cannot download.
But if it's simply a matter of adding <% to the text or Memo field in the database, it won't work, because access will handle the contents of it, and in the database he will be in the form of <, invalid!
The correct approach is to save the <% into the OLE Object field so that our purpose is achieved.
As for how to add to Riga I will not nonsense. If you are not or too troublesome, I have done a database, you download back, in access to the inside of the table pasted into your database, table name casually, and then don't forget to change the database extension to. asp, this is OK. In fact, write an ASP page to do the most convenient, but I am lazy, ha. Whoever has more free time write one.
Download address for this database:
Http://huolx.533.net/nodown.mdb
Http://user1.7host.com/huolx/nodown.mdb


Note: The above method is my own thought out, if there are similarities, it is a coincidence. But I learn ASP4 months, related articles see a lot of, haven't seen this method, so write out, hope for everyone a little help.



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.