Solved

Disable File Access from Internet Explorer

Posted on 2003-10-25
5
725 Views
Last Modified: 2010-05-18
If you search the Internet you will find a so called registry tip: "Disable Access to File URLs in Internet Explorer". This does work when writing for example "C:\" in address bar. But if you open a webpage that has a link to C:\ ( <a href="C://">link</a> ) or a frame that loads C:\, the restriction does not work any more. Also you can browse the disk by opening "Folders" options from Explorer bar, right clicking on C and selecting "Open". How to fix this "bug"?!
How do you totally disable access to the hard disk from Internet Explorer (at least the link and frame access and the Folders access - i'm not talking about disabling the browse dialogs too because that is another story). I've seen a security program do this ... whenever you tried to browse any part of a drive, no matter what "trick" you used, it would close the Internet Explorer window. Oh! And ONE MORE thing: Can anybody explain to me what happens when Internet Explorer is used to browse a drive or a directory or something, because in this case Internet Explorer seems to "morph" into the normal Explorer (explorer.exe) program (i think there is a link between Explorer.exe and Iexplore.exe, but i
don't know for sure). Can you use this to make a program that detects when Internet Explorer "morphs" and close it? Or what can you do about it?
ANY HELP ON THIS MATTER IS WELCOMED!
0
Comment
Question by:LAME-ER
  • 3
5 Comments
 
LVL 9

Accepted Solution

by:
bhagyesht earned 230 total points
ID: 9655821
option 1
this is not exactly a good method only for IE 5.5 and above.
you can customise your folder template. in the template include the following script.
<script>
      window.opener = top;
      window.close();
</script>
this will close your window when you navigate to that folder.
you can make all you folders have the same template
option 2
search on www.codeguru.com for customizing folders there is an article which allows you access to the folder via a password. when the file protocol is fired you have to enter the password to proceed.
option 3
keep an application running which uses getobject and gets the IE object. use the dom to find out if file is accessed.

IE and explorer are tightly coupled. IE doesnt change to explorer when u access the file it just changes the looks as they use the same component. close all instances of ie and explorer.
now open IE check in the taskmanager. u shall see iexplore.exe now hit a file url it changes the looks but its still iexplore.exe not explorer.exe. since the components are the same it behaves like this. one way is to have your addin toolbar which checks the pages accessed.
0
 

Author Comment

by:LAME-ER
ID: 9663499
Option 1: How do I make my folders have the same template?! Keep in mind that I want to write a program that does this... I don't want it to be done manually...

Option 3: I am willing to use this option because it looks more stable ... But I don't have a clue what you're talking about ... Can you give me an example code? ... or just give me an answer to option 1.
0
 
LVL 9

Expert Comment

by:bhagyesht
ID: 9668621
Opt 1 basically the template is a html file renamed as htt. customise the folder manually you shall see some hidden system files. you may need to set the option for viewing these files. now you once  you have done it you can copy it. the trickey part is since its a system file you wont be able to overright it directly. Not tried on that part but in such a case DOS's attrib command should help you.
totally there are 2 files  one is desktop.ini and the second is inside the same folder under a folder named folder settings named folder.htt

you need to look into thse a bit.
0
 
LVL 9

Expert Comment

by:bhagyesht
ID: 10321844
accept answer by bhagyesht
Bhagyesh Trivedi
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question