User Tools

Site Tools


cluster:157

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
cluster:157 [2017/04/06 14:48]
hmeij07
cluster:157 [2017/04/06 15:44]
hmeij07
Line 31: Line 31:
 </code> </code>
  
-Unique usernamaes and UID/GID need to be created. We need a simple web page where public keys can be uploaded with username requested. The username will be prefixed by first 3 characters of College ('wes' for Wesleyan, 'laf' for Lafayette', etc). Script figures from passwd file which UID/GID is next, then+Unique usernamaes and UID/GID need to be created. We need a simple web page where public keys ''ssh-keygen -t rsa'' can be uploaded with username requested. The username will be prefixed by first 3 characters of College ('wes' for Wesleyan, 'laf' for Lafayette', etc). Script figures from passwd file which UID/GID is next, then
  
 <code> <code>
-[root@hmeij ~]# echo "$prefix$uname:x:15001" >> /etc/group +nid=15001 
-[root@hmeij ~]# useradd -u 15001 -g 15001 $prefix$uname +pre=wes 
-[root@hmeij ~]# cp $file /etc/ssh/authorized_keys/$prefix$uname +unm=hmeij 
-[root@hmeij ~]# chmod 0444 /etc/ssh/authorized_keys/$prefix$uname+[root@ ~]# echo "$pre$unm:x:$nid" >> /etc/group 
 +[root@ ~]# useradd -u $nid -g $nid $pre$unm 
 +[root@ ~]# echo "`date | md5sum | awk '{print $1}'`" | passwd $pre$unm --stdin 
 +[root@ ~]# cp /tmp/$upfile /etc/ssh/authorized_keys/$pre$unm 
 +[root@ ~]# chmod 0444 /etc/ssh/authorized_keys/$pre$unm
 </code> </code>
  
 +We need ''root'' authorized keys from each site so that from each college the respective block of UID/GID canbe grabbed and added to local passwd, shadow and group files.
  
 +Hmm, this requires that at CollegeA user hmeij can switch to weshmeij credentials before connecting to CollegeB (echo "$unm $localhost=/bin/su - $pre$unm" >> /etc/sudoers"). Not pretty.
  
 +Ahh, since 
  
 **Kerberos & AD** **Kerberos & AD**
cluster/157.txt · Last modified: 2017/04/06 19:31 by hmeij07