473,804 Members | 2,140 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to prevent file to be copied

Hi All,

I am having a vb.net (VS 2005) application which creates some files in
the Program Files foldes ( lets say 'Test') , but as usual when i
uninstall this application i remove the folder from the Program
Files but the thing is that if the user is bright enough and he did a
copy paste to his personal before uninstalling , then he can use that
file

How can i prevent this , i got the idea of disabling the copy
functionality from the folder called 'Test'

How can i do this......any help will be appreciated

Thanks and Regards
-Sajin

Dec 29 '06 #1
3 3221
Sajin,

You have already investigated what this means for use on Vista?

Cor
"sajin" <sa***@iprlab.c omschreef in bericht
news:11******** *************@i 12g2000cwa.goog legroups.com...
Hi All,

I am having a vb.net (VS 2005) application which creates some files in
the Program Files foldes ( lets say 'Test') , but as usual when i
uninstall this application i remove the folder from the Program
Files but the thing is that if the user is bright enough and he did a
copy paste to his personal before uninstalling , then he can use that
file

How can i prevent this , i got the idea of disabling the copy
functionality from the folder called 'Test'

How can i do this......any help will be appreciated

Thanks and Regards
-Sajin

Dec 29 '06 #2
Why not encrypt the data you put in the file and decrypt it when you need to
use it?

Then if the user copies the file it will be of no use to him.

"sajin" <sa***@iprlab.c omwrote in message
news:11******** *************@i 12g2000cwa.goog legroups.com...
Hi All,

I am having a vb.net (VS 2005) application which creates some files in
the Program Files foldes ( lets say 'Test') , but as usual when i
uninstall this application i remove the folder from the Program
Files but the thing is that if the user is bright enough and he did a
copy paste to his personal before uninstalling , then he can use that
file

How can i prevent this , i got the idea of disabling the copy
functionality from the folder called 'Test'

How can i do this......any help will be appreciated

Thanks and Regards
-Sajin

Dec 29 '06 #3
On 29 Dec 2006 00:12:08 -0800, sajin wrote:
Hi All,

I am having a vb.net (VS 2005) application which creates some files in
the Program Files foldes ( lets say 'Test') , but as usual when i
uninstall this application i remove the folder from the Program
Files but the thing is that if the user is bright enough and he did a
copy paste to his personal before uninstalling , then he can use that
file

How can i prevent this , i got the idea of disabling the copy
functionality from the folder called 'Test'

How can i do this......any help will be appreciated

Thanks and Regards
-Sajin
Hey Sajin,

It's not entirely wise to store data in the program files folder. User data
should be kept in the Application Data Folder. You can get this folder like
so:

Environment.Get FolderPath(Envi ronment.Special Folder.Applicat ionData)

As for preventing clever users from using their own copy or manipulating
the existing data, that will take a bit more work. Preventing copying of a
file is harder than it sounds, especially with almost everyone running as
administrator!

You'll need a very simple way of determining whether a change was made by
the application or by the user. Perhaps every time you update the user data
with the application, store a MD5 hash of the file combined with a MD5 hash
of some other data, perhaps the installation date somewhere. Then check
these every time you access the data. This way you will know:

1) If the user changed an existing data file (File MD5 will differ)
2) If the user has uninstalled and installed again (Installation date MD5
will differ)

Its not bulletproof but should keep casual "hackers" very busy
--
Bits.Bytes
http://bytes.thinkersroom.com
Dec 29 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

22
7436
by: Bryan Rickard | last post by:
I wrote a simple program in VB6 to copy all the files from a directory on a CD-ROM to my hard disk. There are about 10 files, each about 30MB. The program uses Get and Put to get data from the CD into a buffer and then put it into the disk. See code below. It works, but it slows down drastically before it copies all the files. Windows Task Manager shows the CPU usage gradually increasing as the files are copied, until it reaches 100...
6
7330
by: Pekka Niiranen | last post by:
Hi, I have used the following example from win32 extensions: -----SCRIPT STARTS---- import win32file import win32con import win32security import pywintypes
4
8121
by: cyclops | last post by:
I'm trying to do XML + XSLT -> Another XML. The source XML contains multiple namespaces and XSLT will handle all possible tags under each name space. ----source---- <document xmlns="..." xmlns:a="..." xmlns:b=""> .... ----XSLT---- ....
8
2858
by: Bryan Parkoff | last post by:
I find an interesting issue that one base class has only one copy for each derived class. It looks like that one base class will be copied into three base classes while derived class from base class is executed. It means that three derived classes are pointed to a separated copy of base class. I do not allow second and third copy of base class to be created, but it must remain only first copy of base class. It allows three derived...
13
2150
by: Perecli Manole | last post by:
In the forms authentication construct, I need a way to prevent ticket IssueDate and Expiration from being updated for a specific page only. By default forms authentication updates these two values whenever a page is requested and slides these values forward. Is there any way to forgo this proccess just for a specific page. I need this because this page is requested behind the scenes cheking for reminders for an Intranet application....
1
2222
by: Andreas Bergmeier | last post by:
We have a com dll inside the bin directory of a WebApplication. In asp.net 1.1 this dll stays only in the bin directory and just the interop wrapper is copied to the temporary asp.net files. In asp.net 2.0 the com dll is copied to the temporary asp.net files, too - which is a real showstopper because it needs other dlls in the same directory to run. Is there a way one can prevent a dll to be copied to the temporary asp.net files? ...
7
4557
by: perryche | last post by:
Is there a way with MS Access 2002 and above to prevent people importing from a blank Database the tables in another database? I have done a lot of searches but there isn't really a solution that will work for me. Would someone explain how to build a RWOP Query in 2002 and what it does exactly? I can prevent an access to a query, but, what if people just tap into your table, and bypass your query? May be I misunderstood what it does. ...
3
1729
by: Robert Dunlop | last post by:
I am using Microsoft Visual Studio 2005 for development of an ASP.NET site, and I have a problem that greatly effects my workflow at times. It seems that after I upload new files anywhere within the directory structure of the site that is visible to VS, the next time I perform a build VS takes extra time, apparently downloading the new files (though the time required seems much longer than a one-time download should take). During this...
5
3056
by: =?Utf-8?B?UVNJRGV2ZWxvcGVy?= | last post by:
I have a .Net web service that converts the MODCA files to tif or png file format. This web service runs on a 2003 server. This web service first copies the MODCA file to be converted to a temporary conversion folder. Then it converts it to the desired file format and copies the file to the output folder specified. Then it deletes the converted file from the temporary conversion folder. Then it attempts to delete the copied input file...
0
9715
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9595
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10099
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9176
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7643
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5536
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5675
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4314
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3836
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.