home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / sys / sun / admin / 9667 < prev    next >
Encoding:
Internet Message Format  |  1992-12-22  |  1.4 KB

  1. Path: sparky!uunet!paladin.american.edu!gatech!usenet.ins.cwru.edu!agate!spool.mu.edu!enterpoop.mit.edu!eru.mt.luth.se!lunic!sunic!ericom!ppvku!pers
  2. From: pers@ppvku.ericsson.se (Per Stromgren)
  3. Newsgroups: comp.sys.sun.admin
  4. Subject: Safe shutdown by users?
  5. Message-ID: <1992Dec22.155251.11588@ericsson.se>
  6. Date: 22 Dec 92 15:52:51 GMT
  7. Sender: pers@ppvku (Per Stromgren)
  8. Organization: Ericsson
  9. Lines: 28
  10. Nntp-Posting-Host: ppvku.ericsson.se
  11.  
  12. Dear Net!
  13.     
  14.     At our site we need a better shutdown program than
  15. pulling the plug. /etc/shutdown is not executable by ordinary
  16. users here, we want it to be that way, but we would like to
  17. wrap shutdown with a script that does such things as 
  18.     - check that user is logged in on console
  19.     - check that user is alone on the system
  20.     - check that the system is diskless
  21.     - send a mail to us admin people
  22.  
  23. The goal is to let people shutdown/reboot their (own) machines,
  24. if they do it through our programmed checklist above.
  25.  
  26. I just set off the write the script, but I'm not smart enough
  27. to figure out how to setgid/setsid c-program->csh script or
  28. whatever, to make the whole thing at least medium safe. 
  29.  
  30. My first idea was to write a setgid c-program that just do
  31. system("<my script>") and my script would have rwxr-x--- with
  32. the group set to same group as the setgid program. But, as I
  33. just said, I need a helping hand. Have one?
  34.  
  35. Regards,
  36. Per Stromgren.
  37. pers@ppvku.ericsson.se
  38. Ericsson Programatic Sweden AB
  39.     
  40.