preventing piracy...

This is a discussion on preventing piracy... within the C Programming forums, part of the General Programming Boards category; Hi all. I have a question. Let's say I have a program that i wish to give to someone, but ...

  1. #1
    Guest Sebastiani's Avatar
    Join Date
    Aug 2001
    Location
    Waterloo, Texas
    Posts
    5,699

    preventing piracy...

    Hi all. I have a question. Let's say I have a program that i wish to give to someone, but with a certain limitation: they can have only ONE copy on their drive! In other words, if they move their copy to a different part of the hard drive, it moves but REmoves the copy in the previous directory. Also, if they move the copy to the floppy, the previous copy is removed. So basically, a "one-copy" contract. Is there a setting under Windows and also Unix that allows this type of control? Any examples, ideas would be appreciated.

    -Sebastian
    Code:
    bool fun(bool value)
    {
        return std::pow(std::exp(1), std::complex<float>(0, 1) 
        * std::complex<float>(std::atan(1)*(1 << (value + 2))))
        .real() > 0;
    }

  2. #2
    I'm Back
    Join Date
    Dec 2001
    Posts
    556
    you could use the getcwd or some function in dir.h that enables you to check which dir your program is in.

    when the 1st time program executes it gets this dir name and stores it somewhere. the next time it is run it checks for the present dir and compares it with the stored dir name.

    if it is same then it executes other wise it does whatever you want.

  3. #3
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    Posts
    14,826
    Why bother? If your program is nifty enough, it will be cracked. Furthermore, you'd have to be storing this in a seperate file some place, which will even make it easier to crack. Basicly, there is no real point to doing this. Besides, what happens if I copy it in multiple locations before I ever run it?

    Quzah.
    Hope is the first step on the road to disappointment.

  4. #4
    Sayeh
    Guest
    An easy method that provides 'moderate' singularity, is to 'register' the program with the IPC Manager (InterProcess Communications) when it runs.

    Then, each time it is run, it looks to see if it's already running. If you check for this across the network, you can see if perhaps it's running on multiple machines.

    Not perfect, but provides reasonable singularity. You don't care how many copies they have, so long as only one license can run at a time.

    enjoy.

  5. #5
    Registered User
    Join Date
    Oct 2001
    Posts
    375
    Making it require an installer could help for a single drive, as the registry entries would have to be particular to where it's been put. Then make them register the program with the code as something like their social security. They'd have to be pretty crazy to let everyone install with their SS. Help for everything but piracy amongst family and close friends. (Unless cracked so SS not needed of course.)
    Allegro precompiled Installer for Dev-C++, MSVC, and Borland: http://galileo.spaceports.com/~springs/

  6. #6
    Registered User
    Join Date
    Aug 2001
    Posts
    223
    Sounds like you are trying to take away quite a bit from your user but here it goes...

    Lets say that you do encrypt some information and save it in the registry in encrypted format.... this allowing the program to only run from it's original installation folder.... Because in the registry you have also installed some location encrypted init codes to make whatever other checks that prevent the executable from running...

    What would prevent the users from installing in other machines....
    How about some encrypted dynamic information in the installation disk?
    Then that means you could only run the installation from a re-writable media like floppy.... Youc could get some system specific information encrypted into the installation diskettes to prevent it from executing anywhere else and modifying it upon uninstallation....God forbid a system crash where the software can no longer be uninstalled or reinstalled....


    just food for though...
    zMan

  7. #7
    Guest Sebastiani's Avatar
    Join Date
    Aug 2001
    Location
    Waterloo, Texas
    Posts
    5,699
    Thanks all for your input. I do realize that anti-piracy isn't a very popular topic around here...Anyway, I suppose there is no way to instruct Windows to run a "CUT" operation for every "COPY" operation for any file named "Blah.EXE", for instance, perhaps in some configuration setting in a system file. Still, if Windows does indeed have some sort of file stored for this purpose, then my answer would be there....
    Code:
    bool fun(bool value)
    {
        return std::pow(std::exp(1), std::complex<float>(0, 1) 
        * std::complex<float>(std::atan(1)*(1 << (value + 2))))
        .real() > 0;
    }

  8. #8
    Registered User
    Join Date
    Oct 2001
    Posts
    375
    Hence the registry installer. When you install your program, then your installer can remove a previous version..
    Allegro precompiled Installer for Dev-C++, MSVC, and Borland: http://galileo.spaceports.com/~springs/

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. General Guidelines on Preventing Header File collision
    By stanlvw in forum C++ Programming
    Replies: 12
    Last Post: 07-05-2008, 04:02 AM
  2. Replies: 5
    Last Post: 02-05-2003, 01:52 PM
  3. Music Piracy is Good?
    By Davros in forum A Brief History of Cprogramming.com
    Replies: 29
    Last Post: 01-22-2003, 12:11 AM
  4. Piracy Protection: How To? (Ideas)
    By zahid in forum A Brief History of Cprogramming.com
    Replies: 12
    Last Post: 01-13-2002, 11:47 AM
  5. Software piracy
    By Govtcheez in forum A Brief History of Cprogramming.com
    Replies: 37
    Last Post: 12-02-2001, 11:28 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21