i wrote a website for someone and want to disable it after two mothns.
(because he should pay for it after two months, if not i should blow it up)
so, i called a DateTime WebService from my web site for getting DateTime.Now!
i should keep web site start time some where in his server and i want to write a text file in C:\Windows\System32.
but when i tried to write a text file in this path, i got the error below :
Access to the path 'C:\Windows\System32\ is denied.
at this time i have remote access to his server and can change permissions.
but if he change his server, he will see that error and can find that file and edit it easily.
would you please learn me a way for fix that error or another way for saving web site start time!(mean where?)
database is not a good idea, because he has access to his database.
i can write that file on c drive and change it’s attributes (hidden and system), but he can find this file easily.
would be appreciate for some help
You’re looking to start a “cat and mouse” game, and whatever you attempt, someone will find a way around it. Additionally, any attempts you make to limit the availability of the website will likely result in bugs around the licensing code, etc.
I strongly encourage you to consider an alternate approach. Don’t attempt to make any limitations through technical means. Web sites require support. Provide a ongoing support contract. If your client stops paying, he may still have the website, but no one to support it.
Otherwise, another option to consider is that your hosting model is wrong. Host the website for your client, and then the hosting contains the expense. It would also eliminate any technical issues with your client trying to circumvent any licensing controls you add – assuming that your client doesn’t have access to your web host.