This tip is to get a tool called ZoneStripper by James Kovaks to stop the annoying “project location not trusted” dialog box, below, appearing when you open downloaded solutions in Visual Studio.
If you download zipped source code from the web, unzip it and then open the solution in Visual Studio 2008 (and apparently VS 2003 and VS 2005 as well) you may get a dialog that says “The project location is not trusted” … “Running the application may result in security exceptions when it attempts to perform actions which require full trust.” A bit like this:
What happens is that when you download something from the internet Windows (from Windows XP SP2 onwards) will add an alternate stream to the file called zone.identifier. If the file is a zip it will then add that alternate stream to each of the files as it unzips.
You can view this stream by typing something like the following at a command prompt:
You can then read the contents of the alternate stream:
What the ZoneStripper program does is delete the zone.identifier alternate stream from the file so that zone aware applications (and the OS) treat the file normally.
Note: If you unzip the files to a FAT based file system then you won’t have a zone.identifier in the first place as the FAT file system does not support alternate file streams.
Thanks for the tip!
Thanks for this post! I’d never heard of Alternate Data Streams (ADS) before.I found out if you don’t want to download another tool you can right click on your solution file, go to properties, at the bottom will be a security section saying “this file came from another computer and might be blocked to help protect this computer.” You can click unblock next to it. You will also need to do this for all the projects in the solution. :(If you do this with the zip file prior to unzipping the ADS will not be added to your files.
Cool – worked for me. Saved me some headache. I downloaded DotNetNuke and unzipped, which must be exactly what you are describing above. Well done sir.Also, I noted on another blog you could right click the downloaded .zip document, hit properties, and select the “Unblock” button near the bottom which accomplishes the same goal.
Thanks. Just unblocked in the property sheet of the zipfile after download! Extracted. Trust! it worked without any trust issue!
@KyleDude the unblock button is magic! I’ve struggled with this for a few hours.. finally I found this and was about to try changing each file as the original post suggests, but saw your note. That is money my friend. Money.
Great help! Thanks.
Great Tip!!Another option too – in W7 I was able to edit the file in Notepad (as described above) and change the Zone from 3 to 1, and it worked like a charm as well. No need even to use an additional tool.