Summary: admintool and cred table in Solaris 2.2

From: Wolfgang Ratzka (c4080@rphs2)
Date: Thu Jun 17 1993 - 13:47:10 CDT


I wrote:
: If one uses admintool to set up user accounts or edit user information,
: the ownership of the entriy in cred.org_dir is set to the server principal.
: nispasswd then fails to reencode the secret key information.
:...
: Is this a (known?) bug of admintool or are we missing something?

Several people pointed out to me that the bug was known, but not yet fixed.
The obvous workaround would be to use nischown.
The following is my messy but solution. After using admintool just say:

nisgrep 'auth_name=unix\.[0-9]+@' cred.org_dir \
| awk -F\: \
'{printf ("nischown %s\"[cname=%s,auth_type=DES]cred.org_dir\"\n",$1,$1)}' \
|sh

The following is from Stuart Shapiro <stuart@bfsun1.eglin.af.mil>:

#!/sbin/sh

PATH=/usr/bin
export PATH

# change hostname for your machine
niscat cred.org_dir | cut -d: -f1 | sort -u | grep -v bfsun > tmp.$$

xargs -i -t nischown {} '[cname={}],cred.org_dir.eglin.af.mil.' < tmp.$$
#xargs -i -t echo {} '[cname={}],cred.org_dir.eglin.af.mil.' < tmp.$$

rm tmp.$$

--
      ___                                               Wolfgang Ratzka
|    | :-)      -------------------------------------------------------
| /\ |  \       X400: ratzka@rphs1.physik.uni-regensburg.dbp.de
|/  \|   \      SMTP: ratzka@rphs1.physik.uni-regensburg.de



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:07:56 CDT