home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / sys / next / sysadmin / 5187 < prev    next >
Encoding:
Text File  |  1992-09-14  |  2.0 KB  |  61 lines

  1. Newsgroups: comp.sys.next.sysadmin
  2. Path: sparky!uunet!europa.asd.contel.com!darwin.sura.net!wupost!gumby!destroyer!ubc-cs!unixg.ubc.ca!kakwa.ucs.ualberta.ca!news
  3. From: sherwood@fenris.space.ualberta.ca (Sherwood Botsford)
  4. Subject: Re: 'nu -A' question
  5. Message-ID: <1992Sep15.000454.22375@kakwa.ucs.ualberta.ca>
  6. Sender: news@kakwa.ucs.ualberta.ca
  7. Nntp-Posting-Host: fenris.space.ualberta.ca
  8. Organization: University Of Alberta, Edmonton Canada
  9. References: <5516@blue.cis.pitt.edu.UUCP>
  10. Date: Tue, 15 Sep 1992 00:04:54 GMT
  11. Lines: 48
  12.  
  13. robert cyphers writes
  14. > I want to call the command
  15. >   nu -A  name realname uid gid shell pwd home reuse mh  
  16. domain
  17. > to install new users from inside a program.
  18. > My problem is:
  19. > Can I get 'nu -A' to accept "*" as a password with the  
  20. usual meaning,
  21. > i.e. login disabled?
  22.  
  23. Nope.  Think about it.  Nu is going to use whatever you  
  24. type in, run crypt on it, and stuff THAT string into the  
  25. /etc/passwd (or netinfo ) file.  Alternately, it will feed  
  26. the string to passwd, and passwd should barf, because it's  
  27. too short.  Entering it on the command line too, you would  
  28. have to protect it from globbing.
  29.  
  30. HOWEVER
  31. You can get around this by modifying the DeleteAccts shell.   
  32. Since nu is a binary that calls the script, I don't see a  
  33. way to make it call it with extra variables.  But you could  
  34. have DeleteAccts check an environment variable, and based  
  35. on that either delete the account or merely disable it.  (I  
  36. would tend to modify the script so that disableing the  
  37. account was default, deleting it required the extra  
  38. variable.
  39.  
  40. Make that script make a series of calls to niutil to change  
  41. the passwd from sdkfjqp712047612 to *sdkfjqp712047612. (*  
  42. never comes up as the result of encrypting the password,  
  43. and this way, you can remove the * and his old password  
  44. works)
  45.  
  46.  
  47.  
  48. > Also, should 'reuse' and 'mh' be N/Y or 0/1?
  49.  
  50. You want an integer. 
  51. From /etc/nulib/nu2.sh:
  52. if ($wantMHsetup) then
  53.     mkdir Mail
  54.     mkdir Mail/inbox
  55.     ...
  56.  
  57. see also /etc/nu.cf
  58.