Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!sharkey!oxtrap!mudos!mju From: mju@mudos.ann-arbor.mi.us (Marc Unangst) Newsgroups: comp.sys.ibm.pc Subject: Re: SHAREWARE on Networks Message-ID: <349.24633E97@mudos.ann-arbor.mi.us> Date: 6 May 89 18:17:53 GMT Organization: A neat desk is a sign of a crazy person. Lines: 105 In article <48@massey.ac.nz>, GEustace@massey.ac.nz (Glen Eustace) writes: >We recently received about 150M of PC software from SIMTEL20, there is >alot of very good SHAREWARE software included. If we put the software >up on the server, are we liable for the registration? or are our users? Ask yourself this question again, but rephrase it to read "If we put commercial software up on the server, are we responsible for buying it? or are the users?" You should either a) Get a site license that allows an unlimited number of copies; or b) register as many copies as you anticipate having to use at once. If you use (b), you should use some sort of file-locking technique so you can't have more people running it at once than you have registered copies. Usually, the license agreements let you treat the software like a book: You can use it, pass it along to someone else, and have them use it, but you can't have more than one person using it at one time. >Many PD software outlets include SHAREWARE software on their disks, >bulletin boards etc., and treat it as though it were in the Public >Domain. Careful! There's a big difference between allowing people to download a piece of software and allowing them to use it. Most shareware is freely- distributable -- You can pass along as many copies of the unregistered version (if there's any difference) as you want, but each of those people must register their copy if they choose to continue using it. PD software outlets such as PC-SIG can include shareware on their disks as long as it's made clear that the fee the user has paid to PC-SIG was for handling charges, and that the user must still register the software if they choose to continue using it. >Our user community consists of about 1200 PC users, presently some 25 >have been connected to the network. The dilema is that we can supply >SHAREWARE to our users on disks and it then become their >responsibility to register it. If we put it on the server, it would >appear to be our responsibility. We can't afford to register every >SHAREWARE package for 1200 users but we believe we have some >obligation to our user community to ensure its availablity. As I mentioned above, there are two things you can do: a) Get a site license; or b) Register multiple copies of the software. Most shareware vendors will sell you an unlimited-copy version of the software that allows as many people as you want to use the software at once. You usually pay a one-time fee, and you're set for life. This fee, although it is sometimes in the hundreds of dollars, is usually cheaper than registering 1200 copies of the software. If you can't (or are unable to) get a site license, you can register multiple copies of the program. If you don't register as many copies of the software as there are users at your site, you need to install some sort of file-locking so you can't have more users than registered copies of the program. If you had 5 registered copies of the program, your batch file could look something like this: echo off for %%z in (1 2 3 4 5) do if "%1" == "%%z" goto startapp :tryagain for %%x in (1 2 3 4 5) do if not exist G:\LOCK\SUPERAPP.%%x %0 %%x echo Sorry, but all copies of SuperApp are checked out. Please try again echo later. goto end :startapp if exist G:\LOCK\SUPERAPP.%1 goto tryagain rem > G:\LOCK\SUPERAPP.%1 superapp arg1 arg2 arg3 del G:\LOCK\SUPERAPP.%1 :end This batch file assumes that drive G: is a shared network drive, and you have a directory \LOCK for lockfiles. Each lock file has a name in the format appname.num, where appname is the name of the program, and num is the copy number. For each copy that is "checked out", there is a lock file in G:\LOCK. When all the copies have lock files, there are none left, and the batch file exits. If it finds a free copy, though, it calls the batch file again, with argv[1] set to the copy number it found. The batch file then branches to startapp, and checks the lock directory again (in case somebody grabbed the copy while we were re-starting the batch file). If someone has, we keep looking for a free copy. However, if the copy is still available, we create a lock file in G:\LOCK, and then start up the application. After we're done, we delete the lock file and exit. (Note that the first line prevents a user from attempting to fool the batch file by calling it with a copy number that will never be used, such as "xyz". We'll only branch to startapp if the copy number given is valid.) The only problems are 1) A person can still execute the program manually; and 2) If a machine goes down while it's running a copy of the program, that copy isn't returned to circulation. There is also a small window between the time that you check for the lock file the last time, and the time you create the lock file. (1) is fairly easy to deal with; (2) just requires checking the lock directory manually once in a while to make sure that everything is okay. The last problem (with the race condition) is really a non-problem, since I don't think anybody is going to get sued if there is occassionally one more running copy than there are purchased copies. Note that this method works equally well if you have a commercial package that you either don't want to get a site license for, or can't. -- Marc Unangst UUCP smart : mju@mudos.ann-arbor.mi.us UUCP dumb : ...!uunet!sharkey!mudos!mju UUCP dumb alt.: ...!{ames,rutgers}!mailrus!clip!mudos!mju Internet : mju%mudos@cardiology.ummc.umich.edu