home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.unix.admin
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!saimiri.primate.wisc.edu!doug.cae.wisc.edu!castlab!chris
- From: chris@castlab.uucp (Christian)
- Subject: Re: How to write a "turnin" utility??
- Organization: U of Wisconsin-Madison College of Engineering
- Distribution: world
- Date: 29 Dec 92 01:54:18 CST
- Message-ID: <1992Dec29.015418.12223@doug.cae.wisc.edu>
- References: <1992Dec28.213900.14908@organpipe.uug.arizona.edu>
- Lines: 36
-
- In article <1992Dec28.213900.14908@organpipe.uug.arizona.edu> dave@bigdog.engr.arizona.edu (Dave Pottinger) writes:
- >Hi,
- >
- >I'm relatively new to Unix sys admin stuff and have run into some
- >problems with what should be a simple little "turnin" project.
- >Basically, we want to be able to have students "turnin" files from their
- >directory to some place designated by each instructor that will then be
- >accessible only to that instructor/grader (for obvious reasons). These
- >instructors do not have superuser privs. I've used this command on
- >other machines, but am not really sure where to begin learning how to
- >implement one on ours. C? Scripts (ugh)? Any info would be greatly
- >appreciated. Thanks.
- >
-
- There is the script idea. SetUID on the script to that of a user that
- has write access to the directory, and have the script copy the file name
- specified to that directory.
-
- how about:
-
- # /bin/csh
- cp %1 /usr/home/instructors/directory/
-
- save that as an executeable only file, put it where everyone can get at it,
- setuid to the appropriate user that has access to that directory, and the
- student then goes and runs the thing, and specifies the name of the file
- to plopped in the directory. Then give read/write access to the instructors
- for that directory.
-
- For different instructors you could, for example, make a version for each
- course (turnin320, etc.) that copies the file to a directory designated for
- cs320, etc.
-
- Dunno if that helps...
-
- -Chris
-