Remove security warning from programs?

jarzhelsing

New member
Joined
May 15, 2013
Messages
2
Programming Experience
1-3
Hi all!

Im new to this community but Im desperate for an answer. Ive been looking for ages and I hope you guys could help me.

I made an application that runs a program. Using the following code:

Process.Start(path & "\program.exe")

The program it runs is downloaded from the internet and on Windows 7 it keeps popping up the warning "Program Downloaded From the Internet Security Risk blablablabla", you know the drill. You can go to its properties and disable the warning and it runs without the warning. However, everytime I run it from within my program it 're-blocks' it and gives the warning again. Is there any way I can make my program disable that message before it will run the program?

I was thinking that I could find something with file attributes (see code below)


Try
Dim attribute As System.IO.FileAttributes = FileAttributes.Normal
File.SetAttributes(path & "\program.exe", attribute)
Catch

Any help would be appreciated.

Thanks,
Jarz Helsing
 
A cheap trick is to use 'more' command to add zone info, look here: security - Reproducing the blocked exe "unblock" option in file properties in windows 2003 - Stack Overflow
Set zoneid to 0 for local file URLZONE enumeration (Windows)
It can be automated with Process class by carrying out the command with cmd.exe and "/c command" as argument.

Here's a short article about NTFS alternate data streams to give you a better view about what is going on: Manipulating NTFS alternate data streams in C# with the CodeFluent Runtime Client | The CodeFluent Entities Blog
This also suggest a managed library that can be used, I have not tried this.
 
Im confused, how do I add this to the VB.net?

Process.Start(more Zone.Identifier.txt > path & "\program.exe:Zone.Identifier")

Im sorry Im not that much code-guru :(
 
It would be in likes of: Process.Start("cmd.exe", "/c more blah blah")
 
Back
Top