nathan
nathan

Reputation: 185

How to make an application not portable?

I am trying to make an application that should not portable between computers or
between users of the same computer.
Which is the best way to do this?

edit: By not portable I meant, the application should not be usable without installing it. ie) moving the installed folder to a different computer or different user login of the same computer.

How can we get an id that is always unique to a user login in a computer?.

please excuse my poor english.

Upvotes: 0

Views: 193

Answers (3)

Lauritz V. Thaulow
Lauritz V. Thaulow

Reputation: 50995

Almost no matter what mechanism you implement, the other user will always be able to decompile the program and route around what prevents running it with relative ease. Two exceptions:

  • Move key functionality + authentication into c modules. This makes circumvention harder, but not impossible

  • Move key functionality + authentication into a call to a program executing on a remote machine that you control. Here the other user needs to re-implement the function(s) based on sample input and output - direct reverse engineering is not possible.

These points are covered in further detail in the answers to the linked-to question. Of course, as some answers point out, you need to determine how much trouble you wish to go to and if it is worth your while to do so. Maybe a naive python native access control is enough deterrant, even if an adept programmer can work around it.

Upvotes: 1

warvariuc
warvariuc

Reputation: 59604

Let your installation script copy some modules of your program to user application directory. In your program add that path to sys.path, that import would find your modules.

Upvotes: 0

S.Lott
S.Lott

Reputation: 391846

If you want only one user to have access you have to create some kind of "login".

That's what registration or activation keys are for.

http://en.wikipedia.org/wiki/Product_key

You include the user name and some machine identification in the key,

Upvotes: 0

Related Questions